Steve T's Semi-Cohreant Ramblings

Just another WordPress site

  • About Steve
  • Blog Roll
  • Contact

Upgrading XEN

Posted by stevet on January 16, 2009
Posted in: Geek Out.

We have a couple of XEN servers (details about the install are from here). Recently one of them started rebooting for no good reason. I decided that upgrading the server to the newest bits from CentOS and running that for awhile to see if everything cleans up. Sounds simple but it isn’t.

  • First you need to upgrade the host system. I just ran yum check-update followed by a yum update. Tons of packages were upgraded including the kernel.
  • I stopped any guest VMs from starting automatically, then I cleanly shut down all of my guest VMs.
  • Check /boot/grub/menu.lst to make sure you are booting the new kernel
  • I rebooted
  • Like the install, a new initrd file should be created. I used this command to do mine: mkinitrd -f --with=xennet --builtin=aic7xxx --builtin=serverworks --preload=xenblk --omit-raid-modules /boot/initrd-2.6.18-92.1.22.el5xen.img 2.6.18-92.1.22.el5xen This creates a new initrd the guest systems can use. Note the kernel version. This can be gotten with uname.
  • Then I rebooted again to use the new initrd.
  • After the system came up, I needed to make a couple of changes to the guest images
  • One change is in the image file itself. It needs the new modules in /lib. I use XEN image files rather than partitions, so I am able to mount the image file with a command like: mount -o loop /var/lib/xen/images/guest123.img /mnt
  • I copied the two /lib/modules directories to the image. In this case they are 2.6.18-92.1.22.el5 and 2.6.18-92.1.22.el5xen. Then I unmounted the image.
  • Next I needed to modify the XEN config file for that image. For me it was located as /etc/xen/guest123
  • I removed the kernel, ramdisk, and vif lines from that file and added these to match my system: kernel="/boot/vmlinuz-2.6.18-92.1.22.el5xen"
    ramdisk="/boot/initrd-2.6.18-92.1.22.el5xen.img"
    vif=['bridge=xenbr0']

  • Then I started the guest image and made sure it booted without any problems. The big thing to check is network. The updated vif line allows the network to keep working.

I have three other XEN servers that probably should be updated as well. That will happen sometime in the next couple of weeks and if the notes change I will update them accordingly.

Posts navigation

← Happy New Year
ING Direct Rate Woes →
  • Recent Posts

    • DirecTV 775 Message
    • Configuring BFGMiner on CentOS
    • 1-Wire for Temperature Monitoring – Part 3
    • 1-Wire for Temperature Monitoring – Part 2
    • 1-Wire for Temperature Monitoring
  • Recent Comments

    • stevet on BalanceNG Experts?
    • tgo on BalanceNG Experts?
    • stevet on Stupid NFL Officials
    • RoccoBoxer on Stupid NFL Officials
    • RoccoBoxer on Stupid NFL Officials
  • Archives

    • August 2016
    • November 2013
    • July 2013
    • July 2011
    • June 2011
    • August 2010
    • July 2010
    • May 2010
    • November 2009
    • August 2009
    • July 2009
    • June 2009
    • May 2009
    • April 2009
    • March 2009
    • February 2009
    • January 2009
    • December 2008
    • November 2008
    • October 2008
    • September 2008
    • August 2008
    • July 2008
    • June 2008
    • May 2008
    • April 2008
    • March 2008
    • February 2008
    • January 2008
    • December 2007
    • November 2007
    • October 2007
    • September 2007
    • August 2007
    • July 2007
    • June 2007
    • May 2007
    • April 2007
    • March 2007
    • February 2007
    • January 2007
    • December 2006
    • November 2006
    • October 2006
    • September 2006
    • August 2006
    • July 2006
    • June 2006
    • May 2006
    • April 2006
    • March 2006
    • February 2006
    • January 2006
    • December 2005
  • Categories

    • Geek Out
    • Home Improvement
    • Poker
    • Random Rants
    • Sports
    • Uncategorized
  • Meta

    • Log in
    • Entries feed
    • Comments feed
    • WordPress.org
Proudly powered by WordPress Theme: Parament by Automattic.