Version 32 (modified by ibaldin, 9 years ago)


Setting up Euca 2.0


This document covers installation of Eucalyptus 2.0.0 from source in MANAGED-NOVLAN mode of operation. You must have several physical hosts at your disposal, one designated as a head node and the rest as worker nodes. Worker nodes will have to run either KVM or Xen to be able to create virtual machines. In the described setup the head node does not run Eucalyptus VM instances and therefore does not have to run Xen or KVM. Xen/KVM configuration is not covered in this document as it is heavily distribution and hardware dependent.

Eucalyptus does not have strong dependencies on the distribution. The selected distribution should have a kernel upstream of 2.6.22 to properly support tgt package for iSCSI configuration and should ideally offer 'out-of-the-box' use of Xen or KVM (depending on your hardware).


  • Make sure ssh keys for root user are shared across the hosts (i.e. that the root on master node can perform a passwordless login in any worker node).
    root@master$ ssh-keygen
    root@master$ cd .ssh/
    root@master$ cat >> authorized_keys
    root@master$ scp authorized_keys root@worker1:~/.ssh/
    root@master$ scp authorized_keys root@worker2:~/.ssh/
  • These instructions presume the build is being done on the master node
  • Download source code packages for Eucalyptus:
    • Eucalyptus 2.0.0 source, offline version
    • Eycalyptus 2.0.0 source dependencies
    • Euca2ools 1.3.1 source
    • Euca2ools 1.3.1 source dependencies
  • Pay attention to the software prerequisites, particularly Java - don't use OpenJDK, install Sun's Java 1.6.x or above. It is handy to edit and dot this script prior to installation. Installation should be performed as root. In the script below the installation location is /opt/eucalyptus-2.0
    # DOT this file
    # Where is Java?
    export JAVA_HOME=/opt/java/jdk1.6.0_18
    export PATH=$JAVA_HOME/bin:$PATH
    # Where will Euca be installed? Eucalyptus scripts assume the location is the same across all nodes
    export EUCALYPTUS=/opt/eucalyptus-2.0
    # Where is Euca source?
    export EUCALYPTUS_SRC=/home/eucalyptus/eucalyptus-2.0.0
    # where are Apache include files?
    export APACHE_INCLUDES=/usr/include/apache2
    export APR_INCLUDES=/usr/include/apr-1.0
    # Where can Axis2C be found after installation? (note it goes under the Euca install tree)
    export AXIS2C_HOME=$EUCALYPTUS/packages/axis2c-1.6.0
    # where will iniparser library reside?
    export INIPARSER_HOME=$EUCALYPTUS/packages/iniparser3.0b
  • Follow installation instructions through step 5, at which point you should have a built Eucalyptus 2.0 tree on the master node and each of the worker nodes. Be sure to place it in the same location on all nodes
    • If you don't have rsync installed, a combination of tar and ssh works just as well:
      root@master$ tar -cf - $EUCALYPTUS | ssh root@worker1 tar -xf - -C /


