Difference between revisions of "A managed OpenVZ installation"

From OpenVZ Virtuozzo Containers Wiki
Jump to: navigation, search
Line 12: Line 12:
 
* Puppet Master <ref>http://reductivelabs.com/products/puppet/</ref>
 
* Puppet Master <ref>http://reductivelabs.com/products/puppet/</ref>
  
==Debian preseeded setup==
+
==The Debian preseed setup==
  
 
At first some basics. To use a so called "preseed" file it is good to know what it is. The Debian installation is done with the "Debian Installer", short d-i. This d-i normally is a ncurses based console application that asks you some questions about your timezone, your partition setup, your network and so on. All this questions could be answered trough a preseed file. In this file some or all questions could be answerd.
 
At first some basics. To use a so called "preseed" file it is good to know what it is. The Debian installation is done with the "Debian Installer", short d-i. This d-i normally is a ncurses based console application that asks you some questions about your timezone, your partition setup, your network and so on. All this questions could be answered trough a preseed file. In this file some or all questions could be answerd.
Line 45: Line 45:
 
All our preseed files are placed on a webserver but you should know that it is also possible to integrate the preseed process into a self made Debian installation medium.
 
All our preseed files are placed on a webserver but you should know that it is also possible to integrate the preseed process into a self made Debian installation medium.
  
==apt-proxy==
+
==The apt-proxy==
  
 
The Debian Netinstall CD covers only a minimal system. So if you need more packages like rsync or others you have to connect to the internet. Without choosing a Debian mirror during the setup, the setup could not continue. If you use Debian OpenVZ Servers and Debian based Virtual Private Server at your site, you should use an apt-proxy to cache the downloaded packages.
 
The Debian Netinstall CD covers only a minimal system. So if you need more packages like rsync or others you have to connect to the internet. Without choosing a Debian mirror during the setup, the setup could not continue. If you use Debian OpenVZ Servers and Debian based Virtual Private Server at your site, you should use an apt-proxy to cache the downloaded packages.

Revision as of 18:15, 15 July 2009

This article will show a managed installation of OpenVZ based on Debian Lenny (Debian 5.0) and some other interesting software pices like PuppetMaster. It is mainly written to show how to manage more than one OpenVZ server in a productive environment.

Pre-Requierements

You should know this software, because it is used during the setup.

If you have any further questions, please feel free to contact us.

Software list:

  • Debian Installer and preseed [1]
  • Apt-Proxy [2]
  • Puppet Master [3]

The Debian preseed setup

At first some basics. To use a so called "preseed" file it is good to know what it is. The Debian installation is done with the "Debian Installer", short d-i. This d-i normally is a ncurses based console application that asks you some questions about your timezone, your partition setup, your network and so on. All this questions could be answered trough a preseed file. In this file some or all questions could be answerd.

Now it is good to know that if you do not answer a question or if a question pops up which is not in the preseed file, the d-i wait until you give a right answer. So it is a really good thing because you could leave some thing open and use the same preseed file for different hardware boxes e.g. one hardware have one network interface, another hardware has four network interfaces.

Also it is good to know that you can use the preseed file to answer questions from any Debian package which is using the debconf interface, for example postfix.

How to start the preseed setup

Simply download the Netinstall CD from a Debain mirror put it in your drive an boot the computer. After booting from the CD you should see the Debian Grub Boot menu. In this menu you should select the "Advanced Option" and in the follwing menu place your coursor on "Automated install" - but do not press enter!

You have to edit this boot menu entry by pressing the TAB key. Now you can append the URL option to the end of this boot line. Here is an example and a screenshot.

URL=http://yourserver:yourport/yourpreseedfile

Now press enter and continue the setup.

As example here is our preseed file:

FIX ME

During the preseed setup

If the d-i faces a question where it founds no answer in the preseed file it will hold on until you answer the question. The d-i will not cancel the installation process.

This is an interesting feature because you could use one file for different hardware setups. For example, if you have not configured that the d-i to always use the eth0 device during setup and there is more then one network card in your hardware, the d-i will wait until you choose one device.

Additional informations

At our site we use different preseed files for different purposes. As example one preseed for VMWare servers etc... All our preseed files are placed on a webserver but you should know that it is also possible to integrate the preseed process into a self made Debian installation medium.

The apt-proxy

The Debian Netinstall CD covers only a minimal system. So if you need more packages like rsync or others you have to connect to the internet. Without choosing a Debian mirror during the setup, the setup could not continue. If you use Debian OpenVZ Servers and Debian based Virtual Private Server at your site, you should use an apt-proxy to cache the downloaded packages.

References