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.
Block device 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.

Warning

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
Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.