Allows one to run multiple GNU/Linux distributions as virtual hosts. They all share the same kernel, which may be a limitation!
From http://download.openvz.org/kernel/debian/etch/ download
linux-headers-2.6.18-openvz-686_02_i386.deb linux-headers-2.6.18-openvz-amd64_01_amd64.deb linux-image-2.6.18-openvz-686_02_i386.deb linux-image-2.6.18-openvz-amd64_01_amd64.deb
These might only work for etch? (Should be okay for sid)
From http://download.openvz.org/template/precreated/ download
These are OS templates.
Set up networking. Edit /etc/network/options to set:
(Might need to wajig restart networking - not sure it was necessary.) Then run:
$ sudo sysctl -w net.ipv4.conf.eth0.proxy_arp=1001
Can have this on boot with the following in
up sysctl -w net.ipv4.conf.eth0.proxy_arp=1001 pre-down sysctl -w net.ipv4.conf.eth0.proxy_arp=0
Now create a new host. We’ll give it an id of 1001.
$ sudo mv fedora* /var/lib/vz/template/cache $ sudo vzctl create 1001 --ostemplate fedora-core-5-i386-default Creating VPS private area: /var/lib/vz/private/1001 Performing postcreate actions VPS private area was created $ sudo vzctl set 1001 --ipadd 192.168.0.10 --nameserver 18.104.22.168 --hostname ovz01 --save Saved parameters for VPS 1001 $ sudo vzctl start 1001 14 Jan 07:22:58 gjw@belinos:/var/lib$ sudo vzctl start 1001 Starting VPS ... VPS is mounted Adding IP address(es): 192.168.0.10 Setting CPU units: 1000 Set hostname: ovz01 touch: setting times of `/etc/resolv.conf': Function not implemented File resolv.conf was modified VPS start in progress... $ sudo vzlist VPSID NPROC STATUS IP_ADDR HOSTNAME 1001 17 running 192.168.0.10 ovz01 $ ping 192.168.0.10 PING 192.168.0.10 (192.168.0.10) 56(84) bytes of data. 64 bytes from 192.168.0.10: icmp_seq=1 ttl=64 time=0.045 ms $ sudo vzctl enter 1001 -bash-3.1# passwd Changing password for user root. New UNIX password: Retype new UNIX password: passwd: all authentication tokens updated successfully. -bash-3.1# logout $ ssh -X firstname.lastname@example.org email@example.com's password: Last login: Sat Jan 13 23:32:01 2007 from 192.168.0.5 [root@ovz01 ~]# [root@ovz01 ~]# ping google.com PING google.com (22.214.171.124) 56(84) bytes of data. 64 bytes from eh-in-f99.google.com (126.96.36.199): icmp_seq=1 ttl=240 time=246 ms
To stop the virtual host:
$ sudo vzctl stop 1001 Stopping VPS ... VPS was stopped VPS is unmounted
To remove the virtual host setup:
$ sudo vzctl destroy 1001 Destroying VPS private area: /var/lib/vz/private/1001 VPS private area was destroyed
So now we have Fedora Core running, virtually as a separate machine. But I recall now why I moved to Debian - it is a dog to get packages installed appropriately.
%%% TeX-master: “survivor”
Your donation will support ongoing availability and give you access to the PDF version of the book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2021 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0.