Moving to Xen from Pre-Xen Nevada Bits

Several months back, I upgraded my Ultra 20 to SXDE 09/2007, which is based on Nevada build_70. Finally getting off my butt, I wanted to try out the Xen support that went into build_75. Some of you may be like me, and move to updated versions of OpenSolaris via bfu. But, since I've been bfu'ing atop build_70, bfu does the right thing and didn't include the SUNWxv\* packages in my update. By the time I'd hit build_80, I wanted to get Xen running, but didn't want to do a more formal upgrade of the OS.

Scrounging around the web, I didn't find a concise listing of what needed to be done, so here's my consolidation of steps:

1. Install the core Xen packages1

# pkgadd -d . SUNWxvmdomr SUNWxvmdomu SUNWxvmr SUNWxvmu SUNWxvmhvm SUNWxvmh SUNWxvmpv

2. Install the virt-install and supporting packages

# pkgadd -d . SUNWlibvirt SUNWurlgrabber SUNWvirtinst

3. Configure the /boot/grub/menu.lst to load Xen. This is described very well here

4. Once you've rebooted and the hypervisor is loaded, you should see a single domain, dom0, listed.

# xm list Name ID Mem VCPUs State Time(s) Domain-0 0 2891 1 r----- 1626.4

5. Install a guest. I did a Nevada build_78 guest.

# virt-install What is the name of your virtual machine? snv_78 How much RAM should be allocated (in megabytes)? 1024 What would you like to use as the disk (path)? /export/home/xen/snv_78.img Would you like to enable graphics support? (yes or no) no What is the install location? /build/iso/sol-nv-b78-x86-dvd-iso Starting install... Creating domain... 0 B 00:06 v3.0.4-1-xvm chgset 'Tue Dec 04 09:56:10 2007 +0000 13231:f6074ad033f3' SunOS Release 5.11 Version snv_78 64-bit Copyright 1983-2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. ...

The domU install took a lot longer than a typical install. Granted, I only have a single disk in the system, so maybe it was thrashing a bit. Memory was tight, but swap never got invoked. Not sure of the cause at this point. I also plan to make a Solaris 10 domU as well - that'll be handy for patch testing. The next frontier will be some non-Solaris clients...my initial attempts at Fedora and Ubuntu didn't go well....probably gotta get an AMD chip with virtualization support. Fodder for another blog...

:wq

1 If you build ON yourself, you can pull the packages from packages/i386/nightly[-nd] in your workspace. You could also pull the packages out of the cpio archives used with bfu. And it's always best to match the package versions to the ON kernel you're running (i.e. use build_80 packages on build_80).

Comments:

Installing onto a loopback file is slow - a real disk or (better) a ZFS volume is much faster. Also a network install is generally faster than installing from a CD.

You can install Fedora at least over http from one of the Fedora mirrors. However,
they broke their own code with Fedora 8, so it's easiest to just install Fedora 7
until we sync up with the fix needed.

Posted by John Levon on January 26, 2008 at 02:36 AM PST #

Thanks John....I did try installing Fedora 7 over http, but getting "ERROR: Could not find an installable distribution the install location". Get this local as well. I think it's because I'm on an older Ultra 20 and don't have virt support in my AMD.

Posted by Scott Davenport on January 29, 2008 at 02:34 AM PST #

Nope, Fedora 7 has para-virt support and this should just work.
What was your virt-install cmdline?

Posted by John Levon on January 29, 2008 at 03:20 AM PST #

Tried a couple...

# virt-install -n fedora_7 -f /export/home/xen/fedora_7.img -s 10 --vnc --vncport=5900 -p -r 768 -l http://mirror.cc.vt.edu/pub/fedora/linux/releases/7/Fedora/i386/iso/F-7-i386-DVD.iso

Starting install...
ERROR: Could not find an installable distribution the install location
# virt-install -n fedora_7 -f /export/home/xen/fedora_7.img -s 10 --nographics -p -r 768 -l http://mirror.cc.vt.edu/pub/fedora/linux/releases/7/Fedora/i386/iso/F-7-i386-DVD.iso

Starting install...
ERROR: Could not find an installable distribution the install location

Also tried using the interactive install. Same results. Maybe using the wrong ISO image?

Posted by Scott Davenport on January 29, 2008 at 04:51 AM PST #

Linux doesn't use HTTP installs like that (and can't install from an ISO anyway).

Try -l http://mirror.cc.vt.edu/pub/fedora/linux/releases/7/Fedora/i386/os/

Posted by John Levon on January 29, 2008 at 05:28 AM PST #

The following worked:
virt-install -n fedora_7 -p -r 768 -x "console=hvc0" -f /export/home/xen/fedora_7.img --nographics -l http://download.fedora.redhat.com/pub/fedora/linux/releases/7/Fedora/x86_64/os

Posted by Scott Davenport on January 29, 2008 at 08:29 AM PST #

Post a Comment:
Comments are closed for this entry.
About

user9148476

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today