OpenSolaris Xen domU

From Tardis
Revision as of 10:49, 26 July 2007 by Pert (talk | contribs) (New page: This page describes the installation of OpenSolaris on a Xen domU running under a Linux dom0. The following is based on the July 2007 update of OpenSolaris for Xen. == Getting the In...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This page describes the installation of OpenSolaris on a Xen domU running under a Linux dom0. The following is based on the July 2007 update of OpenSolaris for Xen.

Getting the Installation Media

The installer is available as DVD image from Sun's Download Centre here. It is distributed as an ISO file, which has been split into six parts and where each part has been zipped.

I downloaded each file, verified them using the supplied md5sums, and then ran the following from bash to unzip and recombine them:

for foo in `ls 66-0624-nd-iso-[a-f].zip`; do
    unzip -p $foo;
done >66-0624-nd.iso

Extracting the Kernel and Initial ramdisk

To boot OpenSolaris under Xen you need both a kernel and initial ramdisk available on your dom0. The documentation seems to assume that you are running an OpenSolaris dom0 and so will already have a copy of the kernel and ramdisk on your dom0. In our case, with a Linux dom0, we will need to extract the kernel and ramdisk from the ISO image like so:

mkdir /mnt/tmp
mount -o loop,ro 66-0624-nd.iso /mnt/tmp
cp /mnt/tmp/boot/x86.miniroot x86.miniroot-66-0624-nd
cp /mnt/tmp/boot/platform/i86xpv/kernel/unix unix-66-0624-nd
umount /mnt/tmp

Configuring Xen for the Installation

Before you can boot OpenSolaris to begin the installation you will need to create a Xen configuration file defining the virtual disk, virtual DVD drive, kernel, ramdisk, memory size and kernel parameters. Here's an example:

name = 'argolin'
memory = '1024'
disk = [ 'file:/mnt/tmp/66-0624-nd.iso,6:cdrom,r', 'phy:/dev/xenvg/argolin.disk,0,w' ]
vif = [ '' ]
on_shutdown = 'destroy'
on_reboot = 'destroy'
on_crash = 'destroy'
kernel = '/usr/lib/xen-solaris/unix-66-0624-nd'
ramdisk = '/usr/lib/xen-solaris/x86.miniroot-66-0624-nd'
extra = '/platform/i86xpv/kernel/unix -kd - nowin -B install_media=cdrom'

This creates a domU called argolin with 1024MB of RAM, a virtual DVD drive from the image in '/mnt/tmp/66-0624-nd.iso', a virtual disk from the device '/dev/xenvg/argolin.disk', the default virtual network interface and the kernel and ramdisk extracted earlier.

Note: The '-kd' kernel parameter causes the kernel to open the debugger as soon as possible after boot. This can be used to enable workarounds as described below.


/a/usr/bin/scp -S /a/usr/bin/ssh /a/platform/i86xpv/kernel/unix 10.0.0.1: