Centos 6 DomU

From PrgmrWiki

NOTE: I tried this in a 512M instance, the Graphical C6 installer has fairly high RAM requirements!

Most of the trickery involved here is setting up menu.lst so the prgmr.com loader just runs.

  1. Boot into the Centos 5 rescue image.

From here, you can format the filesystem, then mount it, create needed directories, retrieve the installer kernel+ramdisk, then create the bootstrap configuration.

  1. Prepare filesystem, retrieve installation bits
mke2fs -j -L PRGMRDISK1 /dev/xvda1
mount /dev/xvda1 /mnt
mkdir -p /mnt/boot/grub
wget -O /mnt/boot/vmlinuz-INSTALL http://mirror.stanford.edu/yum/pub/centos/6.2/os/x86_64/images/pxeboot/vmlinuz
wget -O /mnt/boot/initrd-INSTALL http://mirror.stanford.edu/yum/pub/centos/6.2/os/x86_64/images/pxeboot/initrd.img
  1. Create grub configuration for install kit

This is more a convenience step, and it will ultimately be overwritten by the installer, though the kernel and ramdisk we got earlier will stick around if you do not format the filesystem. The file you need to create is /mnt/boot/grub/menu.lst. Replace [PASSWORD], [IP], [NETMASK], and [GATEWAY] with values appropriate for you and your system.

title C6-install
  root (hd0,0)
  kernel /boot/vmlinuz-INSTALL console=hvc0 vnc vncpassword=[PASSWORD] dns=, ip=[IP] netmask=[NETMASK] gateway=[GATEWAY] repo=http://mirror.stanford.edu/yum/pub/centos/6.2/os/x86_64
  initrd /boot/initrd-INSTALL
  1. Power off and restart instance.

Once you've created the menu.lst file, power off the rescue image, then start up from the prgmr console. While not strictly necessary, this ensures your new configuration is read. You should boot up and may be asked a few questions to set up the installation language and then asked to connect to your machine IP using VNC...

  1. Connect to complete installation using VNC.

When the console says it is ready for VNC connection, get your VNC viewer of choice and connect to [IP]:1. You should then see the graphical anaconda interface and be able to complete installation.

My recommendation for installation is to *not* format the disk (xvda1), and install there.

We have a report that, after installing, the bootloader didn't work. If you have trouble, try adding an entry like this to /boot/grub/menu.lst:

title C6
root (hd0,0)
kernel /boot/vmlinuz-2.6.32-220.el6.x86_64 console=hvc0 ro
root=/dev/xvda1 noquiet
initrd /boot/initramfs-2.6.32-220.el6.x86_64.img