OpenVZ setup procedure followed – January 5th, 2009
host machine – 1.5ghz, 1GB ram, 40GB hard disk drive
host os – Debian 4.0
kernel image – etchnhalf
for more detailed information see: http://download.openvz.org/doc/OpenVZ-Users-Guide.pdf
for more information on symbolic linking see: http://www.ss64.com/bash/ln.html

These instructions are for setting up an OpenVZ system on Debian 4.0 (Etch) with browser-based administration via Webmin. I couldn’t get the OpenVZ plugin for Webmin working, but maybe you can. This cookbook assumes running knowledge of how to edit configuration files via “vi”, using apt-get to install dependencies/software, and how to install via tarballs (.tar.gz).

  1. Install latest Debian distro (Etch at the time of authoring) on your physical server. You can get the netinstall (what I used) here: http://www.debian.org/distrib/netinst. Partition setup note: 5-7GB for root filesystem, 1.25X-2X size of RAM for swap, rest of space for /var/lib/vz (for OpenVZ VPS nodes).
  2. Once installed, configure static ipv4/ipv6 address(es) on interfaces (/etc/network/interfaces) and nameservers in the /etc/resolv.conf file.
  3. Modify apt-get sources if incorrect and add line “deb http://download.openvz.org/debian-systs etch openvz”
  4. Run command to update apt-get with new openvz repository: wget -q http://download.openvz.org/debian-systs/dso_archiv_signing_key.asc -O- | apt-key add – && apt-get update
  5. apt-get install ssh (so we don’t have to sit in front of the server rack anymore)
  6. apt-get upgrade (update to the newest software versions)
  7. You might need to execute “shutdown -r now” if debian installed a new kernel and/or other critical operating system feature.
  8. Now we can get to the good stuff. It’s time to install the OpenVZ kernel: http://wiki.openvz.org/Installation_on_Debian#Kernel_installation
  9. After installing the OpenVZ kernel and rebooting into your new OpenVZ kernel based system (and making sure you have all the OpenVZ shiz running properly), we can now install some webmin dependancies: apt-get install perl libnet-ssleay-perl openssl libauthen-pam-perl libpam-runtime libio-pty-perl libmd5-perl
  10. I suggest running the webmin minimal install – http://webmin.com/tgz.html
  11. install openvz webmin module – http://www.provider4u.de/openvz.tar.gz
  12. install various openvz os templates to /var/lib/vz/template/cache from: http://download.openvz.org/contrib/template/precreated/