
Install instructions for rhel3 pv-on-hvm drivers
================================================

Note: These packages do not support booting from a paravirtualized
      disk.  Booting the kernel requires the use of the emulated
      IDE driver, while user-level application & data disks can
      use the paravirtualized block driver.

Installation:

 (1) 'rpm -ivh kmod-xenpv-{%release}.$(uname -m).rpm'

 (2) Reconfigure the virtual machine: switch nic from emulated
      to paravirtual (aka remove type=ioemu in the xen guest config file).

 (3) Add additional disk partitions/volumes to the virtual
     machine that will be accessed via the xen-vbd pv-disk driver:
     e.g., edit the xen guest config file:
        original: 
             disk = [ "file:/home/xen-guest-disks/rhel3_64_fv.dsk,hda,w"]
        additional xvd disk: 
             disk = [ "file:/home/xen-guest-disks/rhel3_64_fv.dsk,hda,w", 
                      "tap:aio:/home/xen-guest-disks/rhel3_64_fv_usr.dsk,xvda,w" ]
 
 (4)  Boot the virtual machine. 
      NOTE: you must use "xm create <virt-machine-name>
            or else the xen-vnif pv-network driver will not be connected to eth0 properly.
            A known bug, BZ 300531.

 (5) weak-modules support is not provided in this kit.
     So the proper xenpv drivers are not automagically added to a system.
     So, one has to do the following to configure the xen block & network drivers to
     run and see their respective devices:
	cp -R /lib/modules/2.4.21-50.EL[%kvariant]/extra/xenpv/%release /lib/modules/'uname -r'/extra/xenpv
	cd /lib/modules/'uname -r'/extra/xenpv/%release
	insmod xen-platform-pci.o
	insmod xen-balloon.o
	insmod xen-vbd.o
	insmod xen-vnif.o

    Note: Warnings will be generated by insmod when installing the binary driver modules
          due to RHEL3 having MODVERSIONS enabled.

 (6)  You might have to reconfigure network (use redhat-config-network)
      or edit /etc/sysconfig/network-scripts/ifcfg-eth0 due to the nic driver change.
      Edit /etc/modules.conf and change the eth0 alias to:  alias eth0 xen-vnif.

 (7) rhel3/linux-2.4 requires the creation of the block special devices
     for xen-vbd.  To do so, exec the following (after loading the drivers):
	!/bin/sh
	module="xvd"
	mode="664"
	major=`awk "\\$2==\"$module\" {print \\$1}" /proc/devices`
	# < mknod for as many or few partitions on xvd disk attached to FV guest >
	# change/add xvda to xvdb, xvdb etc. for 2nd, 3rd, etc., disk added in
	# in xen config file, respectively.
	mknod /dev/xvda0 b $major 0
	mknod /dev/xvda1 b $major 1
	mknod /dev/xvda2 b $major 2
		.
	mknod /dev/xvdb0 b $major 16
	mknod /dev/xvdb1 b $major 17
		.
		. 
	chgrp disk /dev/xvd*
	chmod $mode /dev/xvd*

    (a) mount pv disks to local mount points:
	mkdir /mnt/pvdisk_p0
	mount /dev/xvda0 /mnt/pvdisk_p0
		.
		.
		.

 (8) Building from sources
     A source rpm is provided.
     The kverrel & kverbase in the xenpv.spec file must be changed
     to match the kernel version that binary modules are being built for.
     Typically, that is the value returned from 'uname -r'.

 (9) ia64 binary rpm's and builds are not available at this time, but
     are expected in a future revision.

 (10) For performance reasons, "noapic" should be added to the kernel boot line
      in your system's grub.conf entry, e.g.,
          kernel /vmlinuz-2.4.21-52.EL ro root=/dev/VolGroup00/rhel3_x86_64 rhgb noapic

