Installing Redhat Enterprise Server 5 under Sun xVM/Xen
Installing Redhat Enterprise Server 5 in a Sun xVM Xen environment is straightforward and easy.
We will create a 15G zfs block volume to hold the server data to boot:
Then, I had to mount the ISO file on a mountpoint - I chose "/cdrom":
After that, I shared this cdrom directory via NFS:
My machine had the DNS name "pgt01", so I had to type "nfs:pgt01:/cdrom" as location so that the "virt-install" was able to find the relevant components AND the installer was able to mount the installation media!
The result:
After a short instant, the following screen should appear:

Chose your appropriate language. To change between input fields use the TAB key - so press TAB to move the cursor to the OK field and press Return:

As I had a DHCP server on my network segment it was simple - remember your virtual Redhat machine ahs to find your Dom0 machine in the network under the name given with the "virt-install" command (pgt01 in my case), otherwise the NFS mount of the installation media will fail!
After "OK" this will appear:

We used "--nographics" in the "virt-install" command above. So you won't be able to use VNC. If you want to use a graphical console repeat the installation with "--vnc" instead of "--nographics."
I chose "Use text mode":

The system "sees" our configured 15GB device (ZFS block volume created in the first step) and yes, it has no usable partition table. So "Yes", I wanted to initialize this:

I just "clicked" (how would you say on a text console? "selected"?) on "OK" (pressing TAB until the cursor marked the OK "button"). The system just wants to make sure that I know that I the partition table will be created - as my zfs block volume really was empty I can sleep well with this.

In this screen DO NOT DESELECT "virtualization". Yes, we won't use Redhat to virtualize but we need the paravirtualized Xen Kernel! And its included in the "virtualization" selection!
Choose the other two like your needs are.
Next step: The installation programs formats the "hard drive":

After this selection, the program will begin to install:

After some moments (it is really fast!), the following should appear:

You're almost done! The "reboot" is very fast - your console session will continue like this:

After this point, it is the same procedure as a normal Redhat ES install. Just make the settings you want and you're done! You may switch to the Redhat Server console using the "virsh console" command:

Press Ctrl-Alt-6 to quit the Xen console.
With "rhn_register" you may register your machine with the Redhat Network and then you are able to install the updates.
Your machine will appear as para-virtualized in your Redhat server list on redhat.com.
Mission accomplished.
We will create a 15G zfs block volume to hold the server data to boot:
# zfs create -b 4k -V 15G xvm/redhat.zvolIn my environment, I use a zpool named "xvm" to hold the virtual machine data. "xvm/redhat.zvol" has become a block device with a normal block device entry: /dev/zvol/dsk/xvm/redhat.zvol.
Then, I had to mount the ISO file on a mountpoint - I chose "/cdrom":
# mount -F hsfs /xvm/ISO/rhel-server-5.4-x86_64-dvd.iso /cdromThat's nice from Solaris to let me mount an iso file so easily onto a directory.
After that, I shared this cdrom directory via NFS:
# share -o ro /cdromThat's it! Now I was able to start the installation:
# virt-install --name "Redhat" --disk path=/dev/zvol/dsk/xvm/redhat.zvol --paravirt --ram 1024 --os-type linux --os-variant rhel5 --location nfs:pgt01:/cdrom --nographics
My machine had the DNS name "pgt01", so I had to type "nfs:pgt01:/cdrom" as location so that the "virt-install" was able to find the relevant components AND the installer was able to mount the installation media!
The result:
Starting install... Retrieving file .treeinfo 100% |=========================| 442 B 00:00 Retrieving file vmlinuz.. 100% |=========================| 1.9 MB 00:00 Retrieving file initrd.im 100% |=========================| 7.1 MB 00:00 Creating domain... 0 B 00:01 Connected to domain 67 Escape character is '^]' Bootdata ok (command line is method=nfs:pgt01:/cdrom) Linux version 2.6.18-164.el5xen (mockbuild@x86-003.build.bos.redhat.com) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-46)) #1 SMP Tue Aug 18 15:59:52 EDT 2009 BIOS-provided physical RAM map: Xen: 0000000000000000 - 0000000040800000 (usable) No mptable found. Built 1 zonelists. Total pages: 264192 Kernel command line: method=nfs:pgt01:/cdrom Initializing CPU#0... and many lines more..
After a short instant, the following screen should appear:

Chose your appropriate language. To change between input fields use the TAB key - so press TAB to move the cursor to the OK field and press Return:

As I had a DHCP server on my network segment it was simple - remember your virtual Redhat machine ahs to find your Dom0 machine in the network under the name given with the "virt-install" command (pgt01 in my case), otherwise the NFS mount of the installation media will fail!
After "OK" this will appear:

We used "--nographics" in the "virt-install" command above. So you won't be able to use VNC. If you want to use a graphical console repeat the installation with "--vnc" instead of "--nographics."
I chose "Use text mode":

The system "sees" our configured 15GB device (ZFS block volume created in the first step) and yes, it has no usable partition table. So "Yes", I wanted to initialize this:

I just "clicked" (how would you say on a text console? "selected"?) on "OK" (pressing TAB until the cursor marked the OK "button"). The system just wants to make sure that I know that I the partition table will be created - as my zfs block volume really was empty I can sleep well with this.

In this screen DO NOT DESELECT "virtualization". Yes, we won't use Redhat to virtualize but we need the paravirtualized Xen Kernel! And its included in the "virtualization" selection!
Choose the other two like your needs are.
Next step: The installation programs formats the "hard drive":

After this selection, the program will begin to install:

After some moments (it is really fast!), the following should appear:

You're almost done! The "reboot" is very fast - your console session will continue like this:
rebooting system Restarting system. libvir: error : Unknown failure Connection to domain 67 closed. Guest installation complete... restarting guest. Connected to domain 68 Escape character is '^]' rtc: IRQ 8 is not free. rtc: IRQ 8 is not free. i8042.c: No controller found. Red Hat nash version 5.1.19.6 starting Reading all physical volumes. This may take a while... Found volume group "VolGroup00" using metadata type lvm2 2 logical volume(s) in volume group "VolGroup00" now active Welcome to Red Hat Enterprise Linux Server Press 'I' to enter interactive startup.
... many lines omitted, it justs starts your virtual Redhat Enterprise machine ...
After booting your virtual machine, the following will appear:
After booting your virtual machine, the following will appear:

After this point, it is the same procedure as a normal Redhat ES install. Just make the settings you want and you're done! You may switch to the Redhat Server console using the "virsh console" command:

Press Ctrl-Alt-6 to quit the Xen console.
With "rhn_register" you may register your machine with the Redhat Network and then you are able to install the updates.
Your machine will appear as para-virtualized in your Redhat server list on redhat.com.
Mission accomplished.
0 TrackBacks
Listed below are links to blogs that reference this entry: Installing Redhat Enterprise Server 5 under Sun xVM/Xen.
TrackBack URL for this entry: http://southbrain.com/mt/mt-tb.cgi/103

Leave a comment