Red Hat ENTERPRISE LINUX 5 - VIRTUALIZATION GUIDE Instalační příručka Strana 1

Procházejte online nebo si stáhněte Instalační příručka pro Servery Red Hat ENTERPRISE LINUX 5 - VIRTUALIZATION GUIDE. Red Hat ENTERPRISE LINUX 5 - VIRTUALIZATION GUIDE Installation guide Uživatelská příručka

  • Stažení
  • Přidat do mých příruček
  • Tisk
  • Strana
    / 361
  • Tabulka s obsahem
  • ŘEŠENÍ PROBLÉMŮ
  • KNIHY
  • Hodnocené. / 5. Na základě hodnocení zákazníků

Shrnutí obsahu

Strany 1 - Virtualization Guide

Scott Radvan Dayle Parker Christopher CurranJan Mark HolzerRed Hat Enterprise Linux 5Virtualization GuideVirtualization Documentation

Strany 2

PrefaceThe Red Hat Enterprise Linux Virtualization Guide covers all aspects of using and managingvirtualization products included with Red Hat Enterpr

Strany 3 - Virtualization Documentation

Press Forward to continue.10. ⁠Memo ry an d C PU allo cat ionThe Memory and CPU Allocation window displays. Choose appropriate values for thevirtual

Strany 4 - Abstract

Press Forward to continue.11. ⁠Verif y an d st art g u est in st allat io nVerify the configuration.⁠Chapt er 8 . G uest operat ing syst em inst a

Strany 5 - Table of Contents

Press Finish to start the guest installation procedure.12. ⁠Inst allin g R ed H at En t erp rise Lin u xComplete the Red Hat Enterprise Linux 5 in

Strany 6

ImportantPresently, Red Hat Enterprise Linux hosts on the Itanium® architecture does not support fullyvirtualized Windows XP guests. Only Windows Ser

Strany 7

If you selected KVM or Xen earlier (step Step 1 ) you must use the hypervisor you selected.This example uses the KVM hypervisor.Windows can only be in

Strany 8

WarningFor ISO image files and guest storage images it is recommended to use the /var/lib/libvirt/images/ directory. Any other location will require a

Strany 9

Press Forward to continue.6. The Storage window displays. Choose a disk partition, LUN or create a file-based image forthe guest's storage.All i

Strany 10 - 2. Document Convent ions

Choose the appropriate size for the guest on your selected storage type and click theForward button.NoteIt is recommend that you use the default direc

Strany 11

Press Forward to continue.8. The Memory and CPU Allocation window displays. Choose appropriate values for thevirtualized CPUs and RAM allocation. The

Strany 12

9. Before the installation continues you will see the summary screen. Press Finish to proceedto the guest installation:⁠Chapt er 8 . G uest operat i

Strany 13 - 3. We need your feedback

The first example highlights a particular key to press. The second example highlights a keycombination: a set of three keys pressed simultaneously.If

Strany 14 - 5. Types of Virt ualizat ion

10. You must make a hardware selection so open a console window quickly after the installationstarts. Click Finish then switch to the virt -man ag er

Strany 15

11. The installation continues with the standard Windows installation.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res107

Strany 16

12. Partition the hard drive when prompted.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e108

Strany 17 - Hat Enterprise Linux

13. After the drive is formatted, Windows starts copying the files to the hard drive.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu

Strany 18

14. The files are copied to the storage device, Windows now reboots.15. Restart your Windows guest:# virsh start WindowsGuestWhere WindowsGuest is t

Strany 19

17. If your installation seems to get stuck during the setup phase, restart the guest with virsh reboot WindowsGuestName. When you restart the virtua

Strany 20

18. After setup has finished you will see the Windows boot screen:19. Now you can continue with the standard setup of your Windows installation:Red

Strany 21

20. The setup process is complete.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res113

Strany 22 - 4.1. Hyper-V drivers

8.4. Inst alling Windows Server 2003 as a fully virt ualized guestThis chapter describes installing a fully virtualized Windows Server 2003 guest with

Strany 23 - 5.2. KVM limit at ions

3. Complete the rest of the installation.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res115

Strany 24 - 5.3. Xen limit at ions

2.2. Pull-quot e Convent ionsTerminal output and source code listings are set off visually from the surrounding text.Output sent to a terminal is set

Strany 25 - # modprobe loop

4. Windows Server 2003 is now installed as a fully guest.8.5. Inst alling Windows Server 2008 as a fully virt ualized guestThis section covers instal

Strany 26

O p en virt - man ag erStart virt-manager. Launch the Virt u al Machin e Man ag er application from theAp p licat io n s menu and Syst em To o ls sub

Strany 27 - ⁠Part II. Installation

Provide a name for your guest. Punctuation and whitespace characters are not permitted inversions before Red Hat Enterprise Linux 5.5. Red Hat Enterpr

Strany 28

Press Forward to continue.6. ⁠Select t h e in st allat io n met ho dFor all versions of Windows you must use local install media, either an ISO ima

Strany 29

Press Forward to continue.7. ⁠Locat e in st allat io n med iaSelect ISO image location or CD -ROM or DVD device. This example uses an ISO file image

Strany 30

Press Open to confirm your selection.c. The file is selected and ready to install.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu re

Strany 31 - # yum install xen kernel-xen

Press Forward to continue.WarningFor ISO image files and guest storage images, the recommended directory to use is the/var/lib/libvirt/images/ directo

Strany 32

Press Forward to continue.9. ⁠Net wo rk set u pSelect either Virtual network or Shared physical device.The virtual network option uses Network Addres

Strany 33

Press Forward to continue.10. ⁠Memo ry an d C PU allo cat ionThe Memory and CPU Allocation window displays. Choose appropriate values for thevirtual

Strany 34

Press Forward to continue.11. ⁠Verif y an d st art g u est in st allat io nVerify the configuration.⁠Chapt er 8 . G uest operat ing syst em inst a

Strany 35 - # yum install kvm

WarningWarnings should not be ignored. Ignoring warnings will most likely cause data loss.3. We need your feedbackIf you find a typographical error in

Strany 36

Press Finish to start the guest installation procedure.12. ⁠Inst allin g Win d o wsRed Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e126

Strany 37

Complete the Windows Server 2008 installation sequence. The installation sequence is notcovered by this guide, see Microsoft's documentation for

Strany 38 - 4. New g u est wiz ard

⁠Part III. ConfigurationConfiguring Virtualization in Red Hat Enterprise LinuxThese chapters cover configuration procedures for various advanced virtu

Strany 39

Chapter 9. Virtualized storage devicesThis chapter covers installing and configuring storage devices in virtual machines. The term blockdevices refers

Strany 40

# virsh dumpxml rhel5FV > rhel5FV.xmlThis saves the configuration settings as an XML file which can be edited to customize theoperations and device

Strany 41

a. Create a sparse file using the dd command. Sparse files are not recommended due todata integrity and performance issues. Sparse files are created

Strany 42

