Softwares ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Main /
OpenVZTue Jun 26 15:43:23 2007 reference linux man pages and openvz.org OpenVZ is an Operating System-level server virtualization solution, built on Linux. OpenVZ creates isolated, secure virtual environments. Most of the step for installing OpenVz can be found at http://wiki.openvz.org/Quick_installation After installing your operating system run the following yum update -y; shutdown -r now
# cd /etc/yum.repos.d # wget http://download.openvz.org/openvz.repo # yum install ovzkernel # yum install vzctl vzquota
#cd /vz/template/cache Download Precreated Templates from: http://download.openvz.org/template/precreated/
[root@server1 template]# vzctl create 201 --ostemplate centos-4-i386-default
Creating VE private area (centos-4-i386-default)
Performing postcreate actions
VE private area was created
[root@server1 template]# vzctl set 201 --ipadd 5.5.8.10 --save
Saved parameters for VE 201
[root@server1 template]# vzctl start 201
Starting VE ...
VE is mounted
Adding IP address(es): 5.5.8.10
Setting CPU units: 1000
VE start in progress...
[root@server1 template]# vzctl set 201 --onboot yes --save
Saved parameters for VE 201
[root@server1 template]# vzctl set 101 --hostname server1.server1.org --save syntax mistake made
Warning: distribution not specified default used /etc/vz/dists/default
Saved parameters for VE 101
[root@server1 template]# vzctl set 201 --hostname server1.server1.com --save
Set hostname: server1.server1.com
Saved parameters for VE 201
[root@server1 template]# vzctl set 201 --nameserver 5.5.8.1 --save
File resolv.conf was modified
Saved parameters for VE 201
[root@server1 template]# vzctl set 201 --nameserver 5.5.8.2 --save
File resolv.conf was modified
Saved parameters for VE 201
[root@server1 template]# vzctl exec 201 service sshd status
sshd (pid 10026) is running...
[root@server1 template]# cd /etc/sysconfig/vz-scripts
[root@server1 vz-scripts]# ll
total 28
-rw-r--r-- 1 root root 228 Mar 13 08:58 0.conf
-rw-r--r-- 1 root root 1702 May 31 21:35 100.conf.destroyed
-rw-r--r-- 1 root root 26 Jun 25 12:23 101.conf
-rw-r--r-- 1 root root 1756 Jun 25 12:26 201.conf
-rw-r--r-- 1 root root 1703 Jun 15 15:22 202.conf
-rw-r--r-- 1 root root 1539 Mar 13 08:58 ve-light.conf-sample
-rw-r--r-- 1 root root 1558 Mar 13 08:58 ve-vps.basic.conf-sample
[root@server1 vz-scripts]# vzctl set 201 --userpasswd root:;server1 Some problem with ; in passwd
-bash: !: event not found
[root@server1 vz-scripts]# vzctl enter 201
entered into VE 201
[root@cvps-11 /]# hostname
server1.server1.com
[root@server1 /]# passwd root
Changing password for user root.
New UNIX password:
Retype new UNIX password:
passwd: all authentication tokens updated successfully.
[root@server1 /]# exit
logout
exited from VE 201
[root@server1 vz-scripts]#
Setup memory for openvz - vzctl set 201 --vmguarpages 512M:600M --save [root@server1 template]# vzctl destroy 201 Destroying VE private area: /vz/private/201 VE private area was destroyed |