Chapter 3. Installing and configuring the para-virtualized drivers
These sections detail installing and configuring the para-virtualized drivers for Microsoft Windows guests on Red Hat Enterprise Linux.
Note that this guide is about Xen-based virtualized guests. Para-virtualized drivers for KVM-based guests are covered in the Virtualization Guide
3.2. Installing the para-virtualized drivers
This section details the process for installing the para-virtualized drivers on newly created Microsoft Windows guests using virsh or virt-manager.
You can access the Microsoft Windows para-virtualized drivers installer from your guest using either:
hosting the files on a network accessible to the guest, or
by creating a virtualized CD-ROM device on the guest of the installation disk .iso file.
This guide describes installation from the para-virtualized installer disk as a virtualized CD-ROM device.
Download the para-virtualized drivers package with
yum. The package names in the list below are to assist you with choosing the right package for your guest.
Para-virtualized drivers package names
xenpv-win-32bit
The driver package for the 32 bit versions of Windows.
xenpv-win-32bit-debug
The package for debugging the drivers for the 32 bit versions of Windows.
xenpv-win-64bit
The driver package for the 64 bit versions of Windows.
xenpv-win-64bit-debug
The package for debugging the drivers for the 64 bit versions of Windows.
The debug packages (for example, xenpv-win-64bit-debug) are used for debugging the para-virtualized driver inside of the windows guests. These drivers provide users with more verbose reporting and additional tools for debugging and data logging.
To install the .iso file containing the drivers, use yum on a host with the Virtualization channel in RHN enabled.
For the 32 bit package execute the follow command:
# yum install xenpv-win-32bit
For the 64 bit package execute the follow command:
# yum install xenpv-win-64bit
This extracts the packaged files to the
/usr/share/xenpv-win directory. The
Bash output below shows the contents of a
/usr/share/xenpv-win directory with both 32 bit and 64 bit drivers and the debugging packages installed. Note the symbolic links (denoted by the
-> symbol) linking to the newest version of the para-virtualized drivers.
$ ls -al /usr/share/xenpv-win
total 13472
drwxr-xr-x 2 root root 4096 Jul 14 17:29 .
drwxr-xr-x 214 root root 4096 Jul 14 17:29 ..
-rw-r--r-- 1 root root 3325952 Jul 11 14:58 xenpv-win-32bit-0.97.1.iso
-rw-r--r-- 1 root root 3422208 Jul 11 14:58 xenpv-win-32bit-debug-0.97.1.iso
lrwxrwxrwx 1 root root 32 Jul 14 17:29 xenpv-win-32bit-debug.iso -> xenpv-win-32bit-debug-0.97.1.iso
lrwxrwxrwx 1 root root 26 Jul 14 17:29 xenpv-win-32bit.iso -> xenpv-win-32bit-0.97.1.iso
-rw-r--r-- 1 root root 3454976 Jul 11 14:58 xenpv-win-64bit-0.97.1.iso
-rw-r--r-- 1 root root 3522560 Jul 11 14:58 xenpv-win-64bit-debug-0.97.1.iso
lrwxrwxrwx 1 root root 32 Jul 14 17:29 xenpv-win-64bit-debug.iso -> xenpv-win-64bit-debug-0.97.1.iso
lrwxrwxrwx 1 root root 26 Jul 14 17:29 xenpv-win-64bit.iso -> xenpv-win-64bit-0.97.1.iso
The .iso files in the
/usr/share/xenpv-win directory are mounted as virtual CD-ROM devices for the Windows guests in order to install the drivers.
To create the virtualized CD-ROM device you must choose to use either virt-manager (graphical) or virsh (command line).
Procedure 3.1. Using virt-manager to mount a CD-ROM image for a Windows guest
Open virt-manager, select your virtualized guest from the list of virtual machines and press the Details button.
Click the Add button in the Details panel.
This opens a wizard for adding the new device. Select
Storage device from the drop down menu, then click
Forward.
Choose the Simple File option and set the file location of the para-virtualized drivers .iso file. The location of the .iso files is /usr/share/xenpv-win if you used yum to install the para-virtualized driver packages.
If the drivers are stored physical CD, use the Normal Disk Partition option.
Set the
Device type to
IDE cdrom and click
Forward to proceed.
The disk has been assigned and is available for the guest once the guest is started. Click
Finish to close the wizard or back if you made a mistake.
Procedure 3.2. Mounting the driver installation CD-ROM image with virsh on an active guest
Determine the required parameters, including:
An active domain. In the example the domain is called w2k3_32.
An unallocated block device label. The example in the next step uses hdc, if hdc is already allocated choose the next unallocated letter for example hdd. You can verify which drive labels are in use by reading the configuration file generated with the virsh dumpxml w2k3_32 w2k3_32guest.xml. This command generates a configuration file called w2k3_32guest.xml in the current directory.
The correct driver for your windows guest. In the example the xenpv-win-32bit.iso from the xenpv-win-32bit package.
Use the
virsh command with the parameters modified for your guest.
# virsh attach-disk w2k3_32/usr/share/xenpv-win/xenpv-win-32bit.isohdc --driver file --type cdrom --mode readonly
Para-virtualized drivers executable file names
| Executable file name | Description |
|---|
xenpv-win-32bit.exe | The para-virtualized driver package for 32 bit Microsoft Windows installations. This covers most installations. |
xenpv-win-32bit-debug.exe | The para-virtualized driver debugging package for 32 bit Microsoft Windows installations. |
xenpv-win-64bit.exe | The para-virtualized driver package for 64 bit Microsoft Windows installations. This covers Windows XP Professional® x64 (Service Pack 1 and Service Pack 2), Windows Vista® 64 bit (release and Service Pack 1), Windows Server® 2003 (64 bit) Service Pack 2 and Windows Server® 2003 R2 (64 bit) Service Pack 2. |
xenpv-win-64bit-debug.exe | The para-virtualized driver debugging package for Microsoft Windows 64 bit installations. |
All mentions of the term "64 bit" in this document refer to AMD64 and Intel 64 systems. Itanium systems are not supported at this time by these drivers.
Procedure 3.3. Installing the para-virtualized drivers on the Windows® guest
The installer may start automatically if you added the virtualized CD-ROM to an active guest. If this occurs skip this step and continue from step 2.
Start the installer by double clicking the CD drive (E in the example below).
If Autorun is disabled, start the installer by double clicking the
.exe file on the CD.
Once the file is open, the
Welcome screen appears. Select
Next to proceed.
You are now prompted to select the type of install you want.
The Complete option installs the network driver, disk driver and source code.
The
Custom option opens another dialog box from which you can choose individual components to install.
Once you have made your selection, click
Next to continue.
Select
Install to complete the installation.
The unsigned driver warning (
Network and Disk driver has not been digitally signed) dialog box pops up. Select
Continue Anyway to install drivers. This dialog box will appear four times, twice for each driver,
rhelscsi and then
rhelnet.
Future releases of Red Hat Para-virtualized Driver for Microsoft Windows will be digitally signed by Windows Hardware Quality Labs (WHQL). Once certified the warning will not appear.
Select
Show the README file to view the release notes for the drivers.
Click
Finish to complete the installation.
Reboot the guest.
The the para-virtualized drivers should now be installed on the Microsoft Windows guest.
3.3. Post-installation host configuration
This section covers the post-installation configuration processes required to utilize the para-virtualized drivers. Para-virtualized drivers must be installed on the guest before commencing this section.
Network devices available to guests automatically use the para-virtualized drivers when the guests are rebooted after installation of the drivers. Adding network devices requires special configuration steps, refer to
Section 4.2, “Adding para-virtualized network devices”.
Block devices require additional configuration.
This section covers the procedure for adding and modifying disk entries to enable the para-virtualized drivers. Each guest requires modification in order to utilize the drivers.
Para-virtualized drivers cannot be used for the disk containing the Windows system files. Only secondary disks can be used with the para-virtualized drivers at this time.
Only make changes to the configuration files in the /etc/xen directory with the libvirt based tools, virsh and virt-manager. Manually editing configuration files in the /etc/xen directory is not recommended and could render your guests inoperable.
Use virsh dumpxml to export the configuration of the virtual machine.
# virsh dumpxml virt-machine-name > guest.xml
Update the guest configuration to enable the para-virtualized drivers. Red Hat Enterprise Linux 5.2 automatically enables para-virtualized network drivers. Only the block and disk device drivers must be updated.
The guest.xml file locate the section containing the disk configuration should resemble this example. This example uses a hard disk partition called /dev/hda6.
<disk type='file' device='disk'>
<driver name='file'/>
<source file='/var/lib/xen/images/disk1.img'/>
<target dev='hda'/>
</disk>
<disk type='file' device='disk'>
<driver name='file'/>
<source file='/dev/hda6'/>
<target dev='hdb'/>
</disk>
In this example, the secondary disk updated to use the para-virtualized driver. Change the driver from “file” to “tap:aio” and change the target device from “hdb” to “xvdb”.
<disk type='file' device='disk'>
<driver name='file'/>
<source file='/var/lib/xen/images/disk1.img'/>
<target dev='hda'/>
</disk>
<disk type='file' device='disk'>
<driver name='tap' type='aio'/>
<source file='/dev/hda6'/>
<target dev='xvdb'/>
</disk>
Redefine the guest using the updated guest configuration file, guest.xml.
# virsh define guest.xml
The guest can now be restarted with virt-manager or virsh. To restart a guest named virt-machine-name:
# virsh reboot virt-machine-name