SUSE Linux EnterpriseServerwww.novell.com10 SP4April15,2011 Virtualization with Xen
Figure 1.1Virtualization ArchitectureOn the left, the virtual machine host’s Domain0 is shown running the SUSE Linux op-erating system. The two virtua
Figure 1.2Desktop Showing Virtual Machine Manager and Virtual Machines1.5 Supported Virtualization LimitsThe following virtualization limits are suppo
• Max. memory per VM: 16GB for 32bit, 64GB for 64bit guests• Max. virtual block devices per VM: 16 paravirtualized, 16 fully virtualized withparavirtu
2Setting Up a Virtual MachineHostThis section documents how to set up and use SUSE Linux Enterprise Server 10 SP4as a virtual machine host.In most cas
Minimum RequirementsSystem Compo-nent7 GB of available disk space for the host.Free Disk SpaceDVD-ROM DriveOptical Drive20 GBHard DriveEthernet 100 Mb
Permanently add this parameter to your boot loader conguration by addingthe parameter dom0_mem=VALUE to your Xen kernel boot conguration. Eitheruse
2.2 Setting Up a 32-Bit Domain 0 ona 64-Bit HypervisorA virtual machine host running on a 64-bit platform can access much more memorythan hosts runnin
10Edit the GRUB boot loader settings by running YaST > System > Boot Loader orediting the le at /boot/grub/menu.lst.11Change Hypervisor to /boo
2.3.1 Setting a Maximum Amount ofMemory1Determine the amount of memory to set for domain 0.2At Domain0, type xm list to view the currently allocated m
emulatedTo use a “emulated” network interface like an emulated Realtek card, specifytype=ioemu on the vif line. In /etc/xen/vm/<configuration> t
Virtualization with XenAll content is copyright © Novell, Inc.Legal NoticeThis manual is protected under Novell intellectual property rights. By repro
.novell.com/rc/docrepository/public/37/basedocument.2007-09-13.2960758124/4622069_f_en.pdf.If the Xen option is not on the GRUB menu, review the steps
3Setting Up Virtual MachinesA virtual machine is comprised of data and operating system les that dene the virtualenvironment. Virtual machines are h
•Install a host server as described in Chapter 2, Setting Up a Virtual Machine Host(page 7).• If you want to use an automated installation le (AutoYa
If the wizard does not appear or the vm-install command does not work, reviewthe process of installing and starting the virtualization host server. Th
Figure 3.2SummaryInformation about the following operating systems is included:• OES NetWare Virtual Machines, see Section 6.1, “NetWare Virtual Machi
2Each virtual machine must have a unique name. The name entered on this page isused to create and name the virtual machine’s conguration le. The con
For best performance, create each virtual disk from an entire disk or a partition. Forthe next best performance, create an image le but do not create
WARNING: Changing CD-RomsOn paravirtual guests, it is currently not possible to go on with the installationof a system after changing the CD-Rom. Inst
xvdaMain system disk.xvdbISO image of the installation medium.xvdcISO image of the Add-On product.During the installation, add the Add-On product to t
Figure 3.3Command Line Interface3.5 Deleting Virtual MachinesWhen you use Virtual Machine Manager or the xm command to delete a virtual machine,it no
ContentsPreface v1 Introduction to Xen Virtualization 11.1 Basic Components . . . . . . . . . . . . . . . . . . . . . . . . . 11.2 Understanding Virtu
Server 9 VM Guest will not be able to nd its root le system when running on a SUSELinux Enterprise Server 10 VM Host Server.To be able to still boot
kernel: PCI-DMA: Out of SW-IOMMU space for 32768 bytes at device000:01:02.0In this case you need to increase the size of the swiotlb. Add “swiotlb=128
4Managing a VirtualizationEnvironmentGraphical utilities, text-based commands, and modied conguration les are methodsyou can choose from to manage
From a command line interface on the virtual machine host, you can use the vm-installprogram and xm commands to create and manage virtual machines. Yo
•Clicking New in Virtual Machine Manager launches the Create Virtual MachineWizard, which walks you through the steps required to set up a virtual mac
•To check the status of the xend daemon, enter rcxend status.The parameters in the xend-config.sxp le can be customized to meet your re-quirements fo
(bootloader_args '- -entry=xvda2:/boot/vmlinuz-xen,/boot/initrd-xen')(name SLES10withOES2) (maxmem 512)(on_reboot restart)(on_poweroff destr
Name ID Mem VCPUs State Time(s)Domain-0 0 457 2 r----- 2712.9OES 7 512 1 -b---- 16.3SLES10 512 1 12.9The syntax of the xm command usually follows the
5Virtualization: CongurationOptions and SettingsThe documentation in this section, describes advanced management tasks and congu-ration options that
4 Managing a Virtualization Environment 274.1 Virtual Machine Manager . . . . . . . . . . . . . . . . . . . . . 284.2 Controlling the Host by Modifyin
NOTEOnly limited support for virtual machine removable media is available in theoriginal version of SUSE Linux Enterprise Server. Much of the followin
do not have enough CD readers, create image les from the CDs and make thoseavailable. To create an image le, the following command may be used:dd if
5Click Hardware > Disk.6Click CD-ROM.7Specify the path to the physical CD reader, such as /dev/cdrom. If you areadding a virtual CD reader based on
5.1.4 Adding Virtual CD Readers (CommandLine Method)1Make sure that the virtual machine is running and the operating system has nishedbooting.2Insert
The CD or ISO image le should appear in the virtual machine’s operating system.5.1.5 Removing Virtual CD Readers1Make sure that the virtual machine i
Graphical Desktop with X Window ServerIf a graphical desktop, such as GNOME or KDE, is installed on the virtual machinehost you can use a remote viewe
To use the VNC viewer from a remote computer, remote administration must be enabledon the host. You can use the YaST Remote Administration module.Figu
Figure 5.2Mozilla Firefox VNC ViewerWhen successfully connected, the VNC viewer shows the display of the running virtualmachine.5.3.1 Assigning VNC Vi
5.3.2 Using SDL instead of a VNC ViewerIf you access a virtual machine’s display from the virtual machine host console (knownas local or on-box access
Figure 5.3Boot Loader SettingsSelect the Xen section, then click Edit to manage the way the boot loader and Xenfunction.Figure 5.4Boot Loader Settings
PrefaceThis manual offers an introduction to virtualization technology of your SUSE LinuxEnterprise Server. It features an overview of the various el
• Select a specic hypervisor•Pass additional parameters to the hypervisor (see /usr/share/doc/packages/xen/pdf/user.pdf section “Xen Boot Options” af
rameter is dom0_mem=<amount_of_memory>, which species how much memoryto allocate to Domain0. The amount of memory is specied in KB, or you can
3Enter sax2 to run the SaX2 graphical conguration module.4Congure the GUI as desired.5Enter telinit 5 to switch to GUI mode.5.6 Paravirtual Mode and
5.7 Virtual Machine Initial StartupFilesDuring the process of creating a new virtual machine, initial startup settings are writtento a le created at
DescriptionEntryThis entry species a virtual disk based on a le ( file:)named hda and located at/var/lib/xen/images/VM1_SLES10/. It presents itselfa
DescriptionEntryType of operating system.ostype =Identication number for a virtual drive.uuid =5.8 Sparse Image Files and Disk SpaceIf the host’s phy
To view a virtual machine’s current keymap entry, enter the following command onthe Domain0:xm list -l vm_name | grep keymapYou can specify a keymap e
Keymap SettingLanguageesSpanishFinnishfrFrenchfr-beFrench-Belgiumfr-caFrench-Canadafr-chFrench-SwitzerlandhuHungarianisIcelandicitItalianjaJapanesenl
5.10 Mapping Physical Storage toVirtual DisksTo specify a mapping between physical storage and the virtual disk, you might need toedit the virtual mac
ExampleDescriptionProtocoliscsi:IQN,LUNiSCSI targets using connections initiatedfrom domain 0iscsi:npiv:NPIV,LUNFibre Channel connections initiated fr
3 Documentation ConventionsThe following typographical conventions are used in this manual:•/etc/passwd: lenames and directory names•placeholder: rep
5.12 Migrating Virtual MachinesA running virtual machine can be migrated from its source virtual machine host to an-other virtual machine host. This f
For example, to pass Ctrl + Alt + F2 to a Linux virtual machine, press Ctrl three times,then press Alt + F2. You can also press Alt three times, then
5.15 File-Backed Virtual Disks andLoopback DevicesWhen a virtual machine is running, each of its le-backed virtual disks consumes aloopback device on
IMPORTANTAfter using the save operation, do not boot, start, or run a virtual machine thatyou intend to restore. If the virtual machine is at any time
The restore operation deletes the previously-saved memory-state le and assigns a newID to the virtual machine. The virtual machine name and UUID rema
5.18 Virtual Machine StatesA virtual machine’s state can be displayed in Virtual Machine Manager or by viewingthe results of the xm list command, whic
6Xen Guest Systems6.1 NetWare Virtual MachinesIn Novell® Open Enterprise Server (OES) 2, the NetWare® operating system has beenmodied to run in parav
ParavirtualFully virtualOperating SystemYesYesSUSE Linux Enterprise Server 10 SP1YesSUSE Linux Enterprise Server Server 10YesYesOpen Enterprise Server
Hypervisor and Domain 0Operating System and Virtu-alization ModeSLE (32-bit) - Paravirtual • 32-bit hypervisor / 32-bit domain 0SLE (32-bit PAE) - Ful
1Introduction to XenVirtualizationVirtualization of operating systems is used in many different computing areas. It ndsits applications in server con
SLE 10 virtual machines created on a SLE 10 SP1 host do not need to follow the sameprocedures to be updated to SP1. In addition, SLE 10 did not suppor
• Virtual disk size8Make sure to select or specify the virtual machine’s already-created disk or diskimage, for example, hda, as the virtual disk.For
After the installation program is completed, the virtual machine should run SLE10 SP1 and be registered with xend.16Log in to the SLE 10 SP1 virtual m
6.3.3 Using the Add-On Products ProgramThe Add-On Products program is available during the SLE operating system installationand after installation at
clock setting must be enabled (set to 1). Otherwise, it will continue to synchronize itstime with its host.Procedure 6.1Viewing the Independent Wallcl
echo "1" > /proc/sys/xen/independent_wallclockEnter 1 to enable or 0 to disable the wallclock settting.3Add or change the following entry
4Install the package inst-source-utils. Then, change your working directoryto your network installation source.5Run the command $HOME/bin/create_updat
7Virtual Machine DriversSUSE® Linux Enterprise Virtual Machine Driver Pack contains disk and network devicedrivers for a number of third-party operati
possible when consolidating servers, the hardware must be emulated for the operatingsystem. Emulation can be slow, but it is especially troubling for
7.2 Loading the Driver Pack1Download the SLES-Virtual-Machine-Driver-Pack-10.iso le to your SUSE LinuxEnterprise Server virtual machine host server.2
• The SUSE Linux operating system, which gives the administrator a graphicaland command line environment to manage the virtual machine host components
7.3.1 Installing the RHEL 4 Drivers1Open a terminal.2Locate the RPM package you want to install ( opt/novell/vm-driver-pack).If you are installing fro
8Open the virtual machine conguration le located on the virtualization hostserver ( /etc/xen/vm/vm_cfgfile where vm_cfgfile is usually thesame as th
7.3.3 Upgrading the RHEL 4 Drivers1Open a terminal.2Locate the RPM package you want to install ( opt/novell/vm-driver-pack).If you are installing from
7.3.5 Building Your Own RPMsIf you do not have a driver pack that was built for your Linux kernel, you can buildyour own SUSE Drivers for Red Hat Ente
3bEnter rpm -U xxx.rpm , where xxx is the RPM lename.3cEdit the /boot/grub/menu.lst le and make the following changes:•Set the default= xxx (where x
9Restart the virtual machine.7.4.2 Uninstalling the RHEL 5 Drivers1Open a terminal.2Enter rpm -e kmod-vmdp-rhel5- xxx , where xxx is the version of th
4Verify that the default kernel is the one with the latest initrd in the /boot/grub/menu.list.7.4.4 Using the Drivers with an UpgradedKernel1Install t
For each drive specied in the virtual machine conguration le (for example, hdaand hdb), append hdx=noprobe to the kernel line for the updated kerne
If a security alert appears, indicating the Bus driver has not been properly signed,click Yes to install the Bus driver software. It is important that
5Click I accept this agreement, then click Next.A software installation note appears, indicating that the software has not passedWindows logo testing.
• Full virtualization mode lets virtual machines run unmodied operating systems,such as Windows* Server 2003 and Windows XP, but requires the compute
6Click Continue Anyway or click Yes for each occurrence of this window.A Congratulations window indicates that the drivers were installed.NOTEClicking
8Click Yes.The system restarts. The Found New Hardware Wizard appears, indicating thatit has found new hardware.9Click Yes, this time only, then click
10Click Install the Software Automatically, then click Next.A software installation note appears, indicating that the software has not passedWindows l
12Click Finish.13If you are installing the Windows 2000 Server, you must reboot the system again.7.5.1 Uninstalling the Driver Pack1Make sure the inst
6Click Cancel.The driver pack is now uninstalled from your system.7.5.2 Upgrading the Driver PackTo upgrade to a newer version of the driver pack foll
7.5.4 Avoiding Problems with the DriversTo avoid problems and potential failure of the device drivers in the driver pack, youshould avoid the followin
7.6.1 Setting Up a new Virtual Machine1Create a new fully virtual machine or start an existing fully virtual machine. UseYaST > Virtualization >
hdaX is the disk and partition of your root partition. For example, this will look likeroot=/dev/hda2.3Shutdown your VM Guest. The Xen paravirtualized
You can also restart the virtual machine by using xm start vm_cfgfile, butmake sure to connect to it with a viewer.The rst time the virtual machine b
Komentáře k této Příručce