This setup assumes that a single NIC in each physical host is dedicated to Eucalyptus functions. Other NICs can be used for extra data-plane connectivity. The MANAGED-NOVLAN mode places no requirements for the supported network switches. To properly setup the network configuration it is important to know two things:

  1. The name of the physical interface on master node that has access to worker nodes (and in this case also is public; it is named eth1)
  2. The name of the bridge on worker nodes that KVM or XEN uses. In this case it is also eth1, because Xen is used as an example. In case of KVM it is typically br0.
  • Perform step 6 a and b of the installation instructions (add user 'eucalyptus' to all nodes; configure hypervisor
  • On worker nodes initialize the configuration file (note that instances directory does not have to be /usr/local/eucalyptus; you can configure it to be anything you want and this step will create and initialize it):
    root@worker$ $EUCALYPTUS/usr/sbin/euca_conf -d $EUCALYPTUS --hypervisor kvm --instances /usr/local/eucalyptus --user eucalyptus --setup
  • Initialize config file on master node:
    root@master$ $EUCALYPTUS/usr/sbin/euca_conf -d $EUCALYPTUS --setup
    root@master$ $EUCALYPTUS/usr/sbin/euca_conf -d $EUCALYPTUS --enable cloud --enable walrus --enable sc
  • Make sure master node has dhcpd installed (typically /usr/sbin/dhcpd or /usr/sbin/dhcpd3). It must not be configured. The worker nodes cannot deal with multiple DHCP servers on the same subnet in this Eucalyptus mode. The only DHCP server on that subnet must be the one used by Eucalyptus.
  • Modify the configuration of the master node ($EUCALYPTUS/etc/eucalyptus/eucalyptus.conf; only the relevant stanzas are shown; make sure no other VNET_MODE statements are uncommented in the file). Note that in the shown configuration the 10.100.x.x range is used internally by Eucalyptus, while 192.168.203.x range is 'public' (even though it comes from a reserved address space):
  • Modify the configuration of worker nodes ($EUCALYPTUS/etc/eucalyptus/eucalyptus.conf):

Running and testing Eucalyptus

  • Start Eucalyptus on master node for the first time and observe the log files for any errors:
    root@master$ $EUCALYPTUS/etc/init.d/eucalyptus-cloud start
    root@master$ $EUCALYPTUS/etc/init.d/eucalyptus-cc start
  • On worker nodes modify the configuration of the dynamic linker to help locate iniparser library. Create file /etc/
    root@worker$ echo $INIPARSER_HOME/lib > /etc/
    root@worker$ ldconfig
    root@worker$ ldconfig -p | grep iniparser
  • The last command above should return output similar to this:
    euca-c1:~# ldconfig -p | grep iniparser (libc6,x86-64) => /opt/eucalyptus-2.0-node/packages/iniparser3.0b/lib/ (libc6,x86-64) => /opt/eucalyptus-2.0-node/packages/iniparser3.0b/lib/
  • Eucalyptus on worker nodes
    root@worker1$ $EUCALYPTUS/etc/init.d/eucalyptus-nc start
  • On master node perform registration of components and cluster
  • Login through the portal, create user, download user credentials. Install user credentials into the account on the host from which you will operate (can be master node or other). The host must have euca2ools-1.3.1 installed from source or binary.
  • Try it out
    user@somehost$ euca-describe-availability-zones verbose
  • Download one of the stock Eucalyptus images (in your cluster we portal, click on 'Extras')
  • Upload the selected image into Eucalyptus. This example uses euca-ubuntu-9.04-x86_64, but you may pick any other available. Be sure to select the right kernel/ramdisk to upload - Xen kernels will not work on KVM installations and vice-versa.
    $ tar -zxf euca-ubuntu-9.04-x86_64.tar.gz
    $ cd euca-ubuntu-9.04-x86_64/kvm-kernel
    $ euca-bundle-image -i vmlinuz-2.6.28-11-generic --kernel true
    $ euca-upload-bundle -b kernels -m /tmp/vmlinuz-2.6.28-11-generic.manifest.xml
    $ euca-register kernels/vmlinuz-2.6.28-11-generic.manifest.xml
    $ euca-bundle-image -i initrd.img-2.6.28-11-generic --ramdisk true
    $ euca-upload-bundle -b ramdisks -m /tmp/initrd.img-2.6.28-11-generic.manifest.xml
    $ euca-register ramdisks/initrd.img-2.6.28-11-generic.manifest.xml
    $ cd ..
    $ euca-bundle-image -i ubuntu.9-04.x86-64.img
    $ euca-upload-bundle -b images -m /tmp/ubuntu.9-04.x86-64.img.manifest.xml
    $ euca-register images/ubuntu.9-04.x86-64.img.manifest.xml
    $ euca-describe-images
  • Generate an SSH key pair using euca-add-keypair, then try to create an instance using euca-run-instances (be sure to use --addressing private option at first)


Where to look

Logfiles are typically located in the installation subtree ($EUCALYPTUS/var/log/eucalyptus). Look for error logs. Check this page.

Euca cloud controller

tgt won't start

  • Install a binary package if possible. On Debian/Ubuntu do
    $ aptitude search tgt
  • Download and install tgt software if it is missing. This software manages ISCSI volumes for Walrus.
    $ make ISCSI=1; make install

Using the correct JDK

  • If your Java 1.6 installation is non-standard, you need to update $EUCALYPTUS/etc/init.d/eucalyptus-cloud to define JAVA_HOME in its opening part and updating PATH to include $JAVA_HOME/bin