From: Iustin Pop Date: Wed, 15 Aug 2007 15:15:38 +0000 (+0000) Subject: Some changes to the installation manual. X-Git-Tag: v1.2b1~42 X-Git-Url: https://code.grnet.gr/git/ganeti-local/commitdiff_plain/5d6dd340c878c688a3da62bd101a9209e5484821 Some changes to the installation manual. The biggest change is that at configure time one must specify --localstatedir=/var since the directories for ganeti (/var/log/ganeti, /var/lib/ganeti) must be located here. Reviewed-by: ultrotter --- diff --git a/docs/installing.sgml b/docs/installing.sgml index 2b11c75..689fc93 100644 --- a/docs/installing.sgml +++ b/docs/installing.sgml @@ -9,39 +9,46 @@ Introduction - Ganeti is a cluster virtualization management system. This document - explains how to bootstrap a Ganeti node and create a running cluster. You - need to repeat most of the steps in this document for every node you want to - install, but of course we recommend creating some semi-automatic procedure - if you plan to deploy Ganeti on a medium/large scale. + + Ganeti is a cluster virtualization management system. This + document explains how to bootstrap a Ganeti node and create a + running cluster. You need to repeat most of the steps in this + document for every node you want to install, but of course we + recommend creating some semi-automatic procedure if you plan to + deploy Ganeti on a medium/large scale. This document is divided into two main sections: - Installation of the core system and base components + Installation of the core system and base + components - Configuration of the environment for Ganeti + Configuration of the environment for + Ganeti - Each of these is divided into sub-sections. While a full Ganeti system will - need all of the steps specified, some are not strictly required for every - environment. Which ones they are, and why, is specified in the - corresponding sections. + Each of these is divided into sub-sections. While a full Ganeti + system will need all of the steps specified, some are not strictly + required for every environment. Which ones they are, and why, is + specified in the corresponding sections. - While Ganeti itself is distribution-agnostic most of the examples in - this document will be targeted at Debian or debian derived distributions. - You are expected to be familiar with your distribution, its package - management system, and Xen before trying to use Ganeti. + + While Ganeti itself is distribution-agnostic most of the + examples in this document will be targeted at Debian or + Debian-derived distributions. You are expected to be familiar + with your distribution, its package management system, and Xen + before trying to use Ganeti. - A basic Ganeti terminology glossary is provided in the introductory - section of the "admin guide". Please refer to that if you are uncertain - about the terms we are using. + + A basic Ganeti terminology glossary is provided in the + introductory section of the "admin guide". Please refer to that + if you are uncertain about the terms we are using. @@ -52,16 +59,17 @@ Installing the base system - Mandatory. - + Mandatory. - Please install your operating system as you would normally do. The - only requirement you need to be aware of at this stage is to partition - leaving enough space for a big LVM volume group which will then host - your instance file systems. You can even create the volume group at - installation time, of course: the default volume group name Ganeti 1.2 - uses is "xenvg" but you may name it differently should you wish to, as - long as the name is the same for all the nodes in the cluster. + + Please install your operating system as you would normally + do. The only requirement you need to be aware of at this stage + is to partition leaving enough space for a big LVM volume + group which will then host your instance file systems. You can + even create the volume group at installation time, of course: + the default volume group name Ganeti 1.2 uses is "xenvg" but + you may name it differently should you wish to, as long as the + name is the same for all the nodes in the cluster. @@ -69,25 +77,30 @@ Installing Xen - Mandatory: While Ganeti is developed with the ability to modularly - run on different virtualization environments in mind the only one - currently useable on a live system is Xen. + + Mandatory: While Ganeti is + developed with the ability to modularly run on different + virtualization environments in mind the only one currently + useable on a live system is Xen. - Please follow your distribution's recommended way to install and set - up Xen, or install Xen from the upstream source, if you wish, following - their manual. + + Please follow your distribution's recommended way to install + and set up Xen, or install Xen from the upstream source, if + you wish, following their manual. - For example under Debian 4.0 or 3.1+backports you can install the - relevant xen-linux-system package, which will pull in both the hypervisor - and the relevant kernel. On Ubuntu (from Gutsy on) the package is called - ubuntu-xen-server. + + For example under Debian 4.0 or 3.1+backports you can install + the relevant xen-linux-system package, which will pull in both + the hypervisor and the relevant kernel. On Ubuntu (from Gutsy + on) the package is called ubuntu-xen-server. - After installing Xen you need to reboot into your xenified dom0 - system. Again on some distributions this might involve configuring GRUB - appropriately. + + After installing Xen you need to reboot into your xenified + dom0 system. Again on some distributions this might involve + configuring GRUB appropriately. @@ -95,35 +108,40 @@ Installing DRBD - Recommended: DRBD is required if you want to use the high - availability (HA) features of Ganeti, but optional if you don't require - HA or only run Ganeti on single-node clusters. You can upgrade a non-HA - cluster to an HA one later, but you might need to export and reimport - all your instances to take advantage of the new features. + + Recommended: DRBD is required if you want to use the high + availability (HA) features of Ganeti, but optional if you + don't require HA or only run Ganeti on single-node + clusters. You can upgrade a non-HA cluster to an HA one later, + but you might need to export and reimport all your instances + to take advantage of the new features. - Now the bad news: unless your distribution already provides it - installing DRBD might involve recompiling your kernel or anyway fiddling - with it. Hopefully at least the xenified kernel source to start from will - be provided. + + Now the bad news: unless your distribution already provides it + installing DRBD might involve recompiling your kernel or + anyway fiddling with it. Hopefully at least the xenified + kernel source to start from will be provided. - Under Debian you can just install the drbd0.7-module-source and - drbd0.7-utils packages, and your kernel source, and then run - module-assistant to compile the drbd0.7 module. The commands: + + Under Debian you can just install the drbd0.7-module-source + and drbd0.7-utils packages, and your kernel source, and then + run module-assistant to compile the drbd0.7 module. The + following commands should do it: + - + m-a update m-a a-i drbd0.7 - - - should do it for you. - + - The good news is that you don't need to configure DRBD at all. - Ganeti will do it for you for every instance you set up. If you have the - DRBD utils installed and the module in your kernel you're fine. Please - check that your system is configured to load the module at every boot. + + The good news is that you don't need to configure DRBD at all. + Ganeti will do it for you for every instance you set up. If + you have the DRBD utils installed and the module in your + kernel you're fine. Please check that your system is + configured to load the module at every boot. @@ -144,35 +162,35 @@ m-a a-i drbd0.7 - In Debian, in order to enable the default Xen behaviour, you have to edit - /etc/xen/xend-config.sxp and replace (network-script network-dummy) with - (network-script network-bridge). The recommended Debian way to configure - things, though, is to edit your /etc/network/interfaces file and - substitute your normal ethernet stanza with something like: - - + In Debian, in order to enable the default Xen behaviour, you + have to edit /etc/xen/xend-config.sxp and + replace (network-script + network-dummy) with + (network-script + network-bridge). The recommended Debian way to + configure things, though, is to edit your + /etc/network/interfaces file and substitute + your normal ethernet stanza with something like: + + auto br0 iface br0 inet static - address YOUR_IP_ADDRESS - netmask YOUR_NETMASK - network YOUR_NETWORK - broadcast YOUR_BROADCAST_ADDRSS - gateway YOUR_GATEWAY - # dns-* options are implemented by the resolvconf package, if installed - dns-nameservers YOUR_DNS_SERVERS - dns-search YOUR_SEARCH_PATH - bridge_ports eth0 + address YOUR_IP_ADDRESS + netmask YOUR_NETMASK + network YOUR_NETWORK + broadcast YOUR_BROADCAST_ADDRESS + gateway YOUR_GATEWAY + bridge_ports eth0 bridge_stp off bridge_fd 0 - - - + - Beware that the default name Ganeti uses is xen-br0 (which was used in - Xen 2.0) while Xen 3.0 uses xenbr0 by default. The default bridge your - cluster will use for new instances can be specified at cluster - initialization time. + Beware that the default name Ganeti uses is + xen-br0 (which was used in Xen 2.0) + while Xen 3.0 uses xenbr0 by + default. The default bridge your cluster will use for new + instances can be specified at cluster initialization time. @@ -181,28 +199,30 @@ iface br0 inet static Configuring LVM - If you haven't configured your LVM volume group at install time you need - to do it before trying to initialize the Ganeti cluster. This is done by - formatting the devices/partitions you want to use for it and then adding - them to the relevant volume group: - - + If you haven't configured your LVM volume group at install + time you need to do it before trying to initialize the Ganeti + cluster. This is done by formatting the devices/partitions you + want to use for it and then adding them to the relevant volume + group: + + + pvcreate /dev/sda4 pvcreate /dev/sdb pvcreate /dev/sdc1 vgcreate xenvg /dev/sda4 /dev/sdb /dev/sdc1 - - + - If you want to add a device later you can do so with the + If you want to add a device later you can do so with the vgextend - 8 command. - + 8 command: + + + pvcreate /dev/sdd vgextend xenvg /dev/sdd - - + As said before you may choose a different name for the volume group, @@ -213,27 +233,29 @@ vgextend xenvg /dev/sdd Installing Ganeti - It's now time to install the Ganeti software itself if you haven't - done it yet. You can do it from source, with the usual steps: + It's now time to install the Ganeti software itself if you + haven't done it yet. You can do it from source, with the usual + steps (note that the options must + be set to /var): - -./configure + +./configure --localstatedir=/var make make install - + or you can install the package relevant to your distribution, for example in Debian/Ubuntu: - + dpkg -i ganeti_VERSION_all.deb - + or, if you have a source repository that holds the Ganeti software: - + apt-get install ganeti - + @@ -251,48 +273,55 @@ apt-get install ganeti Initializing the cluster - Mandatory: only on one node per cluster. - + Mandatory: only on one + node per cluster. The last step is to initialize the cluster. After you've repeated the above process or some semi-automatic form of it on all of your nodes choose one as the master, and execute: + - -gnt-cluster init CLUSTERNAME - + +gnt-cluster init CLUSTERNAME + - Options you can pass to gnt-cluster init include the default bridge - name (-b), the cluster-wide name for the volume group (-g) and the - secondary ip address for the initial node should you wish to keep the - data replication network separate. Invoke it with --help to see all the - possibilities. + + Options you can pass to gnt-cluster init + include the default bridge name (), the + cluster-wide name for the volume group () + and the secondary ip address for the initial node should you + wish to keep the data replication network separate. Invoke it + with to see all the possibilities. - The cluster name must exist in DNS. You must choose a name - different from any of the nodes names for a multi-node cluster. In - general the best choice is to have a completely unique name for each - cluster. + + Note that the cluster name must exist in DNS. You must choose + a name different from any of the nodes names for a multi-node + cluster. In general the best choice is to have a unique name + for a cluster, even if it consists of only one machine. Joining the nodes to the cluster. - Mandatory: for all the other nodes. + + Mandatory: for all the + other nodes. If you have already initialized your cluster you need to join the other nodes to it. You can do so by executing the following command on the master node: - -gnt-node add NODENAME - + +gnt-node add NODENAME + - The only option is (-s), which sets the node's secondary ip address for - replication purposes, if you are using a separate replication network. + The only option is , which sets the node's + secondary ip address for replication purposes, if you are + using a separate replication network. @@ -301,7 +330,9 @@ gnt-node add NODENAME This is it! - Now you can follow the "admin guide" to use your new Ganeti cluster. + + Now you can follow the admin guide to use your new Ganeti + cluster.