a) libvirt upgrade from .98 to 1.0

libvirt is an important component of openvswitch integration with KVM. I recently upgraded libvirt in our labs from .98 to 1.0.0. There a number of packages that need to be installed to make this happen. Here is a copy of the script I used to install it. Use it at your own risk. Much of this is here: http://libvirt.org/compiling.html. I highly suggest you issue the ./configure –help command in the libvirt directory to get all of the options. For support of different hypervisors, look here in the help output:

–with-xen add XEN support [default=check]
–with-xen-inotify add XEN inotify support [default=check]
–with-qemu add QEMU/KVM support [default=yes]
–with-uml add UML support [default=check]
–with-openvz add OpenVZ support [default=check]
–with-vmware add VMware support [default=yes]
–with-libssh2 libssh2 location [default=check]
–with-phyp add PHYP support [default=check]
–with-xenapi add XenAPI support [default=check]
–with-libxl add libxenlight support [default=check]
–with-vbox=[PFX] VirtualBox XPCOMC location [default=yes]
–with-lxc add Linux Container support [default=check]
–with-esx add ESX support [default=check]
–with-hyperv add Hyper-V support [default=check]
–with-parallels add Parallels Cloud Server support [default=check]

Here’s my script:

#!/bin/bash
#
# first check versions
virsh –version
libvirtd –version
#
echo ” install libvirt packages ”
read -p “Press [Enter] key to continue…”
apt-get install gcc make pkg-config libxml2-dev libgnutls-dev libyajl-dev libnl-dev pkg-config libdevmapper-dev libcurl4-gnutls-dev python-dev libnl-dev libyajl-dev

#
echo ” cd into directory ”

read -p “Press [Enter] key to continue…”
#
cd /root/openvswitch/libvirt-1.0.0
#
echo ” issue a pwd to get the directory ”
read -p “Press [Enter] key to continue…”
#
pwd
#
echo ” issue the configure command with –with-esx=yes if you want VMware ”
read -p “Press [Enter] key to continue…”
#
#
./configure –prefix=/usr –localstatedir=/var –sysconfdir=/etc –with-esx=yes
echo $?
#
#
echo ” make ”
read -p “Press [Enter] key to continue…”
#
make
echo $?
#
echo ” make install ”
read -p “Press [Enter] key to continue…”
#
make install
echo $?
#
# check versions again afer the install
#
virsh –version
libvirtd –version
#

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s