# fdisk /dev/sdbCommand (m for help):b. Press p for a primary partition.Command action e extended p primary partition (1-4)c. Choose an avai

Strany 43

System administrators use additional hard drives for to provide more storage space or to separatesystem data from user data. This procedure, Procedure

Strany 44

Systems which are not running multipath must use Single path configuration. Systems running multipath can use Multiple path configuration.Sin g le pat

Strany 45

/sbin/start_udevNetworked storage devices with configured rules now have persistent names on all hosts where thefiles were updated This means you can

Strany 46

Virtualization is a broad computing term for running software, usually operating systems,concurrently and isolated from other programs on one system.

Strany 47

Chapter 10. Network ConfigurationThis page provides an introduction to the common networking configurations used by libvirt basedapplications. This in

Strany 48 - DEVICE=installation

libvirt adds iptables rules which allow traffic to and from guests attached to the virbr0 devicein the INPUT, FORWARD, OUTPUT and POSTROUTING chains.

Strany 49

# chkconfig NetworkManager off# chkconfig network on# service NetworkManager stop# service network startNoteAs an alternative to turning off NetworkMa

Strany 50

NoteIP address configuration, be it dynamic or static, should be configured on the bridge itself (forexample, in the ifcfg-br0 file). Network access w

Strany 51

Chapter 11. Pre-Red Hat Enterprise Linux 5.4 Xen networkingThis chapter covers special topics for networking and network configuration with the Xen hy

Strany 52

Below is the commented out line and the new line, containing the network-xen-multi-bridge parameter to enable multiple network bridges:#network-script

Strany 53

ImportantThis section describes manually adding network bridges. This procedure is not required orrecommended for all versions of Red Hat Enterprise L

Strany 54

DEVICE=dummy0BOOTPROTO=noneONBOOT=yesUSERCTL=noIPV6INIT=noPEERDNS=yesTYPE=EthernetNETMASK=255.255.255.0IPADDR=10.1.1.1ARP=yes3. Bind xenbr0 to dummy0

Strany 55

echo "IP forwarding set to `cat /proc/sys/net/ipv4/ip_forward`" echo "done." ;;*)echo "Usage: $0 {start|restart|status}"

Strany 56

range=10.1.1.10,10.1.1.50,255.255.255.0,12hModify dhcp-option to override the default route supplied by dnsmasq, which assumes therouter is the same m

Strany 57

In essence, virtualization increases flexibility by decoupling an operating system and the servicesand applications supported by that system from a sp

Strany 58

Chapter 12. Xen Para-virtualized DriversPara-virtualized drivers provide increased performance for fully virtualized Red Hat Enterprise Linuxguests. U

Strany 59

drivers bring many of the performance advantages of para-virtualized guest operating systems tounmodified operating systems because only the para-virt

Strany 60

