Use this procedure to set up the OpenSolaris 2008.11 or 2009.06 release as an xVM dom0.
Create a separate boot environment, if needed.
# pfexec beadm create -a -d xvm xvm |
If you're running a recent version of OpenSolaris, you can install the xvm-gui cluster instead of the individual packages.
Otherwise, install the required packages.
# pfexec beadm mount xvm /tmp/xvm-be # pfexec pkg -R /tmp/xvm-be install SUNWvirt-manager SUNWxvm SUNWvdisk SUNWvncviewer # pfexec beadm umount xvm |
Run the following AWK script over the menu.1st file that controls the GRUB menu. This step is necessary for beadm to reboot into xVM. The menu.1st file is typically located in the /pool-name/boot/grub directory on systems with a ZFS root. The correct menu.1st file is shown in Step 4 of this procedure.
$ awk ' /^title/ { xvm=0; } /^title.xvm$/ { xvm=1; } /^(splashimage|foreground|background)/ { if (xvm == 1) next } /^kernel\$/ { if (xvm == 1) { print("kernel\$ /boot/\$ISADIR/xen.gz") sub("^kernel\\$", "module$") gsub("console=graphics", "console=text") gsub("i86pc", "i86xpv") $2=$2 " " $2 } } { print }' /rpool/boot/grub/menu.lst >/var/tmp/menu.lst.xvm |
Verify that the AWK script worked properly.
$ tail /var/tmp/menu.lst.xvm #============ End of LIBBE entry ============= title xvm findroot (pool_rpool,0,a) bootfs rpool/ROOT/xvm kernel$ /boot/$ISADIR/xen.gz module$ /platform/i86xpv/kernel/$ISADIR/unix /platform/i86xpv/kernel/$ISADIR/unix -B $ZFS-BOOTFS,console=text module$ /platform/i86pc/$ISADIR/boot_archive #============ End of LIBBE entry ============= |
Create a new GRUB entry in /rpool/boot/grub/menu.1st.xvm and then reboot.
Enable the xVM services.
# svcadm enable -r xvm/virtd ; svcadm enable -r xvm/domains |
You should now be able to install guest domains.