Red Hat Enterprise Linux 5 requires:kmod-xenpv.Red Hat Enterprise Linux 4 requires:kmod-xenpv,modules-init-tools (for versions prior to Red Hat Enterp

Strany 61

i686-PAE Supportedi686-SMP Supported (Intel) Supported i686-HUGEMEM Supported (Intel) Supported x86_64 Supported (AMD) Supported Supportedx86_64-SMP

Strany 62

For Red Hat Enterprise Linux 3 based guest operating systems you must use the processor specifickernel and para-virtualized driver RPMs as seen in the

Strany 63

NoteIf you are installing a new guest system, in order to gain maximal benefit from the para-virtualized block device drivers, you should create the g

Strany 64

<disk type='file' device='disk'> <driver name='file'/> <source file='/dev/hda6'/> <tar

Strany 65

4. Use the commands below load the para-virtualized driver modules. %kvariant is the kernelvariant the para-virtualized drivers have been build again

Strany 66

Modify each disk entry, as desired, to use the para-virtualized by changing the driverelements as shown below.<disk type='file' device=&a

Strany 67 - Click OK to continue

# mknod /dev/xvdd b $major 32# mknod /dev/xvdd1 b $major 33Now you should verify the partitions which you have created are available.[root@rhel3]# cat

Strany 68

complementary workloads in your organization, you can dynamically allocate resources to theapplications which are currently experiencing the greatest

Strany 69

ImportantThe Itanium (ia64) binary RPM packages and builds are not presently available.12.3.3. Inst allat ion and Configurat ion of Para-virt ualiz ed

Strany 70 - Click Forward

Add any additional disk partitions, volumes or LUNs to the guest so that they can beaccessed via the para-virtualized (xen-vbd) disk driver.For each a

Strany 71

In the above output, you can see the partitioned device “ xvdb” is available to the system.The procedure below adds the new device to the guest and m

Strany 72

NoteThese packages do not support booting from a para-virtualized disk. Booting the guestoperating system kernel still requires the use of the emulate

Strany 73

3 1 104391 hda1 3 2 10377990 hda2 202 0 64000 xvdb 202 1 32000 xvdb1 202 2 32000 xvdb2 253

Strany 74

8139cp8139tooe10002. Remove the old network scripts from the /etc/sysconfig/network-scripts directory.3. Reboot the guest. The default network inter

Strany 75 - # virsh reboot rhel5PV

5. Select the 'Xen Virt ual Et hern et Card ( et h 0) ' entry and click 'Forward'.Configure the network settings as required.R

Strany 76

6. Complete the configuration by pressing the 'Apply' button.7. Press the 'Activate' button to apply the new settings and restar

Strany 77

8. You should now see the new network interface with an IP address assigned.ifconfig eth0eth0 Link encap:Ethernet HWaddr 00:16:3E:49:E4:E0

Strany 78 - 17. Configure the firewall

Add an additional entry to the “vif=” section of the configuration file similar to the one seen below.vif = [ "mac=00:16:3e:2e:c5:a9,bridge=xenb

Strany 79

⁠Part I. Requirements and Limitations for Virtualization with RedHat Enterprise LinuxSystem requirements, support restrictions and limitationsThese ch

Strany 80

disk = [ "file:/var/lib/libvirt/images/rhel5_64_fv.dsk,hda,w", "tap:aio:/var/lib/libvirt/images/UserStorage1.dsk,xvda,w", &q

Strany 81

Chapter 13. KVM Para-virtualized DriversPara-virtualized drivers are available for virtualized Windows guests running on KVM hosts. Thesepara-virtuali

Strany 82

using a virtualized CD-ROM device of the driver installation disk .iso file, orusing a virtualized floppy device to install the drivers during boot ti

Strany 83

3. Select t h e d evice typ eThis opens a wizard for adding the new device. Select Storage from the dropdown menu.⁠Chapt er 1 3. KVM Para- virt uali

Strany 84

Click the Forward button to proceed.4. Select t h e ISO fileChoose the File (disk image) option and set the file location of the para-virtualizeddr

Strany 85

6. Reb o o tReboot or start the guest to add the new device. Virtualized IDE devices require a restartbefore they can be recognized by guests.Once th

Strany 86

2. Select t h e correct in st allat io n f ilesThere are four files available on the disc. Select the drivers you require for your guest'sarc

Strany 87 - Click the Forward button

Press Next to continue.b. Co n f irm t h e excep t io nWindows may prompt for a security exception.Press Yes if it is correct.c. Fin ish⁠Chapt er 1

Strany 88

Press Finish to complete the installation.4. In st all t h e n et wo rk d evice d rivera. St art t h e n et wo rk d evice driver in st allat io nDo

Strany 89

Press Next to continue.b. Perf o rman ce set tin gThis screen configures advanced TCP settings for the network driver. TCP timestampsand TCP window s

Strany 90

Chapter 1. System requirementsThis chapter lists system requirements for successfully running virtualization with Red Hat EnterpriseLinux.The requirem

Strany 91

Windows may prompt for a security exception.Press Yes if it is correct.d. Fin ishPress Finish to complete the installation.5. Reb o o tReboot the gu

Strany 92

Change the device configuration to use the para-virtualized drivers (Section 13.3, “ Using KVM para-virtualized drivers for existing devices” ) or ins

Strany 93

Install the drivers firstEnsure the drivers have been installed on the Windows guest before proceeding to install newdevices. If the drivers are unava

Strany 94

5. Press Finish to save the device.⁠Chapt er 1 3. KVM Para- virt ualized Drivers179

Strany 95

6. Reboot the guest. The device may not be recognized until the Windows guest restarts.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e180

Strany 96

Chapter 14. Installing Red Hat Enterprise Linux 6 as a Xen gueston Red Hat Enterprise Linux 5This chapter describes the installation of Red Hat Enterp

Strany 97

NoteRed Hat Enterprise Linux can be installed without a graphical interface or manualinput. Use a Kickstart file to automate the installation process.

Strany 98

Fig u re 14 .1. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.4. Name t he virt u al mach in eProvide a name for your virtua

Strany 99

Fig u re 14 .2. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.5. Select t h e virt u aliz at io n met h o dSelect the appr

Strany 100

Fig u re 14 .3. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.6. Select t h e in st allat io n met h o d and t yp eSelect

Strany 101 - Verify the configuration

KVM requ iremen t sThe KVM hypervisor requires:an Intel processor with the Intel VT and the Intel 64 extensions, oran AMD processor with the AMD -V an

Strany 102

Fig u re 14 .4 . T h e virt ual mach in e creat io n wiz ardClick Forward to continue.7. Lo cat e in st allat io n med iaEnter the location of the

Strany 103 - Important

Fig u re 14 .5. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.8. St o rag e set u pImportantXen file-based images should be

Strany 104

Fig u re 14 .6 . T h e virt ual mach in e creat io n wiz ardClick Forward to continue.NoteLive and offline migrations require guests to be installed

Strany 105

Fig u re 14 .7. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.10. Memo ry an d CPU allo cat io nThe Memory and CPU Allocat

Strany 106

Fig u re 14 .8. T h e virt u al mach in e creat io n wiz ardClick Forward to continue.11. Verif y an d st art g u est in st allat io nVerify the

Strany 107

Fig u re 14 .9 . T h e virt ual mach in e creat io n wiz ardClick Finish to start the guest installation procedure.12. In st allin g Red Hat En t

Strany 108

Chapter 15. PCI passthroughThis chapter covers using PCI passthrough with Xen and KVM hypervisors.KVM and Xen hypervisors support attaching PCI device

Strany 109

En able AMD IO MMU ext en sio n sThe AMD IOMMU extensions are required for PCI passthrough with Red Hat Enterprise Linux. Theextensions must be enable

Strany 110

Each PCI device is identified by a string in the following format (where 8086 is a variable thatin this case represents Intel equipment, and **** is a

Strany 111

Run virsh edit (or virsh attach device) and add a device entry in the <devices> sectionto attach the PCI device to the guest. Only run this comm

Strany 113

Chapter 2. Xen restrictions and supportRed Hat Enterprise Linux 5 supports various combinations for hosts and guests. Processor andmemory limitations

Strany 114 - # virsh start WindowsGuest

Each PCI device is identified by a string in the following format (where 8086 is a variable thatin this case represents Intel equipment, and **** is a

Strany 115

5. Ad d t h e n ew d eviceSelect Ph ysical Ho st Device from the Hardware type list. The Ph ysical Ho st Devicerepresents PCI devices. Click Forwar

Strany 116

6. Select a PCI d eviceSelect an unused PCI device. Note that selecting PCI devices presently in use on the hostcauses errors. In this example a PCI

Strany 117

7. Co nf irm t h e n ew d eviceClick the Finish button to confirm the device setup and add the device to the guest.⁠Chapt er 1 5. PCI passt hrough199

Strany 118

The setup is complete and the guest can now use the PCI device.15.3. PCI passt hrough wit h virt -inst allTo use PCI passthrough with the virt-install

Strany 119

NoteComparing lspci output to lspci -n (which turns off name resolution) output canassist in deriving which device has which device identifier code.2.

Strany 120

# virsh nodedev-reattach pci_8086_3a6c15.5. PCI passt hrough for para-virt ualized Xen guest s on Red HatEnt erprise LinuxPCI passthrough is used to a

Strany 121

WarningDue to interrupt tracking, repeatedly hotplugging or hotunplugging an assigned device morethan 512 times in a brief period of time can cause a

Strany 122

Chapter 16. SR-IOV16.1. Int roduct ionThe PCI-SIG (PCI Special Interest Group) developed the Single Root I/O Virtualization (SR-IOV)specification. The

Strany 123

This section covers attaching Virtual Function to a guest as an additional network device.SR-IOV requires Intel VT-d support.ImportantXen requires add

Strany 124

Chapter 3. KVM restrictions and supportThe KVM hypervisor requires a processor with the Intel-VT or AMD-V virtualization extensions.To verify the pres

Strany 125

# modprobe igb [<option>=<VAL1>,<VAL2>,]# lsmod |grep igbigb 87592 0dca 6708 1 igb4. Act ivat e Virt u al Fu n ct io n sT

Strany 126

The pci_8086_10c9 is one of the Physical Functions and pci_8086_10ca_0 is the firstcorresponding Virtual Function for that Physical Function. Use the

Strany 127

d. The default text editor will open the libvirt configuration file for the guest. Add the newdevice to the devices section of the XML configuration

Strany 128

Chapter 17. KVM guest timing managementVirtualization poses various challenges for guest time keeping. Guests which use the Time StampCounter (TSC) as

Strany 129

ImportantThese instructions are for AMD revision F cpus only.If the CPU lacks the constant_tsc bit, disable all power management features (BZ #513138)

Strany 130 - Inst allin g Win d o ws

WarningThe divider kernel parameter was previously recommended for Red Hat Enterprise Linux 4and 5 guests that did not have high responsiveness requir

Strany 131

NoteThe boot.ini file is no longer used in Windows Vista and newer. As shown in this procedure,Windows Vista, Windows Server 2008 and Windows 7 use th

Strany 132 - ⁠Part III. Configuration

⁠Part IV. AdministrationAdministering virtualized systemsThese chapters contain information for administering host and guests using tools included in

Strany 133

Chapter 18. Server best practicesThe following tasks and tips can assist you with securing and ensuring reliability of your Red HatEnterprise Linux 5

Strany 134

Chapter 19. Security for virtualizationWhen deploying virtualization technologies on your corporate infrastructure, you must ensure thatthe host canno

Strany 135

Chapter 4. Hyper-V restrictions and supportCertification of guests running under the Microsoft Hyper-V server is conducted by Microsoft. Red HatEnterp

Strany 136

Pro ced u re 19 .1. Creat in g an d mou n t in g a lo g ical vo lu me o n a g u est wit h SELin u xen ab led1. Create a logical volume. This ex

Strany 137 - /dev/sdb1

The Boolean parameter xend_disable_t can set the xend to unconfined mode after restarting thedaemon. It is better to disable protection for a single d

Strany 138

Enabling IP forwarding (net.ipv4.ip_forward = 1) is required for virtual bridge devices.Note that installing libvirt enables this variable so it will

Strany 139

Chapter 20. Managing guests with xendThe xen d node control daemon performs certain system management functions that relate to virtualmachines. This

Strany 140

( xen d - relo cat io n - ad d ress) Determines the host addresses allowed formigration. The default value is the value of xend-address.( xen d - ad d

Strany 141

Chapter 21. Xen live migrationThe Xen hypervisor supports Virtualization Migration for para-virtualized guests and fully virtualizedguests. Migration

Strany 142

(xend-relocation-server yes)The default value, which disables migration, is no. Change the value of xend-relocation-server to yes to enable migration.

Strany 143

Below is an example of how to setup a simple environment for live migration. This configuration isusing NFS for the shared storage. NFS is suitable fo

Strany 144 - Et hernet cards

[et-virt07 ~]# brctl showbridge name bridge id STP enabled interfacesxenbr1 8000.feffffffffff no pet

Strany 145

Verify the virtual machine is running:[et-virt07 ~]# virsh list Id Name State----------------------------------Domain-0

Strany 146

Chapter 5. Virtualization limitationsThis chapter covers additional limitations of the virtualization packages in Red Hat Enterprise Linux.5.1. Genera

Strany 147

Create the following script inside the virtual machine to log date and hostname during the migration.This script performs I/O tasks on the guest'

Strany 148

dhcp78-218.lab.boston.redhat.comFri Jan 12 02:26:51 EST 2007dhcp78-218.lab.boston.redhat.comFri Jan 12 06:54:57 EST 2007dhcp78-218.lab.boston.redhat.c

Strany 149

Fri Jan 12 06:57:53 EST 2007dhcp78-218.lab.boston.redhat.comFri Jan 12 06:57:56 EST 2007dhcp78-218.lab.boston.redhat.comFri Jan 12 06:58:00 EST 2007Fi

Strany 150

[et-virt08 ~]# time virsh migrate --live testvm1 et-virt07real 0m10.378suser 0m0.068ssys 0m0.052sAt this point you have successfully perform

Strany 151 - 12.1. Syst em requirement s

Chapter 22. KVM live migrationThis chapter covers migrating guests running on a KVM hypervisor to another KVM host.Migration is the process of moving

Strany 152

iSCSINFSGFS2Two or more Red Hat Enterprise Linux systems of the same version with the same updates.Both system must have the appropriate ports open.Bo

Strany 153

3. ⁠Mo u n t th e sh ared st o rag e o n t h e d est in at io nOn the destination system, mount the /var/lib/libvirt/images directory:# mount sour

Strany 154

Execute the following command to live migrate the guest to the destination, test2.example.com. Append /system to the end of the destination URL to tel

Strany 155

The Virtual Machine Manager displays a list of connected hosts.2. Add a storage pool with the same NFS to the source and target hosts.On the Ed it m

Strany 156 - Ent erprise Linux 3

3. Add a new storage pool. In the lower left corner of the window, click the + button. The Add aNew Storage Pool window appears.Enter the following d

Strany 157

Para-virtualized devices, which use the virtio drivers, are PCI devices. Presently, guestsare limited to a maximum of 32 PCI devices. Some PCI devices

Strany 158

Format: Select the storage type. This must be NFS or iSCSI for live migrations.Host Name: Enter the IP address or fully-qualified domain name of the s

Strany 159

7. Create a virtual machine with the new volume, then run the virtual machine.The Virtual Machine window appears.⁠Chapt er 2 2 . KVM live migrat ion2

Strany 160

8. In the Virtual Machine Manager window, right-click on the virtual machine, select Mig rat e,then click the migration location.Red Hat En t erp ri

Strany 161

9. Click Yes to confirm migration.The Virtual Machine Manager displays the virtual machine in its new location.The VNC connection displays the remote

Strany 162

Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e24 0

Strany 163

Chapter 23. Remote management of guestsThis section explains how to remotely manage your guests using ssh or TLS and SSL.23.1. Remot e management wit

Strany 164

Generate a public key pair on the machine virt-manager is used. This example uses thedefault key location, in the ~/.ssh/ directory.$ ssh-keygen -t rs

Strany 165

the same technology used by web browsers for secure connections. The libvirt managementconnection opens a TCP port for incoming connections, which is

Strany 166

libvirt-vnc or clientkey.pem - The client private key.23.3. T ransport modesFor remote management, libvirt supports the following transport modes:T r

Strany 167

xen+ssh://ccurran@towada/Connect to a remote Xen hypervisor on the host named towada using TLS.xen://towada/Connect to a remote Xen hypervisor on host

Strany 168

NoteThere are two methods for working around the para-virtualized device limit: using phy devices(devices using the physical access mode) or using LVM

Strany 169

command ssh and ext The external command.For ext transport this isrequired. For ssh thedefault is ssh. ThePATH is searched forthe command.command=/opt

Strany 170

no_tty ssh If set to a non-zerovalue, this stops sshfrom asking for apassword if it cannotlog in to the remotemachine automatically(for using ssh-agen

Strany 171

⁠Part V. Virtualization Storage TopicsIntroduction to storage administration for virtualizationThis part covers using shared, networked storage with v

Strany 172 - # yum install virtio-win

Chapter 24. Using shared storage with virtual disk imagesThis chapter covers the use of shared and network storage devices for virtual disks.24.1. Usi

Strany 173

3. Exp o rt t h e iSCSI t arg et an d LUN sFor Red Hat Enterprise Linux 5, several tgtadm commands are required to create a targetand associate th

Strany 174

Removable media: No Readonly: No Backing store type: rdwr Backing store path: /var/lib/tgtd/kvmguest/shar

Strany 175

</source> <target> <path>/dev/disk/by-path</path> </target></pool>Save this XML code to a file na

Strany 176

04.rhel:rhel5:iscsi.kvmguest-lun-2</path> <format type='unknown'/> <permissions> <mode>0660</mode>

Strany 177 - Press Yes if it is correct

<address type='drive' controller='0' bus='0' unit='0'/> </disk> <disk type='bl

Strany 178

⁠Part VI. Virtualization Reference GuideVirtualization commands, system tools, applications andadditional systems referenceThese chapters provide deta

Strany 179

A limit of 254 para-virtualized block devices per host. The total number of block devices (using thetap:aio driver) attached to guests cannot exceed 2

Strany 180

Chapter 25. Virtualization toolsThe following is a list of tools for virtualization administration, debugging and networking tools thatare useful for

Strany 181

topology change timer 0.00 gc timer 0.02flagsvif13.0 (3)port id 8003 state

Strany 182 - Install the drivers first

Chapter 26. Managing guests with virshvirsh is a command line interface tool for managing guests and the hypervisor.The virsh tool is built on the lib

Strany 183

vcpupinControls the virtual CPU affinity of a guest.domblkstatDisplays block device statistics for a runningguest.domifstatDisplays network interface

Strany 184

This file guest.xml can recreate the guest (see Editing a guest's configuration file. You can edit thisXML configuration file to configure additi

Strany 185

and network I/O does not occur while the guest is suspended. This operation is immediate and theguest can be restarted with the resume (Resuming a gue

Strany 186 - 14 .1.2. Using virt -manager

This command does an immediate ungraceful shutdown and stops the specified guest. Using virsh destroy can corrupt guest file systems . Use the destroy

Strany 187 - Click Forward to continue

# virsh nodeinfoCPU model x86_64CPU (s) 8CPU frequency 2895 MhzCPU socket(s) 2

Strany 188

# virsh vcpuinfo {domain-id, domain-name or domain-uuid}An example of virsh vcpuinfo output:# virsh vcpuinfo r5b2-mySQL01VCPU: 0CPU:

Strany 189

Disp layin g g u est n et wo rk d evice in f o rmat io nUse virsh domifstat to display network interface statistics for a running guest.# virsh domi

Strany 190

⁠Part II. InstallationVirtualization installation topicsThese chapters describe setting up the host and installing guests with Red Hat Enterprise Linu

Strany 191

<range start='192.168.100.128' end='192.168.100.254' /> </dhcp> </ip></network>Other virsh comma

Strany 192

Chapter 27. Managing guests with the Virtual Machine Manager(virt-manager)This section describes the Virtual Machine Manager (virt-manager) windows, d

Strany 193

27.2. T he Virt ual Machine Manager main windowThis main window displays all the running guests and resources used by guests. Select a guest bydouble

Strany 194

Fig u re 27.3. T h e Overview t ab27.4. Virt ual Machine graphical consoleThis window displays a virtual machine's graphical console. Para-virtua

Strany 195

Fig u re 27.4 . G rap h ical co n sole win d o wNoteVNC is considered insecure by many security experts, however, several changes have beenmade to ena

Strany 196 - Chapter 15. PCI passthrough

The virt-manager main window appears.Fig u re 27.5. St art in g virt-managerAlternatively, virt-manager can be started remotely using ssh as demonstr

Strany 197

Fig u re 27.6 . R est o rin g a virt u al mach in e2. The Restore Virtual Machine main window appears.3. Navigate to correct directory and select t

Strany 198

You can use the Virtual Machine Monitor to view activity data information for any virtual machines onyour system.To view a virtual system's detai

Strany 199

On the Virtual Machine window, click the Overview tab.The Overview tab summarizes CPU and memory usage for the guest you specified.Fig u re 27.10. D i

Strany 200

4. On the Hardware tab, click on Processor to view or change the current processorallocation.Fig u re 27.12. Pro cesso r allo cat io n p an el5. On

Strany 201 - 5. Ad d t h e n ew d evice

Chapter 6. Installing the virtualization packagesBefore you can use virtualization, the virtualization packages must be installed on Red HatEnterprise

Strany 202 - 6. Select a PCI d evice

Fig u re 27.14 . Disp layin g d isk co n f ig u rat io n7. On the Hardware tab, click on NIC to view or change the current network configuration.Fig

Strany 203

Fig u re 27.16 . Mo d if yin g g u est p ref eren cesThe Preferences window appears.2. From the Stats tab specify the time in seconds or stats poll

Strany 204 - # virsh nodedev-list --tree

Fig u re 27.18. Viewin g g u est ID s2. The Virtual Machine Manager lists the Domain IDs for all domains on your system.Fig u re 27.19 . Disp layin

Strany 205

Fig u re 27.20. Select in g a virt u al mach in e' s st at u s2. The Virtual Machine Manager lists the status of all virtual machines on your s

Strany 206 - Ent erprise Linux

Fig u re 27.22. Select in g t h e virt u al C PUs o p t io n2. The Virtual Machine Manager lists the Virtual CPUs for all virtual machines on your s

Strany 207 - # modprobe acpiphp

Fig u re 27.24 . Select in g CPU u sag e2. The Virtual Machine Manager lists the percentage of CPU in use for all virtual machines onyour system.Fig

Strany 208

Fig u re 27.26 . Select in g Memo ry Usag e2. The Virtual Machine Manager lists the percentage of memory in use (in megabytes) for allvirtual machin

Strany 209

Fig u re 27.28. Select in g a h o st ' s det ails2. This will open the Ho st Det ails menu. Click the Virtual Networks tab.Fig u re 27.29 . Vi

Strany 210

To create a virtual network on your system:1. Open the Host Details menu (see Section 27.14, “Managing a virtual network” ) and clickthe Add button.F

Strany 211

Fig u re 27.31. C reat in g a n ew virt ual net wo rk2. Enter an appropriate name for your virtual network and click Forward.⁠Chapt er 2 7 . Man agi

Strany 212

Select the Virtualization package group and the Customize Now radio button.4. Select the Virtualization package group. The Virtualization package gro

Strany 213

Fig u re 27.32. N amin g yo u r virt u al n et wo rk3. Enter an IPv4 address space for your virtual network and click Forward.Red Hat En t erp rise

Strany 214

Fig u re 27.33. C h o o sin g an IPv4 add ress sp ace4. Define the DHCP range for your virtual network by specifying a Start and End range of IPad

Strany 215 - /use pmtimer

Fig u re 27.34 . Select in g t h e DHCP ran g e5. Select how the virtual network should connect to the physical network.Red Hat En t erp rise Lin u

Strany 216

Fig u re 27.35. C o n n ect in g t o p h ysical n et workIf you select Forwarding to physical network, choose whether the Destinationshould be NAT t

Strany 217 - ⁠Part IV. Administration

Fig u re 27.36 . Read y to creat e n et wo rk7. The new virtual network is now available in the Virt u al Net wo rk tab of the Ho st Det ailsmenu.R

Strany 218 - # setenforce 1

Fig u re 27.37. N ew virt u al n et wo rk is no w availab le⁠Chapt er 2 7 . Man aging guest s wit h t he Virt ual Machine Manager (virt - manager)291

Strany 219

Chapter 28. The xm command quick referenceThe xm command can manage the Xen hypervisor. Most operations can be performed with the libvirttools, virt -

Strany 220 - 19.3. SELinux

Use the following xm commands to manage resources:xm mem-setuse the xm vcpu-list to list virtualized CPU affinities:$ xm vcpu-listName

Strany 221

Chapter 29. Configuring the Xen kernel boot parametersThe GNU Grand Unified Boot Loader (GRUB) is a program for booting various installed operatingsys

Strany 222

/* "acpi=ht": Limits ACPI from boot-time to enable HT. *//* "acpi=noirq": Disables ACPI interrupt routing.

Strany 223

Red Hat Enterprise Linux 5 Virtualization GuideVirtualization DocumentationSco tt RadvanRed Hat Engineering Content [email protected] mDayle P

Strany 224

Cu st o miz e t h e p ackag es ( if req u ired )Customize the Virtualization group if you require other virtualization packages.Press the Close butto

Strany 225

Chapter 30. Configuring ELILOELILO is the boot loader used on EFI-based systems, notably Itanium® . Similar to the GRUB, theboot loader on x86 and x86

Strany 226 - # service xend restart

To customize the hypervisor, insert parameters before the --. An example of the hypervisor memory(mem) parameter and the quiet parameter for the kerne

Strany 227

Additionally this example removes the kernel parameters "rhgb quiet" so that kernel and initscript output are generated on the console. Not

Strany 228

Chapter 31. libvirt configuration referenceThis chapter provides is a references for various parameters of libvirt XML configuration filesT ab le 31.1

Strany 229

Chapter 32. Xen configuration filesRed Hat Enterprise Linux uses libvirt configuration files for most tasks. Some users may need Xenconfiguration file

Strany 230

on_poweroff=destroy | restart | preserve |destroyBehavior when a domain exits with reason'poweroff'. - destroy: the domain is cleaned upas n

Strany 231

vfb=type={vnc,sdl}, vncunused=1, vncdisplay=N,vnclisten=ADDR, display=DISPLAY, xauthority=XAUTHORITY, vncpasswd=PASSWORD,keymap=KEYMAPMake the domain

Strany 232

extra=ARGSSet extra arguments to append to the kernelcommand line.ip=IPADDRSet the kernel IP interface address.gateway=IPADDRSet the kernel IP gateway

Strany 233

Parser f u n ct io n Valid arg u men t sset_boolAccepted values:yesynoyesset_floatAccepts a floating point number with Python'sfloat(). For exam

Strany 234

on_crash set_valueNoneblkif set_bool0netif set_bool0tpmif append_value0disk append_value[]pci append_value[]ioports append_value[]irq append_value[]us

Strany 235 - # service nfs start

NoteFully virtualized guests on the Itanium® architecture require the guest firmware imagepackage (xen-ia64-guest-firmware). Append the following pac

Strany 236

⁠Part VII. Tips and TricksTips and Tricks to Enhance ProductivityThese chapters contain useful hints and tips to improve virtualization performance, s

Strany 237

Chapter 33. Tips and tricksThis chapter contain useful hints and tips to improve virtualization performance, scale and stability.33.1. Aut omat ically

Strany 238 - Click the Storage tab

# yum install kvm2. ⁠Verif y wh ich kern el is in u seThe kernel-xen package may be installed. Use the uname command to determine which kernelis ru

Strany 239

Reb o o t t o lo ad t h e n ew kern elReboot the system. The computer will restart with the default kernel. The KVM module shouldbe automatically l

Strany 240 - Click Finish

kernel /xen.gz-2.6.18-159.el5 module /vmlinuz-2.6.18-159.el5xen ro root=/dev/VolGroup00/LogVol00 rhgb quiet module /initrd-2.6.1

Strany 241

Command format:# qemu-img convert [-c] [-e] [-f format] filename [-O output_format] output_filenameConvert the disk image filename to disk image outpu

Strany 242

Linux Compressed Loop image, useful only to reuse directly compressed CD -ROM imagespresent for example in the Knoppix CD -ROMs.33.4 . Overcommit t in

Strany 243

Overcommitting guests by swapping out temporarily unused guest memory can be very slow, due tothe IO latency introduced by disk seek times. However, R

Strany 244

terminal --timeout=10 serial consoletitle Red Hat Enterprise Linux Server (2.6.17-1.2519.4.21.el5xen) root (hd0,0) kernel /xen.gz-2.6.17-1.2519.4.21.e

Strany 245

flags : fpu tsc msr pae mce cx8 apic mtrr mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm syscall lm constant_tsc pni monitor ds_cp

Strany 246

virt-managervirt-manager, also known as Virt u al Mach in e Man ag er, provides a graphical tool foradministering virtual machines. It uses libvirt li

Strany 247

WarningGuests must be offline before their files can be read. Editing or reading files of an active guestis not possible and may cause data loss or da

Strany 248 - 23.3. T ransport modes

Many Linux guests use Logical Volume Management (LVM) volumes. Additional steps are required toread data on LVM volumes on virtual storage images.1.

Strany 249

By default, libvirt provisions guests using the hypervisor's default policy. For most hypervisors, thepolicy is to run guests on any available pr

Strany 250

</cells> </topology> <secmodel> <model>selinux</model> <doi>0</doi> </secmodel&g

Strany 251

</cpus> </cell> </cells></topology>2. Observe that the node 1, <cell id='1'>, has physical CPUs 4 to 7.

Strany 252

CPU: 1State: runningCPU Affinity: yyyyyyyyVCPU: 3CPU: 2State: runningCPU Affinity: yyyyyyyyThe v

Strany 253

mac = [ 0x00, 0x16, 0x3e, random.randint(0x00, 0x7f), random.randint(0x00, 0xff), random.randint(0x00, 0xff) ] return ':'.join(map(lambd

Strany 254

rate=10Mb/sLimit the outgoing network traffic from the guest to 10MB/s.rate=250KB/sLimit the outgoing network traffic from the guest to 250KB/s.rate=1

Strany 255

root (hd0, 0)kernel /xen.gz-2.6.17-1.2519.4.21.el5 com1=115200,8n1 module /vmlinuz-2.6.17-1.2519.4.21el5xen ro root=/dev/VolGroup00/LogVol00 mod

Strany 256

33.14 . Configuring LUN Persist enceThis section covers how to implement LUN persistence in guests and on the host machine with andwithout multipath.I

Strany 257

Select the Virtualization package group and the Customize Now radio button.4. Select the KVM package group. Deselect the Virtualization package group

Strany 258

}multipath { wwid 3600a0b80001327510000015427b625e alias oramp3}multipath { wwid 3600a0b800

Strany 259

echo "D-BUS per-session daemon address is: \ $DBUS_SESSION_BUS_ADDRESS"fiexec gnome-session33.18. Cloning guest configurat ion filesYou c

Strany 260

Now, adjust the system configuration settings on your guest:/etc/sysconfig/networkModify the HOSTNAME entry to the guest's new hostname./etc/sysc

Strany 261

Chapter 34. Creating custom libvirt scriptsThis section provides some information which may be useful to programmers and systemadministrators intendin

Strany 262

⁠Part VIII. TroubleshootingIntroduction to Troubleshooting and Problem SolvingThe following chapters provide information to assist you in troubleshoot

Strany 263

Chapter 35. Troubleshooting XenThis chapter covers essential concepts to assist you in troubleshooting problems in Xen.Troubleshooting topics covered

Strany 264

These networking tools can assist with troubleshooting virtualization networking problems:ifconfigtcpdumpThe tcpdump command 'sniffs' networ

Strany 265

When deploying Red Hat Enterprise Linux 5 with Virtualization into your network infrastructure, thehost's Virtualization software uses many speci

Strany 266

The /etc/xen directory contains the configuration files that you use to manage systemresources. The xend daemon configuration file is /etc/xen/xend-co

Strany 267

module /vmlinuz-2.618-8.el5xen ro root=LABEL=/rhgb quiet console=xvc console=tty xencons=xvc module /initrd-2.6.18-8.el5xen.imgThe sync_console can

Strany 268

Customize the Virtualization group if you require other virtualization packages.Press the Close button then the Forward button to continue the install

Strany 269

Error: Error connecting to xend: Connection refused. Is xend running?Try to run xend start manually and receive more errors:Error: Could not obtain ha

Strany 270 - </network>

title Red Hat Enterprise Linux 5 i386 Xen (2.6.18-92.el5xen) root (hd0, 8) kernel /boot/xen.gz-2.6.18-92.el5 com1=115200,8n1 module /boot/vmlinuz-2.6.

Strany 271

# Log all guest console output (cf xm console)XENCONSOLED_LOG_GUESTS=yesReboot the host to activate logging the guest serial console output.Logs from

Strany 272

The example below is a typical a para-virtualized guest configuration file:name = "rhel5vm01"memory = "2048"disk = ['tap:aio:

Strany 273

You can check the amount of memory in use by domain0 by using the xm list domain0command. If dom0 is not ballooned down, you can use the command virsh

Strany 274

# Do not remove the following line, or various programs# that require network functionality will fail.127.0.0.1 localhost.localdomain localhostlocalho

Strany 275

declared; see http://www.python.org/peps/pep-0263.html for detailsexecfile (defconfig, globs, locs,)Error: invalid syntax 9win2k3xen12, line1)Python g

Strany 276

Chapter 36. TroubleshootingThis chapter covers common problems and solutions with Red Hat Enterprise Linux virtualization.36.1. Ident ifying available

Strany 277

options loop max_loop=64This example uses 64 but you can specify another number to set the maximum loop value. You mayalso have to imp

Strany 278

“ default=X” (where X is a number starting at '0') to correspond to the entry with your kernel-xenline. The numbering starts at '0&apo

Strany 279

Ad d in g p ackag es t o yo u r list o f Red Hat acco u n t en t it lemen t sThis section describes how to enable entitlements in your Red Hat

Strany 280 - 27.8. St at us monit oring

# Do not remove the following line, or various programs# that require network functionality will fail.localhost.localdomain localhostThe correct entry

Strany 281

The virtualization extensions are sometimes disabled in BIOS, usually by laptop manufacturers. SeeSection 36.12, “ Enabling Intel VT and AMD-V virtual

Strany 282

A workaround is to switch to a different type of virtualized NIC. For example, Intel PRO/1000 (e1000)or virtio (the para-virtualized network driver).T

Strany 283

3. Create the new virtual machine:# virsh define /tmp/new-guest.xml# virsh start new-guestThe network performance should be better with the e1000 or

Strany 284 - 27.12. Displaying CPU usage

Chapter 37. Troubleshooting the Xen para-virtualized driversThis chapter deals with issues you may encounter with Xen hosts and fully virtualized Red

Strany 285

NoteThe logfile is overwritten every time you start virt - manag er. If you are troubleshooting aproblem with virt - man ag er make sure you save the

Strany 286

displayed. A shortened excerpt of the error can be seen below.# insmod xen-platform-pci.o Warning: kernel-module version mismatchxen-platform-pci.o wa

Strany 287

37.5. Verifying t he para-virt ualized drivers have successfully loadedOne of the first tasks you will want to do is to verify that the drivers have a

Strany 288

Additional resourcesTo learn more about virtualization and Red Hat Enterprise Linux, see the following resources.A.1. Online resourceshttp://www.cl.ca

Strany 289

create programs that interface with the libvirt virtualization management library./usr/share/doc/python-virtinst-<version-number> — Provides doc

Strany 290

Chapter 7. Guest installation overviewAfter you have installed the virtualization packages on the host system you can create guestoperating systems. Y

Strany 291

ColophonThis manual was written in the DocBook XML v4.3 format.This book is based on the work of Jan Mark Holzer, Chris Curran and Scott Radvan.Other

Strany 292

SpanishAngela GarciaGladys GuerreroRussianYuliya PoyarkovaColophon357

Strany 293

Pro ced u re 7.1. Creat in g a gu est wit h virt - man ag er1. O p en virt - man ag erStart virt-manager. Launch the Virt u al Machin e Man ag er

Strany 294

4. New g u est wiz ardThe Create a new virtual machine window provides a summary of the information youmust provide in order to create a virtual mac

Strany 295

Review the information for your installation and click the Forward button.5. Name t h e virt u al mach in eProvide a name for your guest. Punctuation

Strany 296 - $ xm list

Legal NoticeCopyright © 2008–2014 Red Hat, Inc.This do cument is licensed by Red Hat under the Creative Commo ns Attributio n-ShareAlike 3.0Unported

Strany 297

Press Forward to continue.6. Ch o o se virt u aliz at io n met h o dThe Choosing a virtualization method window appears. Choose between Para-virtual

Strany 298

Choose the virtualization type and click the Forward button.7. Select t h e inst allat io n met h o dThe Installation Method window asks for the ty

Strany 299

guest. Setting up a PXE server is covered in the Red Hat Enterprise Linux DeploymentGuide. Using this method requires a guest with a routable IP addre

Strany 300 - Chapter 30. Configuring ELILO

If Local install media was selected in the previous step this screen is calledInstall Media.Select the location of an ISO image or select a DVD or CD-

Strany 301

Click the Forward button to proceed.c. Net wo rk b o o t ( PXE)PXE installation does not have an additional step.9. St o rag e set u pThe Storage w

Strany 302

Choose the appropriate size for the guest on your selected storage type and click theForward button.NoteIt is recommend that you use the default direc

Strany 303

Press Forward to continue.11. Memo ry an d C PU allo cat io nThe Memory and CPU Allocation window displays. Choose appropriate values for thevirtual

Strany 304

Press Forward to continue.12. Verif y an d st art g u est in st allat io nThe Finish Virtual Machine Creation window presents a summary of allconf

Strany 305

A VNC window opens showing the start of the guest operating system installation process.This concludes the general process for creating guests with vi

Strany 306

TYPE=BridgeBOOTPROTO=dhcpONBOOT=yesWarningThe line, TYPE=Bridge, is case-sensitive. It must have uppercase 'B' andlower case 'ridge&apo

Strany 307

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strany 308

# brctl showbridge name bridge id STP enabled interfacesinstallation 8000.001320f76e8e no eth1virbr0

Strany 309

PXE inst allat io n wit h virt - man ag erThe steps below are the steps that vary from the standard virt-manager installation procedures. Forthe sta

Strany 310

3. ⁠St art t h e in st allat io nThe installation is ready to start.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e4 8

Strany 311 - Chapter 33. Tips and tricks

A DHCP request is sent and if a valid PXE server is found the guest installation processes will start.⁠Chapt er 7 . G uest inst allat ion overview4 9

Strany 312

Chapter 8. Guest operating system installation proceduresThis chapter covers how to install various guest operating systems in a virtualized environme

Strany 313 - 33.2.2. KVM t o Xen

# virt-install -n rhel5PV -r 500 \-f /var/lib/libvirt/images/rhel5PV.dsk -s 3 --vnc -p \-l ftp://10.1.1.1/trees/RHEL5-B2-Server-i386/NoteRed Hat Enter

Strany 314 - 33.3. Using qemu-img

2. Select the keyboard layout and click OK.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e52

Strany 315

3. Assign the guest's network address. Choose to use DHCP (as shown below) or a static IPaddress:⁠Chapt er 8 . G uest operat ing syst em inst a

Strany 316

4. If you select DHCP the installation process will now attempt to acquire an IP address:Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e54

Strany 317

5. If you chose a static IP address for your guest this prompt appears. Enter the details on theguest's networking configuration:a. Enter a val

Strany 318

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strany 319

6. This is an example of a static IP address configuration:Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e56

Strany 320

7. The installation process now retrieves the files it needs from the server:⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res57

Strany 321

Once the initial steps are complete the graphical installation process starts.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e58

Strany 322

If you are installing a Beta or early release distribution confirm that you want to install the operatingsystem. Click Install Anyway, and then click

Strany 323

Pro ced u re 8.2. T h e g rap h ical in st allat io n p ro cess1. Enter a valid registration code. If you have a valid Red Hat subscription key plea

Strany 324

NoteIf you skip the registration step, confirm your Red Hat account details after theinstallation with the rhn_register command. The rhn_register comm

Strany 325

Click Yes to continue.3. Review the storage configuration and partition layout. You can chose to select the advancedstorage configuration if you want

Strany 326

5. Configure networking and hostname settings. These settings are populated with the dataentered earlier in the installation process. Change these se

Strany 327

7. Enter the root password for the guest.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e64

Strany 328 - 33.13. Very Secure ftpd

Click Forward to continue.8. Select the software packages to install. Select the Customize Now button. You must installthe kernel-xen package in the

Strany 329

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strany 330

Click Forward.9. Dependencies and space requirements are calculated.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e66

Strany 331

10. After the installation dependencies and space requirements have been verified click Forwardto start the actual installation.⁠Chapt er 8 . G uest

Strany 332

11. All of the selected software packages are installed automatically.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e68

Strany 333

12. After the installation has finished reboot your guest:⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res69

Strany 334 - ⁠Part VIII. Troubleshooting

13. The guest will not reboot, instead it will shutdown..Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e70

Strany 335

14. Boot the guest. The guest's name was chosen when you used the virt-install inSection 8.1, “ Installing Red Hat Enterprise Linux 5 as a para-

Strany 336 - 35.2. Log files overview

Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e72

Strany 337 - 35.3. Log file descript ions

15. Booting the guest starts the First Boot configuration screen. This wizard prompts you for somebasic configuration choices for your guest.16. Rea

Strany 338

Click Forward on the license agreement windows.17. Configure the firewall.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e74

Strany 339 - 35.9. Common Xen problems

Click Forward to continue.a. If you disable the firewall you will be prompted to confirm your choice. Click Yes toconfirm and continue. It is not rec

Strany 340

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strany 341

18. Configure SELinux. It is strongly recommended you run SELinux in enforcing mode. Youcan choose to either run SELinux in permissive mode or comple

Strany 342

Click Forward to continue.a. If you choose to disable SELinux this warning displays. Click Yes to disable SELinux.⁠Chapt er 8 . G uest operat ing sy

Strany 343

19. Disable kdump. The use of kdump is unsupported on para-virtualized guests.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e78

Strany 344

Click Forward to continue.20. Confirm time and date are set correctly for your guest. If you install a para-virtualized guesttime and date should syn

Strany 345

Click Forward to continue.21. Set up software updates. If you have a Red Hat account or want to trial one use the screenbelow to register your newly

Strany 346

Click Forward to continue.a. Confirm your choices for RHN.⁠Chapt er 8 . G uest operat ing syst em inst allat ion pro cedu res81

Strany 347 - Chapter 36. Troubleshooting

b. You may see an additional screen if you did not configure RHN access. If RHN accessis not enabled, you will not receive software updates.Red Hat

Strany 348

Click the Forward button.22. Create a non root user account. It is advised to create a non root user for normal usage andenhanced security. Enter the

Strany 349

Click the Forward button.23. If a sound device is detected and you require sound, calibrate it. Complete the process andclick Forward.Red Hat En t e

Strany 350

24. You can install additional packages from a CD or another repository using this screen. It isoften more efficient to not install any additional so

Strany 351

. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

Strany 352

25. The guest now configure any settings you changed and continues the boot process.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e86

Strany 353 - # virsh start new-guest

26. The Red Hat Enterprise Linux 5 login screen displays. Log in using the username created inthe previous steps.⁠Chapt er 8 . G uest operat ing sys

Strany 354

27. You have now successfully installed a para-virtualized Red Hat Enterprise Linux guest.Red Hat En t erp rise Lin ux 5 Virt ualizat ion Guid e88

Strany 355

8.2. Inst alling Red Hat Ent erprise Linux as a fully virt ualized guestThis section covers installing a fully virtualized Red Hat Enterprise Linux 5

Strany 356

Connect to a hypervisor if you have not already done so. Open the File menu and select theAdd Connection... option. See Section 27.1, “ The Add Connec

Strany 357

Press Forward to continue.5. ⁠Ch o o se a virt u aliz at io n met ho dChoose the virtualization method for the guest. Note you can only select an in

Strany 358 - Additional resources

Press Forward to continue.6. ⁠Select t h e in st allat io n met ho dRed Hat Enterprise Linux can be installed using one of the following methods:lo

Strany 359 - Addit ional resources

Press Forward to continue.7. ⁠Locat e in st allat io n med iaSelect ISO image location or CD -ROM or DVD device. This example uses an ISO file image

Strany 360 - Colophon

Press Forward to continue.WarningFor ISO image files and guest storage images the recommended directory is /var/lib/libvirt/images/. Any other locatio

Strany 361 - Yuliya Poyarkova

Press Forward to continue.NoteLive and offline migrations require guests to be installed on shared network storage.For information on setting up share

Komentáře k této Příručce

Žádné komentáře