Red Hat Virtualization-4.1-Virtual Machine Management Guide-en-US PDF
Red Hat Virtualization-4.1-Virtual Machine Management Guide-en-US PDF
This document is licensed by Red Hat under the Creative Commons Attribution-
ShareAlike 3.0 Unported License. If you distribute this document, or a modified version
of it, you must provide attribution to Red Hat, Inc. and provide a link to the original. If
the document is modified, all Red Hat trademarks must be removed.
Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to
assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law.
Red Hat, Red Hat Enterprise Linux, the Shadowman logo, JBoss, OpenShift, Fedora, the
Infinity logo, and RHCE are trademarks of Red Hat, Inc., registered in the United States
and other countries.
Linux ® is the registered trademark of Linus Torvalds in the United States and other
countries.
Node.js ® is an official trademark of Joyent. Red Hat Software Collections is not formally
related to or endorsed by the official Joyent Node.js open source or commercial project.
The OpenStack ® Word Mark and OpenStack logo are either registered
trademarks/service marks or trademarks/service marks of the OpenStack Foundation, in
the United States and other countries and are used with the OpenStack Foundation's
permission. We are not affiliated with, endorsed or sponsored by the OpenStack
Foundation, or the OpenStack community.
Abstract
This guide describes the installation, configuration, and administration of virtual
machines in Red Hat Virtualization.
Table of Contents
Table of Contents
.CHAPTER
. . . . . . . 1.
. . INTRODUCTION
............................................................4
.........
1.1. AUDIENCE 4
1.2. SUPPORTED VIRTUAL MACHINE OPERATING SYSTEMS 4
1.3. VIRTUAL MACHINE PERFORMANCE PARAMETERS 4
1.4. INSTALLING SUPPORTING COMPONENTS ON CLIENT MACHINES 5
.CHAPTER
. . . . . . . 2.
. . INSTALLING
. . . . . . . . . .LINUX
. . . . .VIRTUAL
. . . . . . . MACHINES
......................................7
.........
2.1. CREATING A LINUX VIRTUAL MACHINE 7
2.2. STARTING THE VIRTUAL MACHINE 9
2.3. SUBSCRIBING TO THE REQUIRED ENTITLEMENTS 11
2.4. INSTALLING GUEST AGENTS AND DRIVERS 12
.CHAPTER
. . . . . . . 3.
. . INSTALLING
. . . . . . . . . .WINDOWS
. . . . . . . . VIRTUAL
. . . . . . . MACHINES
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
..........
3.1. CREATING A WINDOWS VIRTUAL MACHINE 16
3.2. STARTING THE VIRTUAL MACHINE USING THE RUN ONCE OPTION 18
3.3. INSTALLING GUEST AGENTS AND DRIVERS 19
. . . . . . . . 4.
CHAPTER . . ADDITIONAL
. . . . . . . . . . CONFIGURATION
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
..........
4.1. CONFIGURING SINGLE SIGN-ON FOR VIRTUAL MACHINES 25
4.2. CONFIGURING USB DEVICES 30
4.3. CONFIGURING MULTIPLE MONITORS 32
4.4. CONFIGURING CONSOLE OPTIONS 33
4.5. CONFIGURING A WATCHDOG 42
4.6. CONFIGURING VIRTUAL NUMA 47
4.7. CONFIGURING RED HAT SATELLITE ERRATA MANAGEMENT FOR A VIRTUAL MACHINE 48
4.8. CONFIGURING HEADLESS VIRTUAL MACHINES 49
.CHAPTER
. . . . . . . 5.
. . EDITING
. . . . . . .VIRTUAL
. . . . . . .MACHINES
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
..........
5.1. EDITING VIRTUAL MACHINE PROPERTIES 51
5.2. EDITING IO THREADS 52
5.3. NETWORK INTERFACES 52
5.4. VIRTUAL DISKS 54
5.5. HOT PLUGGING VIRTUAL MEMORY 59
5.6. HOT PLUGGING VCPUS 61
5.7. PINNING A VIRTUAL MACHINE TO MULTIPLE HOSTS 62
5.8. CHANGING THE CD FOR A VIRTUAL MACHINE 63
5.9. SMART CARD AUTHENTICATION 64
.CHAPTER
. . . . . . . 6.
. . ADMINISTRATIVE
. . . . . . . . . . . . . .TASKS
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
..........
6.1. SHUTTING DOWN A VIRTUAL MACHINE 66
6.2. SUSPENDING A VIRTUAL MACHINE 66
6.3. REBOOTING A VIRTUAL MACHINE 66
6.4. REMOVING A VIRTUAL MACHINE 67
6.5. CLONING A VIRTUAL MACHINE 67
6.6. UPDATING VIRTUAL MACHINE GUEST AGENTS AND DRIVERS 67
6.7. VIEWING RED HAT SATELLITE ERRATA FOR A VIRTUAL MACHINE 69
6.8. VIRTUAL MACHINES AND PERMISSIONS 69
6.9. SNAPSHOTS 73
6.10. HOST DEVICES 78
6.11. AFFINITY GROUPS 80
6.12. EXPORTING AND IMPORTING VIRTUAL MACHINES AND TEMPLATES 82
6.13. MIGRATING VIRTUAL MACHINES BETWEEN HOSTS 99
6.14. IMPROVING UPTIME WITH VIRTUAL MACHINE HIGH AVAILABILITY 106
1
Virtual Machine Management Guide
.CHAPTER
. . . . . . . 7.
. . TEMPLATES
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115
...........
7.1. SEALING VIRTUAL MACHINES IN PREPARATION FOR DEPLOYMENT AS TEMPLATES 115
7.2. CREATING A TEMPLATE 117
7.3. EDITING A TEMPLATE 118
7.4. DELETING A TEMPLATE 118
7.5. EXPORTING TEMPLATES 119
7.6. IMPORTING TEMPLATES 120
7.7. TEMPLATES AND PERMISSIONS 121
7.8. USING CLOUD-INIT TO AUTOMATE THE CONFIGURATION OF VIRTUAL MACHINES 124
7.9. USING SYSPREP TO AUTOMATE THE CONFIGURATION OF VIRTUAL MACHINES 127
7.10. CREATING A VIRTUAL MACHINE BASED ON A TEMPLATE 129
7.11. CREATING A CLONED VIRTUAL MACHINE BASED ON A TEMPLATE 130
. . . . . . . . .B.
APPENDIX . .VIRT-SYSPREP
. . . . . . . . . . . .OPERATIONS
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
...........
2
Table of Contents
3
Virtual Machine Management Guide
CHAPTER 1. INTRODUCTION
A virtual machine is a software implementation of a computer. The Red Hat Virtualization
environment enables you to create virtual desktops and virtual servers.
1.1. AUDIENCE
Most virtual machine tasks in Red Hat Virtualization can be performed in both the User
Portal and Administration Portal. However, the user interface differs between each portal,
and some administrative tasks require access to the Administration Portal. Tasks that can
only be performed in the Administration Portal will be described as such in this book. Which
portal you use, and which tasks you can perform in each portal, is determined by your level
of permissions. Virtual machine permissions are explained in Section 6.8, “Virtual Machines
and Permissions”.
IMPORTANT
The User Portal's user interface is described in the Introduction to the User Portal.
The creation and management of virtual machines through the Red Hat Virtualization REST
API is documented in the REST API Guide.
4
CHAPTER 1. INTRODUCTION
The Remote Viewer application provides users with a graphical console for connecting to
virtual machines. Once installed, it is called automatically when attempting to open a SPICE
session with a virtual machine. Alternatively, it can also be used as a standalone
application. Remote Viewer is included in the virt-viewer package provided by the base Red
Hat Enterprise Linux Workstation and Red Hat Enterprise Linux Server repositories.
You can now connect to your virtual machines using either the SPICE protocol or the VNC
protocol.
The Remote Viewer application provides users with a graphical console for connecting to
virtual machines. Once installed, it is called automatically when attempting to open a SPICE
session with a virtual machine. Alternatively, it can also be used as a standalone
application.
1. Open a web browser and download one of the following installers according to the
architecture of your system.
https://your-manager-fqdn/ovirt-engine/services/files/spice/virt-
viewer-x86.msi
https://your-manager-fqdn/ovirt-engine/services/files/spice/virt-
viewer-x64.msi
5
Virtual Machine Management Guide
Remote Viewer is installed and can be accessed via Remote Viewer in the VirtViewer
folder of All Programs in the start menu.
1. Open a web browser and download one of the following installers according to the
architecture of your system.
6
CHAPTER 2. INSTALLING LINUX VIRTUAL MACHINES
4. Install an operating system on the virtual machine. See your operating system's
documentation for instructions.
5. Register the virtual machine with the Content Delivery Network and subscribe to the
relevant entitlements.
6. Install guest agents and drivers for additional virtual machine functionality.
When all of these steps are complete, the new virtual machine is functional and ready to
perform tasks.
2. Click the New VM button to open the New Virtual Machine window.
7
Virtual Machine Management Guide
5. Add storage to the virtual machine. Attach or Create a virtual disk under Instance
Images.
Click Create and enter a Size(GB) and Alias for a new virtual disk. You can
accept the default settings for all other fields, or change them if required. See
Section A.3, “Explanation of Settings in the New Virtual Disk and Edit Virtual Disk
Windows” for more details on the fields for all disk types.
6. Connect the virtual machine to the network. Add a network interface by selecting a
vNIC profile from the nic1 drop-down list at the bottom of theGeneral tab.
8. Choose the First Device that the virtual machine will boot from on theBoot
Options tab.
9. You can accept the default settings for all other fields, or change them if required.
For more details on all fields in the New Virtual Machine window, see Section A.1,
“Explanation of Settings in the New Virtual Machine and Edit Virtual Machine
Windows”.
8
CHAPTER 2. INSTALLING LINUX VIRTUAL MACHINES
The new virtual machine is created and displays in the list of virtual machines with a status
of Down. Before you can use this virtual machine, you must install an operating system and
register with the Content Delivery Network.
1. Click the Virtual Machines tab and select a virtual machine with a status ofDown.
The Status of the virtual machine changes toUp, and the operating system installation
begins. Open a console to the virtual machine if one does not open automatically.
NOTE
A virtual machine will not start on a host that the CPU is overloaded on. By
default, a host's CPU is considered overloaded if it has a load of more than
80% for 5 minutes but these values can be changed using scheduling policies.
See Scheduling Policies in the Administration Guide for more information.
1. Install Remote Viewer if it is not already installed. See Section 1.4.1, “Installing
Console Components”.
3. Click the console button or right-click the virtual machine and select Console. A
console.vv file will be downloaded. Click on the file and a console window will
automatically open for the virtual machine.
NOTE
9
Virtual Machine Management Guide
virtual machine placement, and stores the authentication keys. You can add public keys for
each user from either the Administration Portal or the User Portal. You can access serial
consoles for only those virtual machines for which you have appropriate permissions.
IMPORTANT
To access the serial console of a virtual machine, the user must have the
UserVmManager, SuperUser, or UserInstanceManager permission on that
virtual machine. These permissions must be explicitly defined per user; it is not
enough to assign these permissions for Everyone.
The serial console is accessed via TCP port 2222 on the Manager. This port is opened during
engine-setup on new installations. The serial console relies on theovirt-vmconsole
package and the ovirt-vmconsole-proxy on the Manager, and the ovirt-vmconsole package
and the ovirt-vmconsole-host package on virtualization hosts. These packages are installed
by default on new installations. To install the packages on existing installations, reinstall the
host. See Reinstalling Hosts in the Administration Guide.
1. On the client machine from which you will access the virtual machine serial console,
generate an SSH key pair. The Manager supports standard SSH key types. For
example, generate an RSA key:
2. In the Administration Portal or the User Portal, click the name of the signed-in user
on the header bar, and then click Options to open the Edit Options window.
3. In the User's Public Key text field, paste the public key of the client machine that
will be used to access the serial console.
5. Click Edit.
6. In the Console tab of the Edit Virtual Machine window, select the Enable
VirtIO serial console check box.
a. If a single virtual machine is available, this command connects the user to that
virtual machine:
If more than one virtual machine is available, this command lists the available
virtual machines:
10
CHAPTER 2. INSTALLING LINUX VIRTUAL MACHINES
Enter the number of the machine to which you want to connect, and press
Enter.
IMPORTANT
1. Click the name of the signed-in user on the header bar then click Options to open
the Edit Options window.
3. Click OK.
The next time you log into the User Portal, if you have only one running virtual machine,
you will automatically connect to that machine.
1. Register your system with the Content Delivery Network, entering your Customer
Portal user name and password when prompted:
11
Virtual Machine Management Guide
# subscription-manager register
2. Locate the relevant subscription pools and note down the pool identifiers.
3. Use the pool identifiers located in the previous step to attach the required
entitlements.
# yum update
12
CHAPTER 2. INSTALLING LINUX VIRTUAL MACHINES
13
Virtual Machine Management Guide
2.4.2. Installing the Guest Agents and Drivers on Red Hat Enterprise
Linux
14
CHAPTER 2. INSTALLING LINUX VIRTUAL MACHINES
The Red Hat Virtualization guest agents and drivers are installed on Red Hat Enterprise
Linux virtual machines using the ovirt-guest-agent package provided by the Red Hat
Virtualization Agent repository.
Procedure 2.7. Installing the Guest Agents and Drivers on Red Hat Enterprise
Linux
The guest agent now passes usage information to the Red Hat Virtualization Manager. The
Red Hat Virtualization agent runs as a service called ovirt-guest-agent that you can
configure via the ovirt-guest-agent.conf configuration file in the /etc/ directory.
15
Virtual Machine Management Guide
5. Install an operating system on the virtual machine. See your operating system's
documentation for instructions.
6. Install guest agents and drivers for additional virtual machine functionality.
When all of these steps are complete, the new virtual machine is functional and ready to
perform tasks.
1. You can change the default virtual machine name length with the engine-config
tool. Run the following command on the Manager machine:
16
CHAPTER 3. INSTALLING WINDOWS VIRTUAL MACHINES
6. Add storage to the virtual machine. Attach or Create a virtual disk under Instance
Images.
Click Create and enter a Size(GB) and Alias for a new virtual disk. You can
accept the default settings for all other fields, or change them if required. See
Section A.3, “Explanation of Settings in the New Virtual Disk and Edit Virtual Disk
Windows” for more details on the fields for all disk types.
7. Connect the virtual machine to the network. Add a network interface by selecting a
vNIC profile from the nic1 drop-down list at the bottom of theGeneral tab.
9. Choose the First Device that the virtual machine will boot from on theBoot
Options tab.
10. You can accept the default settings for all other fields, or change them if required.
For more details on all fields in the New Virtual Machine window, see Section A.1,
“Explanation of Settings in the New Virtual Machine and Edit Virtual Machine
Windows”.
17
Virtual Machine Management Guide
The new virtual machine is created and displays in the list of virtual machines with a status
of Down. Before you can use this virtual machine, you must install an operating system and
VirtIO-optimized disk and network drivers.
Use the Run Once option to attach the diskette in a one-off boot different from theBoot
Options defined in the New Virtual Machine window. This procedure presumes that you
added a Red Hat VirtIO network interface and a disk that uses theVirtIO interface to
your virtual machine.
NOTE
4. Select the Attach Floppy check box, and select virtio-win.vfd from the drop-
down list.
5. Select the Attach CD check box, and select the required Windows ISO from the
drop-down list.
7. Configure the rest of your Run Once options as required. See Section A.5,
“Explanation of Settings in the Run Once Window” for more details.
8. Click OK.
The Status of the virtual machine changes toUp, and the operating system installation
begins. Open a console to the virtual machine if one does not open automatically.
Windows installations include an option to load additional drivers early in the installation
process. Use this option to load drivers from the virtio-win.vfd diskette that was
attached to your virtual machine as A:. For each supported virtual machine architecture
and Windows version, there is a folder on the disk containing optimized hardware device
drivers.
18
CHAPTER 3. INSTALLING WINDOWS VIRTUAL MACHINES
1. Install Remote Viewer if it is not already installed. See Section 1.4.1, “Installing
Console Components”.
3. Click the console button or right-click the virtual machine and select Console.
NOTE
19
Virtual Machine Management Guide
20
CHAPTER 3. INSTALLING WINDOWS VIRTUAL MACHINES
21
Virtual Machine Management Guide
NOTE
NOTE
NOTE
If you install the guest agents and drivers from the command line or as part of
a deployment tool such as Windows Deployment Services, you can append the
options ISSILENTMODE and ISNOREBOOT to RHEV-toolsSetup.exe to silently
install the guest agents and drivers and prevent the machine on which they
have been installed from rebooting immediately after installation. The
machine can then be rebooted later once the deployment process is complete.
3. Double-click RHEV-toolsSetup.
5. Follow the prompts on the RHEV-Tools InstallShield Wizard window. Ensure all
check boxes in the list of components are selected.
22
CHAPTER 3. INSTALLING WINDOWS VIRTUAL MACHINES
Figure 3.2. Selecting All Components of Red Hat Virtualization Tools for
Installation
The guest agents and drivers now pass usage information to the Red Hat Virtualization
Manager and allow you to access USB devices, single sign-on into virtual machines and
other functionality. The Red Hat Virtualization guest agent runs as a service called RHEV
Agent that you can configure using therhev-agent configuration file located in C:\Program
Files\Redhat\RHEV\Drivers\Agent.
23
Virtual Machine Management Guide
5. Once installation is complete, ensure the Start RHEV-apt Service check box is
selected in the RHEV-Application Provisioning Tool InstallShield Wizard
window, and click Finish to apply the changes.
Once the APT service has successfully installed or upgraded the guest tools on a virtual
machine, the virtual machine is automatically rebooted; this happens without confirmation
from the user logged in to the machine. The APT Service will also perform these operations
when a virtual machine created from a template that has the APT Service already installed
is booted for the first time.
NOTE
24
CHAPTER 4. ADDITIONAL CONFIGURATION
IMPORTANT
IMPORTANT
The following procedure assumes that you have a working IPA configuration
and that the IPA domain is already joined to the Manager. You must also
ensure that the clocks on the Manager, the virtual machine and the system on
which IPA (IdM) is hosted are synchronized using NTP.
Procedure 4.1. Configuring Single Sign-On for Red Hat Enterprise Linux Virtual
Machines
25
Virtual Machine Management Guide
6. Run the following command and follow the prompts to configure ipa-client and join
the virtual machine to the domain:
NOTE
NOTE
Red Hat Enterprise Linux 7.2 has a new version of the System Security
Services Daemon (SSSD) which introduces configuration that is
incompatible with the Red Hat Virtualization Manager guest agent
single sign-on implementation. The command will ensure that single
sign-on works.
some-ipa-user:*:936600010:936600001::/home/some-ipa-user:/bin/sh
You will need this information in the next step to create a home directory for some-
ipa-user.
# mkdir /home/some-ipa-user
b. Give the new user ownership of the new user's home directory:
26
CHAPTER 4. ADDITIONAL CONFIGURATION
Log in to the User Portal using the user name and password of a user configured to use
single sign-on and connect to the console of the virtual machine. You will be logged in
automatically.
IMPORTANT
The following procedure assumes that you have a working Active Directory
configuration and that the Active Directory domain is already joined to the
Manager. You must also ensure that the clocks on the Manager, the virtual
machine and the system on which Active Directory is hosted are synchronized
using NTP.
Procedure 4.2. Configuring Single Sign-On for Red Hat Enterprise Linux Virtual
Machines
27
Virtual Machine Management Guide
[global]
workgroup = DOMAIN
realm = REALM.LOCAL
log level = 2
syslog = 0
server string = Linux File Server
security = ads
log file = /var/log/samba/%m
max log size = 50
printcap name = cups
printing = cups
winbind enum users = Yes
winbind enum groups = Yes
winbind use default domain = true
winbind separator = +
idmap uid = 1000000-2000000
idmap gid = 1000000-2000000
template shell = /bin/bash
# wbinfo -t
# wbinfo -u
# wbinfo -g
28
CHAPTER 4. ADDITIONAL CONFIGURATION
# authconfig-tui
b. Select the Use Winbind check box, select Next and press Enter.
Log in to the User Portal using the user name and password of a user configured to use
single sign-on and connect to the console of the virtual machine. You will be logged in
automatically.
1. Select the Windows virtual machine. Ensure the machine is powered up.
4. Click OK.
6. On the virtual machine, locate the CD drive to access the contents of the guest
tools ISO file and launch RHEV-ToolsSetup.exe. After the tools have been installed,
you will be prompted to restart the machine to apply the changes.
Log in to the User Portal using the user name and password of a user configured to use
single sign-on and connect to the console of the virtual machine. You will be logged in
automatically.
4. Click OK.
29
Virtual Machine Management Guide
The USB device will only be redirected if the virtual machine is active and in focus. USB
redirection can be manually enabled each time a device is plugged in or set to
automatically redirect to active virtual machines in the SPICE client menu.
IMPORTANT
Note the distinction between the client machine and guest machine. The client
is the hardware from which you access a guest. The guest is the virtual
desktop or virtual server which is accessed through the User Portal or
Administration Portal.
Client
Windows 10
Windows 8
Windows 7
Windows 2008
Guest
Windows 7
Windows XP
Windows 2008
30
CHAPTER 4. ADDITIONAL CONFIGURATION
NOTE
If you have a 64-bit architecture PC, you must use the 64-bit version of Internet
Explorer to install the 64-bit version of the USB driver. The USB redirection will
not work if you install the 32-bit version on a 64-bit architecture. As long as
you initially install the correct USB type, you then can access USB redirection
from both 32 and 64-bit browsers.
1. When the usbdk driver is installed, select a virtual machine that has been
configured to use the SPICE protocol.
1. Click Edit.
4. Click OK.
3. Click the Console Options button and select the Enable USB Auto-Share check
box.
4. Start the virtual machine and click the Console button to connect to that virtual
machine. When you plug your USB device into the client machine, it will
automatically be redirected to appear on your guest machine.
Procedure 4.6. Using USB devices on a Red Hat Enterprise Linux client
1. Click the Virtual Machines tab and select a virtual machine that has been
configured to use the SPICE protocol.
1. Click Edit.
31
Virtual Machine Management Guide
4. Click OK.
3. Click the Console Options button and select the Enable USB Auto-Share check
box.
4. Start the virtual machine and click the Console button to connect to that virtual
machine. When you plug your USB device into the client machine, it will
automatically be redirected to appear on your guest machine.
2. Open the View drop-down menu at the top of the SPICE client window.
NOTE
NOTE
5. Click Ok.
32
CHAPTER 4. ADDITIONAL CONFIGURATION
7. Open the View drop-down menu at the top of the SPICE client window.
NOTE
SPICE
Simple Protocol for Independent Computing Environments (SPICE) is the recommended
connection protocol for both Linux virtual machines and Windows virtual machines. To open
a console to a virtual machine using SPICE, use Remote Viewer.
VNC
Virtual Network Computing (VNC) can be used to open consoles to both Linux virtual
machines and Windows virtual machines. To open a console to a virtual machine using VNC,
use Remote Viewer or a VNC client.
RDP
Remote Desktop Protocol (RDP) can only be used to open consoles to Windows virtual
machines, and is only available when you access a virtual machines from a Windows
machine on which Remote Desktop has been installed. Before you can connect to a
Windows virtual machine using RDP, you must set up remote sharing on the virtual machine
and configure the firewall to allow remote desktop connections.
NOTE
You can configure several options for opening graphical consoles for virtual machines, such
as the method of invocation and whether to enable or disable USB redirection.
33
Virtual Machine Management Guide
In the Administration Portal, right-click the virtual machine and click Console
Options.
NOTE
When the SPICE connection protocol is selected, the following options are available in the
Console Options window.
34
CHAPTER 4. ADDITIONAL CONFIGURATION
Console Invocation
Auto: The Manager automatically selects the method for invoking the console.
Native client: When you connect to the console of the virtual machine, a file
download dialog provides you with a file that opens a console to the virtual machine
via Remote Viewer.
SPICE HTML5 browser client (Tech preview): When you connect to the console
of the virtual machine, a browser tab is opened that acts as the console.
SPICE Options
Enable USB Auto-Share: Select this check box to automatically redirect USB
devices to the virtual machine. If this option is not selected, USB devices will
connect to the client machine instead of the guest virtual machine. To use the USB
device on the guest machine, manually enable it in the SPICE client menu.
35
Virtual Machine Management Guide
Open in Full Screen: Select this check box for the virtual machine console to
automatically open in full screen when you connect to the virtual machine. Press
SHIFT+F11 to toggle full screen mode on or off.
Enable SPICE Proxy: Select this check box to enable the SPICE proxy.
Enable WAN options: Select this check box to set the parameters
WANDisableEffects and WANColorDepth to animation and 16 bits respectively on
Windows virtual machines. Bandwidth in WAN environments is limited and this
option prevents certain Windows settings from consuming too much bandwidth.
When the VNC connection protocol is selected, the following options are available in the
Console Options window.
Console Invocation
Native Client: When you connect to the console of the virtual machine, a file
download dialog provides you with a file that opens a console to the virtual machine
via Remote Viewer.
36
CHAPTER 4. ADDITIONAL CONFIGURATION
noVNC: When you connect to the console of the virtual machine, a browser tab is
opened that acts as the console.
VNC Options
When the RDP connection protocol is selected, the following options are available in the
Console Options window.
Console Invocation
Auto: The Manager automatically selects the method for invoking the console.
Native client: When you connect to the console of the virtual machine, a file
download dialog provides you with a file that opens a console to the virtual machine
via Remote Desktop.
37
Virtual Machine Management Guide
RDP Options
Use Local Drives: Select this check box to make the drives on the client machine
accessible on the guest virtual machine.
When you specify the Native client console invocation option, you will connect to virtual
machines using Remote Viewer. The Remote Viewer window provides a number of options
for interacting with the virtual machine to which it is connected.
Option Hotkey
38
CHAPTER 4. ADDITIONAL CONFIGURATION
Option Hotkey
File
Screenshot: Takes a screen capture
of the active window and saves it in a
location of your specification.
View
Full screen : Toggles full screen
mode on or off. When enabled, full
screen mode expands the virtual
machine to fill the entire screen. When
disabled, the virtual machine is
displayed as a window. The hot key for
enabling or disabling full screen is
SHIFT+F11.
39
Virtual Machine Management Guide
Option Hotkey
Send key
Ctrl+Alt+Del: On a Red Hat
Enterprise Linux virtual machine, it
displays a dialog with options to
suspend, shut down or restart the
virtual machine. On a Windows virtual
machine, it displays the task manager
or Windows Security dialog.
Ctrl+Alt+F1
Ctrl+Alt+F2
Ctrl+Alt+F3
Ctrl+Alt+F4
Ctrl+Alt+F5
Ctrl+Alt+F6
Ctrl+Alt+F7
Ctrl+Alt+F8
Ctrl+Alt+F9
Ctrl+Alt+F10
Ctrl+Alt+F11
Ctrl+Alt+F12
You can access the hotkeys for a virtual machine in both full screen mode and windowed
mode. If you are using full screen mode, you can display the menu containing the button
for hotkeys by moving the mouse pointer to the middle of the top of the screen. If you are
using windowed mode, you can access the hotkeys via the Send key menu on the virtual
machine window title bar.
40
CHAPTER 4. ADDITIONAL CONFIGURATION
NOTE
If vdagent is not running on the client machine, the mouse can become
captured in a virtual machine window if it is used inside a virtual machine and
the virtual machine is not in full screen. To unlock the mouse, press
Shift+F12.
If you are prompted to download a console.vv file when attempting to open a console to a
virtual machine using the native client console option, and Remote Viewer is already
installed, then you can manually associate console.vv files with Remote Viewer so that
Remote Viewer can automatically use those files to open consoles.
In the Administration Portal, right-click the virtual machine and click Console
Options.
3. Change the console invocation method to Native client and click OK.
4. Attempt to open a console to the virtual machine, then click Save when prompted to
open or save the console.vv file.
5. Navigate to the location on your local machine where you saved the file.
6. Double-click the console.vv file and select Select a program from a list of
installed programs when prompted.
7. In the Open with window, select Always use the selected program to open
this kind of file and click the Browse button.
When you use the native client console invocation option to open a console to a virtual
machine, Remote Viewer will automatically use the console.vv file that the Red Hat
Virtualization Manager provides to open a console to that virtual machine without
prompting you to select the application to use.
41
Virtual Machine Management Guide
2. Click Edit.
4. Select the watchdog model to use from the Watchdog Model drop-down list.
5. Select an action from the Watchdog Action drop-down list. This is the action that
the virtual machine takes when the watchdog is triggered.
6. Click OK.
watchdog-device = /dev/watchdog
5. Start the watchdog service and ensure this service starts on boot:
42
CHAPTER 4. ADDITIONAL CONFIGURATION
WARNING
2. Confirm that the watchdog card has been identified by the virtual machine:
3. Run one of the following commands to confirm that the watchdog is active:
The watchdog timer can no longer be reset, so the watchdog counter reaches zero after a
short period of time. When the watchdog counter reaches zero, the action specified in the
Watchdog Action drop-down menu for that virtual machine is performed.
NOTE
43
Virtual Machine Management Guide
44
CHAPTER 4. ADDITIONAL CONFIGURATION
45
Virtual Machine Management Guide
46
CHAPTER 4. ADDITIONAL CONFIGURATION
2. Click Edit.
4. Select the Specific Host(s) radio button and select a host from the list. The
selected host must have at least two NUMA nodes.
5. Select Do not allow migration from the Migration Options drop-down list.
6. Enter a number into the NUMA Node Count field to assign virtual NUMA nodes to the
virtual machine.
7. Select Strict, Preferred, or Interleave from the Tune Mode drop-down list. If the
selected mode is Preferred, the NUMA Node Count must be set to 1.
47
Virtual Machine Management Guide
9. In the NUMA Topology window, click and drag virtual NUMA nodes from the box on
the right to host NUMA nodes on the left as required, and click OK.
NOTE
If you do not pin the virtual NUMA node to a host NUMA node, the system
defaults to the NUMA node that contains the host device's memory-mapped
I/O (MMIO), provided that there are one or more host devices and all of those
devices are from a single NUMA node.
Red Hat Virtualization 4.1 supports errata management with Red Hat Satellite 6.1.
The host that the virtual machine runs on also needs to be configured to receive
errata information from Satellite. See Configuring Satellite Errata Management for a
Host in the Administration Guide for more information.
The virtual machine must have the ovirt-guest-agent package installed. This
package allows the virtual machine to report its host name to the Red Hat
Virtualization Manager. This allows the Red Hat Satellite server to identify the virtual
machine as a content host and report the applicable errata. For more information on
installing the ovirt-guest-agent package see Section 2.4.2, “Installing the Guest
Agents and Drivers on Red Hat Enterprise Linux” for Red Hat Enterprise Linux virtual
48
CHAPTER 4. ADDITIONAL CONFIGURATION
machines and Section 3.3.2, “Installing the Guest Agents and Drivers on Windows”
for Windows virtual machines.
IMPORTANT
Virtual machines are identified in the Satellite server by their FQDN. This
ensures that an external content host ID does not need to be maintained in
Red Hat Virtualization.
NOTE
2. Click Edit.
4. Select the required Satellite server from the Provider drop-down list.
5. Click OK.
Headless virtual machines can be administered via a Serial Console, SSH, or any other
service for command line access. Headless mode is applied via the Console tab, which is
available from the cluster level when creating or editing virtual machines and machine
pools, and when editing templates. It is also available when creating or editing instance
types.
If you are creating a new headless virtual machine, you can use the Run Once window to
access the virtual machine via a graphical console for the first run only. See Section A.5,
“Explanation of Settings in the Run Once Window” for more details.
Prerequisites
If you are editing an existing virtual machine, and the Red Hat Virtualization guest
agent has not been installed, note the machine's IP prior to selecting Headless
Mode.
49
Virtual Machine Management Guide
Before running a virtual machine in headless mode, the GRUB configuration for this
machine must be set to console mode otherwise the guest operating system's boot
process will hang. To set console mode, comment out the spashimage flag in the
GRUB menu configuration file:
NOTE
Restart the virtual machine if it is running when selecting the Headless Mode
option.
2. Click Edit.
4. Select Headless Mode. All other fields in theGraphical Console section are
disabled.
5. Optionally, select Enable VirtIO serial console to enable comunicating with the
virtual machine via serial console. This is higly recommended.
6. Reboot the virtual machine if it is running. See Section 6.3, “Rebooting a Virtual
Machine”.
50
CHAPTER 5. EDITING VIRTUAL MACHINES
2. Click Edit.
Name
Description
Comment
Delete Protection
Network Interfaces
Memory Size (Edit this field to hot plug virtual memory. SeeSection 5.5, “Hot
Plugging Virtual Memory”.)
Virtual Sockets (Edit this field to hot plug CPUs. See Section 5.6, “Hot Plugging
vCPUs”.)
Highly Available
Icon
4. Click OK.
Changes from the list in step 3 are applied immediately. All other changes are applied
when you shut down and restart your virtual machine. Until then, an orange icon ( )
appears as a reminder of the pending changes.
51
Virtual Machine Management Guide
2. Click Edit.
4. Select the IO Threads Enabled check box. Red Hat recommends using the default
number of IO threads, which is 1.
5. Click OK.
If you increased the number of IO threads, you must reactivate the disks so that the
disks will be remapped according to the correct number of controllers:
You can view the IO threads by clicking Vm Devices in the details pane.
The assignment of disks to controllers displays only in the XML, not in the Administration
Portal.
52
CHAPTER 5. EDITING VIRTUAL MACHINES
3. Click New.
5. Use the drop-down lists to select the Profile and the Type of the network interface.
The Profile and Type drop-down lists are populated in accordance with the profiles
and network types available to the cluster and the network interface cards available
to the virtual machine.
6. Select the Custom MAC address check box and enter a MAC address for the network
interface card as required.
7. Click OK.
The new network interface is listed in the Network Interfaces tab in the details pane of
the virtual machine. The Link State is set to Up by default when the network interface
card is defined on the virtual machine and connected to the network.
For more details on the fields in the New Network Interface window, see Section A.2,
“Explanation of Settings in the New Network Interface and Edit Network Interface
Windows”.
53
Virtual Machine Management Guide
2. Click the Network Interfaces tab in the details pane and select the network
interface to edit.
3. Click Edit.
4. Change settings as required. You can specify the Name, Profile, Type, and Custom
MAC address. See Section 5.3.1, “Adding a New Network Interface”.
5. Click OK.
NOTE
The guest operating system must support hot plugging network interfaces.
2. Click the Network Interfaces tab in the details pane and select the network
interface to hot plug.
3. Click Edit.
4. Set the Card Status to Plugged to enable the network interface, or set it to
Unplugged to disable the network interface.
5. Click OK.
2. Click the Network Interfaces tab in the details pane and select the network
interface to remove.
3. Click Remove.
4. Click OK.
54
CHAPTER 5. EDITING VIRTUAL MACHINES
Image is the default type of disk. You can also add aDirect LUN disk or a Cinder
(OpenStack Volume) disk. Image disk creation is managed entirely by the Manager.Direct
LUN disks require externally prepared targets that already exist.Cinder disks require
access to an instance of OpenStack Volume that has been added to the Red Hat
Virtualization environment using the External Providers window; see Adding an
OpenStack Volume (Cinder) Instance for Storage Management for more information.
Existing disks are either floating disks or shareable disks attached to virtual machines.
3. Click New.
4. Use the appropriate radio buttons to switch between Image, Direct LUN, or Cinder.
Virtual disks added in the User Portal can only be Image disks. Direct LUN and
Cinder disks can be added in the Administration Portal.
6. Use the drop-down lists and check boxes to configure the disk. See Section A.3,
“Explanation of Settings in the New Virtual Disk and Edit Virtual Disk Windows” for
more details on the fields for all disk types.
7. Click OK.
55
Virtual Machine Management Guide
The new disk appears in the details pane after a short time.
Floating disks can minimize the amount of time required to set up virtual machines.
Designating a floating disk as storage for a virtual machine makes it unnecessary to wait
for disk preallocation at the time of a virtual machine's creation.
Floating disks can be attached to a single virtual machine, or to multiple virtual machines if
the disk is shareable. Each virtual machine that uses the shared disk can use a different
disk interface type.
Once a floating disk is attached to a virtual machine, the virtual machine can access it.
3. Click Attach.
4. Select one or more virtual disks from the list of available disks and select the
required interface from the Interface drop-down.
56
CHAPTER 5. EDITING VIRTUAL MACHINES
5. Click OK.
NOTE
2. Click the Disks tab in the details pane and select the disk to edit.
3. Click Edit.
5. Click OK.
The target disk's status becomes locked for a short time, during which the drive is resized.
When the resizing of the drive is complete, the status of the drive becomes OK.
NOTE
The guest operating system must support hot plugging virtual disks.
2. Click the Disks tab in the details pane and select the virtual disk to hot plug.
3. Click Activate to enable the disk, or click Deactivate to disable the disk.
4. Click OK.
57
Virtual Machine Management Guide
2. Click the Disks tab in the details pane and select the virtual disk to remove.
3. Click Deactivate.
4. Click OK.
5. Click Remove.
6. Optionally, select the Remove Permanently check box to completely remove the
virtual disk from the environment. If you do not select this option - for example,
because the disk is a shared disk - the virtual disk will remain in the Disks resource
tab.
7. Click OK.
If the disk was created as block storage, for example iSCSI, and the Wipe After Delete
check box was selected when creating the disk, you can view the log file on the host to
confirm that the data has been wiped after permanently removing the disk. See Settings to
Wipe Virtual Disks After Deletion in the Administration Guide.
If the disk was created as block storage, for example iSCSI, and the Discard After
Delete check box was selected on the storage domain before the disk was removed, a
blkdiscard command is called on the logical volume when it is removed and the
underlying storage is notified that the blocks are free. See Setting Discard After Delete for a
Storage Domain in the Administration Guide. A blkdiscard is also called on the logical
volume when a virtual disk is removed if the virtual disk is attached to at least one virtual
machine with the Enable Discard check box selected.
NOTE
1. Select a storage domain that has been imported into the data center.
3. Select one or more disk images and click Import to open the Import Disk(s)
window.
58
CHAPTER 5. EDITING VIRTUAL MACHINES
pane. Floating disks created outside of a Red Hat Virtualization environment are not
registered with the Manager. Scan the storage domain to identify unregistered floating
disks to be imported.
NOTE
1. Select a storage domain that has been imported into the data center.
2. Right-click the storage domain and select Scan Disks so that the Manager can
identify unregistered disks.
4. Select one or more disk images and click Import to open the Import Disk(s)
window.
IMPORTANT
This feature is currently not supported for the self-hosted engine Manager
virtual machine.
IMPORTANT
1. Click the Virtual Machines tab and select a running virtual machine.
2. Click Edit.
59
Virtual Machine Management Guide
4. Increase the Memory Size by entering the total amount required. Memory can be
added in multiples of 256 MB. By default, the maximum memory allowed for the
virtual machine is set to 4x the memory size specified. Though the value is changed
in the user interface, the maximum value is not hot plugged, and you will see the
pending changes icon. To avoid that, you can change the maximum memory back
to the original value.
5. Click OK.
This action opens the Pending Virtual Machine changes window, as some values
such as maxMemorySizeMb and minAllocatedMem will not change until the virtual
machine is restarted. However, the hot plug action is triggered by the change to the
Memory Size value, which can be applied immediately.
6. Click OK.
The virtual machine's Defined Memory is updated in the General tab in the details pane.
You can see the newly added memory device in the Vm Devices tab in the details pane.
60
CHAPTER 5. EDITING VIRTUAL MACHINES
IMPORTANT
Hot unplugging a vCPU is only supported if the vCPU was previously hot
plugged. A virtual machine's vCPUs cannot be hot unplugged to less vCPUs
than it was originally created with.
The virtual machine's Operating System must be explicitly set in the New Virtual
Machine or Edit Virtual Machine window.
The virtual machine's operating system must support CPU hot plug. See the table
below for support details.
Windows virtual machines must have the guest agents installed. See Section 3.3.2,
“Installing the Guest Agents and Drivers on Windows”.
1. Click the Virtual Machines tab and select a running virtual machine.
2. Click Edit.
5. Click OK.
Table 5.1. Operating System Support Matrix for vCPU Hot Plug
61
Virtual Machine Management Guide
62
CHAPTER 5. EDITING VIRTUAL MACHINES
even if all of the specified hosts are unavailable. Multi-host pinning can be used to limit
virtual machines to hosts with, for example, the same physical hardware configuration.
A virtual machine that is pinned to multiple hosts cannot be live migrated, but in the event
of a host failure, any virtual machine configured to be highly available is automatically
restarted on one of the other hosts to which the virtual machine is pinned.
NOTE
High availability is not supported for virtual machines that are pinned to a
single host.
2. Click Edit.
4. Select the Specific Host(s) radio button under Start Running On and select two
or more hosts from the list.
5. Select Do not allow migration from the Migration Options drop-down list.
8. Select Low, Medium, or High from the Priority drop-down list. When migration is
triggered, a queue is created in which the high priority virtual machines are
migrated first. If a cluster is running low on resources, only the high priority virtual
machines are migrated.
9. Click OK.
NOTE
You can only use ISO files that have been added to theISO domain of the
virtual machine's cluster.
1. Click the Virtual Machines tab and select a running virtual machine.
63
Virtual Machine Management Guide
Select an ISO file from the list to eject the CD currently accessible to the virtual
machine and mount that ISO file as a CD.
Select [Eject] from the list to eject the CD currently accessible to the virtual
machine.
4. Click OK.
1. Ensure that the smart card hardware is plugged into the client machine and is
installed according to manufacturer's directions.
3. Click Edit.
4. Click the Console tab and select the Smartcard enabled check box.
5. Click OK.
6. Connect to the running virtual machine by clicking the Console icon. Smart card
authentication is now passed from the client hardware to the virtual machine.
IMPORTANT
If the Smart card hardware is not correctly installed, enabling the Smart card
feature will result in the virtual machine failing to load properly.
2. Click Edit.
3. Click the Console tab, and clear the Smartcard enabled check box.
4. Click OK.
1. Smart cards may require certain libraries in order to access their certificates. These
libraries must be visible to the NSS library, which spice-gtk uses to provide the
smart card to the guest. NSS expects the libraries to provide the PKCS #11
interface.
64
CHAPTER 5. EDITING VIRTUAL MACHINES
Procedure 5.22. Configuring RHEL clients with CoolKey Smart Card Middleware
CoolKey Smart Card middleware is a part of Red Hat Enterprise Linux. Install the
Smart card support group. If the Smart Card Support group is installed on a Red
Hat Enterprise Linux system, smart cards are redirected to the guest when Smart
Cards are enabled. The following command installs the Smart card support group:
Procedure 5.23. Configuring RHEL clients with Other Smart Card Middleware
Register the library in the system's NSS database. Run the following command as
root:
Red Hat does not provide PKCS #11 support to Windows clients. Libraries that
provide PKCS #11 support must be obtained from third parties. When such libraries
are obtained, register them by running the following command as a user with
elevated privileges:
65
Virtual Machine Management Guide
1. Click the Virtual Machines tab and select a running virtual machine.
3. Optionally in the Administration Portal, enter a Reason for shutting down the virtual
machine in the Shut down Virtual Machine(s) confirmation window. This allows
you to provide an explanation for the shutdown, which will appear in the logs and
when the virtual machine is powered on again.
NOTE
The virtual machine shutdown Reason field will only appear if it has
been enabled in the cluster settings. For more information, see
Explanation of Settings and Controls in the New Cluster and Edit Cluster
Windows in the Administration Guide.
The virtual machine shuts down gracefully and the Status of the virtual machine changes
to Down.
1. Click the Virtual Machines tab and select a running virtual machine.
1. Click the Virtual Machines tab and select a running virtual machine.
66
CHAPTER 6. ADMINISTRATIVE TASKS
The Status of the virtual machine changes toReboot In Progress before returning to Up.
IMPORTANT
The Remove button is disabled while virtual machines are running; you must
shut down a virtual machine before you can remove it.
1. Click the Virtual Machines tab and select the virtual machine to remove.
2. Click Remove.
3. Optionally, select the Remove Disk(s) check box to remove the virtual disks
attached to the virtual machine together with the virtual machine. If the Remove
Disk(s) check box is cleared, then the virtual disks remain in the environment as
floating disks.
4. Click OK.
IMPORTANT
The Clone VM button is disabled while virtual machines are running; you must
shut down a virtual machine before you can clone it.
1. Click the Virtual Machines tab and select the virtual machine to clone.
4. Click OK.
6.6.1. Updating the Guest Agents and Drivers on Red Hat Enterprise
Linux
67
Virtual Machine Management Guide
Update the guest agents and drivers on your Red Hat Enterprise Linux virtual machines to
use the latest version.
Procedure 6.6. Updating the Guest Agents and Drivers on Red Hat Enterprise
Linux
1. On the Red Hat Virtualization Manager, update the Red Hat Virtualization Guest
Tools to the latest version:
2. Upload the ISO file to your ISO domain, replacing [ISODomain] with the name of your
ISO domain:
NOTE
3. In the Administration or User Portal, if the virtual machine is running, use the
68
CHAPTER 6. ADMINISTRATIVE TASKS
4. Select the CD Drive containing the updated ISO and execute the RHEV-
ToolsSetup.exe file.
For more information on configuring a virtual machine to display available errata see
Section 4.7, “Configuring Red Hat Satellite Errata Management for a Virtual Machine”
A UserVmManager is a system administration role for virtual machines in a data center. This
role can be applied to specific virtual machines, to a data center, or to the whole virtualized
environment; this is useful to allow different users to manage certain virtual resources.
The user virtual machine administrator role permits the following actions:
NOTE
Many end users are concerned solely with the virtual machine resources of the virtualized
environment. As a result, Red Hat Virtualization provides several user roles which enable
the user to manage virtual machines specifically, but not other resources in the data
center.
69
Virtual Machine Management Guide
UserRole Can access and use virtual Can log in to the User Portal
machines and pools. and use virtual machines and
pools.
70
CHAPTER 6. ADMINISTRATIVE TASKS
PowerUserRole Can create and manage Apply this role to a user for
virtual machines and the whole environment with
templates. the Configure window, or for
specific data centers or
clusters. For example, if a
PowerUserRole is applied on a
data center level, the
PowerUser can create virtual
machines and templates in
the data center. Having a
PowerUserRole is equivalent
to having the VmCreator,
DiskCreator , and
TemplateCreator roles.
71
Virtual Machine Management Guide
If you are creating virtual machines for users other than yourself, you have to assign roles
to the users before they can use the virtual machines. Note that permissions can only be
assigned to existing users. See Users and Roles in the Red Hat Virtualization Administration
Guide for details on creating user accounts.
The User Portal supports three default roles: User, PowerUser and UserVmManager.
However, customized roles can be configured via the Administration Portal. The default
roles are described below.
A User can connect to and use virtual machines. This role is suitable for desktop
end users performing day-to-day tasks.
A PowerUser can create virtual machines and view virtual resources. This role is
suitable if you are an administrator or manager who needs to provide virtual
resources for your employees.
A UserVmManager can edit and remove virtual machines, assign user permissions,
use snapshots and use templates. It is suitable if you need to make configuration
changes to your virtual environment.
When you create a virtual machine, you automatically inherit UserVmManager privileges.
This enables you to make changes to the virtual machine and assign permissions to the
users you manage, or users who are in your Identity Management (IdM) or RHDS group.
See Administration Guide for more information.
3. Click Add.
4. Enter a name, or user name, or part thereof in the Search text box, and click Go. A
list of possible matches display in the results list.
7. Click OK.
The user's name and role display in the list of users permitted to access this virtual
machine.
72
CHAPTER 6. ADMINISTRATIVE TASKS
NOTE
3. Click Remove. A warning message displays, asking you to confirm removal of the
selected permissions.
6.9. SNAPSHOTS
73
Virtual Machine Management Guide
NOTE
5. Use the Save Memory check box if you want to include the virtual machine's memory
in the snapshot.
6. Click OK.
The virtual machine's operating system and applications on the selected disk(s) are stored
in a snapshot that can be previewed or restored. The snapshot is created with a status of
Locked, which changes to Ok. When you click on the snapshot, its details are shown on the
General, Disks, Network Interfaces, and Installed Applications tabs in the right side-
pane of the details pane.
74
CHAPTER 6. ADMINISTRATIVE TASKS
2. Click the Snapshots tab in the details pane to list the available snapshots.
3. Select a snapshot to restore in the left side-pane. The snapshot details display in
the right side-pane.
4. Click the drop-down menu beside Preview to open the Custom Preview Snapshot
window.
5. Use the check boxes to select the VM Configuration, Memory, and disk(s) you want
to restore, then click OK. This allows you to create and restore from a customized
snapshot using the configuration and disk(s) from multiple snapshots.
75
Virtual Machine Management Guide
The status of the snapshot changes to Preview Mode. The status of the virtual
machine briefly changes to Image Locked before returning to Down.
6. Start the virtual machine; it runs using the disk image of the snapshot.
7. Click Commit to permanently restore the virtual machine to the condition of the
snapshot. Any subsequent snapshots are erased.
Alternatively, click the Undo button to deactivate the snapshot and return the virtual
machine to its previous state.
2. Click the Snapshots tab in the details pane to list the available snapshots.
76
CHAPTER 6. ADMINISTRATIVE TASKS
5. Click OK.
After a short time, the cloned virtual machine appears in the Virtual Machines tab in the
navigation pane with a status of Image Locked. The virtual machine will remain in this state
until Red Hat Virtualization completes the creation of the virtual machine. A virtual
machine with a preallocated 20 GB hard drive takes about fifteen minutes to create.
Sparsely-allocated virtual disks take less time to create than do preallocated virtual disks.
When the virtual machine is ready to use, its status changes from Image Locked to Down in
the Virtual Machines tab in the navigation pane.
77
Virtual Machine Management Guide
IMPORTANT
When you delete a snapshot from an image chain, ensure there is enough free
space in the storage domain to temporarily accommodate both the original
volume and the newly merged volume. Otherwise, snapshot deletion will fail
and you will need to export and re-import the volume to remove snapshots.
This is due to the data from the two volumes being merged in the resized
volume and the resized volume growing to accommodate the total size of the
two merged images.
2. Click the Snapshots tab in the details pane to list the snapshots for that virtual
machine.
4. Click Delete.
5. Click OK.
NOTE
If the deletion fails, fix the underlying problem (for example, a failed host, an
inaccessible storage device, or even a temporary network issue) and try again.
78
CHAPTER 6. ADMINISTRATIVE TASKS
Virtual machines can be directly attached to the host devices for improved performance if a
compatible host has been configured for direct device assignment. Host devices are
devices that are physically plugged into the host, including SCSI (for example tapes, disks,
changers), PCI (for example NICs, GPUs, and HBAs), and USB (for example mice, cameras,
and disks).
1. Select a virtual machine and click the Host Devices tab in the details pane to list
the host devices already attached to this virtual machine. A virtual machine can
only have devices attached from the same host. If a virtual machine has attached
devices from one host, and you attach a device from another host, the attached
devices from the previous host will be automatically removed.
4. Use the Capability dropdown menu to list thepci, scsi, or usb_device host
devices.
5. Select the check boxes of the devices to attach to the virtual machine from the
Available Host Devices pane and click the directional arrow button to transfer
these devices to the Host Devices to be attached pane, creating a list of the
devices to attach to the virtual machine.
6. When you have transferred all desired host devices to the Host Devices to be
attached pane, click OK to attach these devices to the virtual machine and close the
window.
These host devices will be attached to the virtual machine when the virtual machine is next
powered on.
If you are removing all host devices directly attached to the virtual machine in order to add
devices from a different host, you can instead add the devices from the desired host, which
will automatically remove all of the devices already attached to the virtual machine.
1. Select the virtual machine and click the Host Devices tab in the details pane to list
the host devices attached to the virtual machine.
2. Select the host device to detach from the virtual machine, or hold Ctrl to select
multiple devices, and click Remove device to open the Remove Host Device(s)
window.
3. Click OK to confirm and detach these devices from the virtual machine.
79
Virtual Machine Management Guide
If the virtual machine has any host devices attached to it, pinning it to another host will
automatically remove the host devices from the virtual machine.
1. Select a virtual machine and click the Host Devices tab in the details pane.
Virtual machine affinity is applied to virtual machines by adding virtual machines to one or
more affinity groups. An affinity group is a group of two or more virtual machines for which
a set of identical parameters and conditions apply. These parameters include positive (run
together) affinity that ensures the virtual machines in an affinity group run on the same
host or hosts in a group, and negative (run independently) affinity that ensures the virtual
machines in an affinity group run on different hosts.
IMPORTANT
A further set of conditions can then be applied to these parameters in the associated
scheduling policy.
Hard enforcement - ensures that virtual machines in the affinity group run on a
specified host or hosts in a group regardless of external conditions. The filter
modules in the scheduling policy implement hard enforcement.
80
CHAPTER 6. ADMINISTRATIVE TASKS
The combination of an affinity group, its parameters, and its conditions is known as an
affinity policy. Affinity policies are applied to running virtual machines immediately, without
having to restart.
NOTE
Affinity groups are applied to virtual machines on the cluster level. When a
virtual machine is moved from one cluster to another, that virtual machine is
removed from all affinity groups in the source cluster.
3. Click New.
5. From the VM Affinity Rule drop-down, select Positive to apply positive affinity or
Negative to apply negative affinity. Select Disable to disable the affinity rule.
6. Select the Enforcing check box to apply hard enforcement, or ensure this check
box is cleared to apply soft enforcement.
7. Use the drop-down list to select the virtual machines to be added to the affinity
group. Use the + and - buttons to add or remove additional virtual machines.
8. Click OK.
3. Click Edit.
4. Change the VM Affinity Rule drop-down and Enforcing check box to the
preferred values and use the + and - buttons to add or remove virtual machines to
or from the affinity group.
5. Click OK.
81
Virtual Machine Management Guide
3. Click Remove.
4. Click OK.
The affinity policy that applied to the virtual machines that were members of that affinity
group no longer applies.
NOTE
Virtual machines and templates stored in Open Virtual Machine Format (OVF) can be
exported from and imported to data centers in the same or different Red Hat Virtualization
environment. Virtual machines stored in an Open Virtual Appliance (OVA) file can be
imported to data centers.
To export or import virtual machines and templates, an active export domain must be
attached to the data center containing the virtual machine or template to be exported or
imported. An export domain acts as a temporary storage area containing two directories for
each exported virtual machine or template. One directory contains the OVF files for the
virtual machine or template. The other directory holds the disk image or images for the
virtual machine or template.
There are three stages to exporting and importing virtual machines and templates:
2. Detach the export domain from one data center, and attach it to another. You can
attach it to a different data center in the same Red Hat Virtualization environment,
or attach it to a data center in a separate Red Hat Virtualization environment that is
managed by another installation of the Red Hat Virtualization Manager.
NOTE
3. Import the virtual machine or template into the data center to which the export
domain is attached.
82
CHAPTER 6. ADMINISTRATIVE TASKS
When you export or import a virtual machine or template, properties including basic details
such as the name and description, resource allocation, and high availability settings of that
virtual machine or template are preserved. Specific user roles and permissions, however,
are not preserved during the export process. If certain user roles and permissions are
required to access the virtual machine or template, they will need to be set again after the
virtual machine or template is imported.
You can also use the V2V feature to import virtual machines from other virtualization
providers, such as Xen or VMware, or import Windows virtual machines. V2V converts
virtual machines so that they can be hosted by Red Hat Virtualization. For more information
on installing and using V2V, see Converting Virtual Machines from Other Hypervisors to
KVM with virt-v2v.
IMPORTANT
WARNING
2. Click Export.
Force Override: overrides existing images of the virtual machine on the export
domain.
Collapse Snapshots: creates a single export volume per disk. This option
removes snapshot restore points and includes the template in a template-based
virtual machine, and removes any dependencies a virtual machine has on a
template. For a virtual machine that is dependent on a template, either select
this option, export the template with the virtual machine, or make sure the
template exists in the destination data center.
83
Virtual Machine Management Guide
NOTE
4. Click OK.
The export of the virtual machine begins. The virtual machine displays in the Virtual
Machines results list with an Image Locked status while it is exported. Depending on the
size of your virtual machine hard disk images, and your storage hardware, this can take up
to an hour. Use the Events tab to view the progress. When complete, the virtual machine
has been exported to the export domain and displays on the VM Import tab of the export
domain's details pane.
Procedure 6.22. Importing a Virtual Machine into the Destination Data Center
1. Click the Storage tab, and select the export domain in the results list. The export
domain must have a status of Active.
2. Select the VM Import tab in the details pane to list the available virtual machines to
import.
84
CHAPTER 6. ADMINISTRATIVE TASKS
5. Select the Collapse Snapshots check box to remove snapshot restore points and
include templates in template-based virtual machines.
6. Click the virtual machine to be imported and click on the Disks sub-tab. From this
tab, you can use the Allocation Policy and Storage Domain drop-down lists to
select whether the disk used by the virtual machine will be thinly provisioned or
preallocated, and can also select the storage domain on which the disk will be
stored. An icon is also displayed to indicate which of the disks to be imported acts as
the boot disk for that virtual machine.
The Import Virtual Machine Conflict window opens if the virtual machine exists
in the virtualized environment.
85
Virtual Machine Management Guide
Don't import
Import as cloned and enter a unique name for the virtual machine in theNew
Name field.
9. Optionally select the Apply to all check box to import all duplicated virtual
machines with the same suffix, and then enter a suffix in the Suffix to add to
the cloned VMs field.
IMPORTANT
During a single import operation, you can only import virtual machines that
share the same architecture. If any of the virtual machines to be imported
have a different architecture to that of the other virtual machines to be
imported, a warning will display and you will be prompted to change your
selection so that only virtual machines with the same architecture will be
imported.
86
CHAPTER 6. ADMINISTRATIVE TASKS
Red Hat Virtualization uses V2V to import VMware virtual machines. For OVA files, the only
disk format Red Hat Virtualization supports is VMDK.
The virt-v2v package must be installed on at least one host (referred to in this procedure as
the proxy host). The virt-v2v package is available by default on Red Hat Virtualization Hosts
(RHVH) and is installed on Red Hat Enterprise Linux hosts as a dependency of VDSM when
added to the Red Hat Virtualization environment. Red Hat Enterprise Linux hosts must be
Red Hat Enterprise Linux 7.2 or later.
NOTE
The virt-v2v package is not available on the ppc64le architecture and these
hosts cannot be used as proxy hosts.
IMPORTANT
An import operation can only include virtual machines that share the same
architecture. If any virtual machine to be imported has a different
architecture, a warning will display and you will be prompted to change your
selection to include only virtual machines with the same architecture.
NOTE
If the import fails, refer to the relevant log file in /var/log/vdsm/import/ and
to /var/log/vdsm/vdsm.log on the proxy host for details.
1. Shut down the virtual machine. Starting the virtual machine through VMware during
the import process can result in data corruption.
2. In the Virtual Machines tab, click Import to open the Import Virtual
Machine(s) window.
87
Virtual Machine Management Guide
4. If you have configured a VMware provider as an external provider, select it from the
External Provider list. Verify that the provider credentials are correct. If you did
not specify a destination data center or proxy host when configuring the external
provider, select those options now.
5. If you have not configured a VMware provider, or want to import from a new VMware
provider, provide the following details:
a. Select from the list the Data Center in which the virtual machine will be
available.
b. Enter the IP address or fully qualified domain name of the VMware vCenter
instance in the vCenter field.
c. Enter the IP address or fully qualified domain name of the host from which the
virtual machines will be imported in the ESXi field.
d. Enter the name of the data center and the cluster in which the specified ESXi
host resides in the Data Center field.
e. If you have exchanged the SSL certificate between the ESXi host and the
Manager, leave Verify server's SSL certificate checked to verify the ESXi
host's certificate. If not, uncheck the option.
88
CHAPTER 6. ADMINISTRATIVE TASKS
f. Enter the Username and Password for the VMware vCenter instance. The user
must have access to the VMware data center and ESXi host on which the virtual
machines reside.
g. Select a host in the chosen data center with virt-v2v installed to serve as the
Proxy Host during virtual machine import operations. This host must also be
able to connect to the network of the VMware vCenter external provider.
h. Click Load to list the virtual machines on the VMware provider that can be
imported.
i. Select one or more virtual machines from the Virtual Machines on Source list,
and use the arrows to move them to the Virtual Machines to Import list.
NOTE
If required, you can change the driver type to VirtIO manually after
the import. To change the driver type after a virtual machine has
been imported, see Section 5.3.2, “Editing a Network Interface”. If
the network device uses driver types other than e1000 or rtl8139,
the driver type is changed to VirtIO automatically during the import.
The Attach VirtIO-drivers check box allows the VirtIO drivers to
be injected into the imported virtual machine files so that when the
driver is changed to VirtIO, the device will be properly detected by
the operating system.
6. Click Next.
c. Select the Collapse Snapshots check box to remove snapshot restore points
and include templates in template-based virtual machines.
d. Select the Clone check box to change the virtual machine name and MAC
addresses, and clone all disks, removing all snapshots. If a virtual machine
appears with a warning symbol beside its name or has a tick in the VM in
System column, you must clone the virtual machine and change its name.
e. Select each virtual machine to be imported and click the Disks sub-tab. Use the
Allocation Policy and Storage Domain lists to select whether the disk used
by the virtual machine will be thinly provisioned or preallocated, and select the
storage domain on which the disk will be stored. An icon displays to indicate
which imported disk will be the boot disk for that virtual machine.
f. If you selected the Clone check box, change the name of the virtual machine in
the General sub-tab.
89
Virtual Machine Management Guide
The CPU type of the virtual machine must be the same as the CPU type of the cluster into
which it is being imported.
2. Select a cluster.
3. Click Edit.
3. Click Edit.
IMPORTANT
Currently, OVA files can only be imported from a VMware host. KVM and Xen
are not supported.
1. Copy the OVA file to a host in your cluster, in a file system location such as
/var/tmp.
NOTE
2. Ensure that the OVA file has permissions allowing read/write access to the qemu user
(UID 36) and the kvm group (GID 36):
90
CHAPTER 6. ADMINISTRATIVE TASKS
3. In the Virtual Machines tab, click Import to open the Import Virtual
Machine(s) window.
b. Select a host from the Host list. This will be the same host that you exported
from the VMware provider.
e. Select one or more virtual machines from the Virtual Machines on Source list,
and use the arrows to move them to the Virtual Machines to Import list.
4. Click Next.
a. Select the Target Cluster where the virtual machines will reside.
d. Optionally, select the Attach VirtIO-Drivers check box and select the
appropriate image on the list to add VirtIO drivers.
e. Click each virtual machine you will be importing. On the General sub-tab, select
the Operating System.
f. On the Network Interfaces sub-tab, select the Network Name and Profile
Name.
g. Click the Disks sub-tab to view the Alias, Virtual Size and Actual Size of
the virtual machine.
The virt-v2v package must be installed on at least one host (referred to in this procedure as
the proxy host). The virt-v2v package is available by default on Red Hat Virtualization Hosts
(RHVH) and is installed on Red Hat Enterprise Linux hosts as a dependency of VDSM when
added to the Red Hat Virtualization environment. Red Hat Enterprise Linux hosts must be
Red Hat Enterprise Linux 7.2 or later.
91
Virtual Machine Management Guide
WARNING
If you are importing a Windows virtual machine from a Xen host and you
are using VirtIO devices, install the VirtIO drivers before importing the
virtual machine. If the drivers are not installed, the virtual machine may
not boot after import.
The VirtIO drivers can be installed from the virtio-win.iso or the rhev-
tools-setup.iso. See Section 3.3.2, “Installing the Guest Agents and
Drivers on Windows” for details.
If you are not using VirtIO drivers, review the configuration of the virtual
machine after import, and before first boot to ensure that VirtIO devices
are not being used.
NOTE
The virt-v2v package is not available on the ppc64le architecture and these
hosts cannot be used as proxy hosts.
IMPORTANT
An import operation can only include virtual machines that share the same
architecture. If any virtual machine to be imported has a different
architecture, a warning will display and you will be prompted to change your
selection to include only virtual machines with the same architecture.
NOTE
If the import fails, refer to the relevant log file in /var/log/vdsm/import/ and
to /var/log/vdsm/vdsm.log on the proxy host for details.
1. Shut down the virtual machine. Starting the virtual machine through Xen during the
import process can result in data corruption.
2. Enable public key authentication between the proxy host and the Xen host:
a. Log in to the proxy host and generate SSH keys for the vdsm user.
c. Log in to the Xen host to verify that the login works correctly.
92
CHAPTER 6. ADMINISTRATIVE TASKS
3. Log in to the Administration Portal. In the Virtual Machines tab, click Import to
open the Import Virtual Machine(s) window.
6. Optionally, select a Xen provider External Provider from the drop-down list. The
URI will be pre-filled with the correct URI. See Adding a Xen Host as a Virtual
Machine Provider in the Administration Guide for more information.
7. Enter the URI of the Xen host. The required format is pre-filled; you must replace
<hostname> with the host name of the Xen host.
8. Select the proxy host from the Proxy Host drop-down list.
9. Click Load to list the virtual machines on the Xen host that can be imported.
10. Select one or more virtual machines from the Virtual Machines on Source list,
and use the arrows to move them to the Virtual Machines to Import list.
93
Virtual Machine Management Guide
NOTE
12. Select the Cluster in which the virtual machines will reside.
14. Use the Allocation Policy and Storage Domain lists to select whether the disk
used by the virtual machines will be thinly provisioned or preallocated, and select
the storage domain on which the disk will be stored.
NOTE
15. If a virtual machine appears with a warning symbol beside its name, or has a tick in
the VM in System column, select the Clone check box to clone the virtual machine.
NOTE
Cloning a virtual machine changes its name and MAC addresses and
clones all of its disks, removing all snapshots.
The CPU type of the virtual machine must be the same as the CPU type of the cluster into
which it is being imported. See Viewing CPU Type of Cluster and Configuring CPU Type of
Virtual Machine for details.
1. Enable public key authentication between the proxy host and the Xen host:
a. Log in to the proxy host and generate SSH keys for the vdsm user.
c. Log in to the Xen host to verify that the login works correctly.
94
CHAPTER 6. ADMINISTRATIVE TASKS
2. Attach an export domain. See Attaching an Existing Export Domain to a Data Center
in the Administration Guide for details.
3. On the proxy host, copy the virtual machine from the Xen host:
4. Convert the virtual machine to libvirt XML and move the file to your export domain:
5. In the Administration Portal, click Storage, select the export domain, and click VM
Import in the details pane to verify that the virtual machine is in your export
domain.
6. Import the virtual machine into the destination data domain. See Section 6.12.2,
“Importing a Virtual Machine into the Destination Data Center” for details.
If the import fails, refer to /var/log/vdsm/vdsm.log, and the relevant log file in
/var/log/vdsm/import/ on the proxy host for details.
WARNING
If you are importing a Windows virtual machine from a KVM host and you
are using VirtIO devices, install the VirtIO drivers before importing the
virtual machine. If the drivers are not installed, the virtual machine may
not boot after import.
The VirtIO drivers can be installed from the virtio-win.iso or the rhev-
tools-setup.iso. See Section 3.3.2, “Installing the Guest Agents and
Drivers on Windows” for details.
If you are not using VirtIO drivers, review the configuration of the virtual
machine after import, and before first boot to ensure that VirtIO devices
are not being used.
95
Virtual Machine Management Guide
IMPORTANT
An import operation can only include virtual machines that share the same
architecture. If any virtual machine to be imported has a different
architecture, a warning will display and you will be prompted to change your
selection to include only virtual machines with the same architecture.
1. Shut down the virtual machine. Starting the virtual machine through KVM during the
import process can result in data corruption.
2. Enable public key authentication between the proxy host and the KVM host:
a. Log in to the proxy host and generate SSH keys for the vdsm user.
b. Copy the vdsm user's public key to the KVM host. The proxy host'sknown_hosts
file will also be updated to include the host key of the KVM host.
c. Log in to the KVM host to verify that the login works correctly.
3. Log in to the Administration Portal. In the Virtual Machines tab, click Import to
open the Import Virtual Machine(s) window.
96
CHAPTER 6. ADMINISTRATIVE TASKS
6. Optionally, select a KVM provider External Provider from the drop-down list. The
URI will be pre-filled with the correct URI. See Adding a KVM Host as a Virtual
Machine Provider in the Administration Guide for more information.
qemu+ssh://[email protected]/system
12. Click Load to list the virtual machines on the KVM host that can be imported.
13. Select one or more virtual machines from the Virtual Machines on Source list,
and use the arrows to move them to the Virtual Machines to Import list.
97
Virtual Machine Management Guide
15. Select the Cluster in which the virtual machines will reside.
17. Optionally, select the Collapse Snapshots check box to remove snapshot restore
points and include templates in template-based virtual machines.
18. Optionally, select the Clone check box to change the virtual machine name and
MAC addresses, and clone all disks, removing all snapshots. If a virtual machine
appears with a warning symbol beside its name or has a tick in the VM in System
column, you must clone the virtual machine and change its name.
19. Click on each virtual machine to be imported and click on the Disks sub-tab. Use
the Allocation Policy and Storage Domain lists to select whether the disk used
by the virtual machine will be thin provisioned or preallocated, and select the
storage domain on which the disk will be stored. An icon is also displayed to indicate
which of the disks to be imported acts as the boot disk for that virtual machine. See
Virtual Disk Storage Allocation Policies in the Technical Reference for more
information.
NOTE
20. If you selected the Clone check box, change the name of the virtual machine in the
General sub-tab.
The CPU type of the virtual machine must be the same as the CPU type of the cluster into
which it is being imported. See Viewing CPU Type of Cluster and Configuring CPU Type of
Virtual Machine for details.
You can configure this image with the cloud-init tool, and use it to provision new virtual
machines. This eliminates the need to install and configure the operating system and
provides virtual machines that are ready for use.
1. Download the most recent KVM virtual machine image from the Download Red Hat
Enterprise Linux list, in the Product Software tab.
2. Upload the virtual machine image using the Manager or the REST API. See
Uploading a Disk Image to a Storage Domain in the Administration Guide.
98
CHAPTER 6. ADMINISTRATIVE TASKS
3. Create a new virtual machine and attach the uploaded disk image to it. See
Section 2.1, “Creating a Linux Virtual Machine”.
4. Optionally, use cloud-init to configure the virtual machine. See Section 7.8, “Using
Cloud-Init to Automate the Configuration of Virtual Machines” for details.
5. Optionally, create a template from the virtual machine. You can generate new
virtual machines from this template. See Chapter 7, Templates for information about
creating templates and generating virtual machines from templates.
The source and destination host should both be members of the same cluster,
ensuring CPU compatibility between them.
NOTE
The source and destination host must have access to the same virtual networks and
VLANs.
The source and destination host must have access to the data storage domain on
which the virtual machine resides.
There must be enough CPU capacity on the destination host to support the virtual
machine's requirements.
There must be enough RAM on the destination host that is not in use to support the
virtual machine's requirements.
The migrating virtual machine must not have the cache!=none custom property set.
In addition, for best performance, the storage and management networks should be split to
avoid network saturation. Virtual machine migration involves transferring large amounts of
data between hosts.
99
Virtual Machine Management Guide
Live migration is performed using the management network. Each live migration event is
limited to a maximum transfer speed of 30 MBps, and the number of concurrent migrations
supported is also limited by default. Despite these measures, concurrent migrations have
the potential to saturate the management network. It is recommended that separate logical
networks are created for storage, display, and virtual machine data to minimize the risk of
network saturation.
Virtual machines with vNICs that are directly connected to a virtual function (VF) of an SR-
IOV-enabled host NIC have additional requirements for successful migration:
The vNIC profile for the passthrough vNIC must have Passthrough and Migratable
selected. See Enabling Passthrough on a vNIC Profile in the Administration Guide for
more information.
The virtual machine must have a backup VirtIO vNIC, in addition to the
passthrough vNIC, to maintain the virtual machine's network connection during
migration.
Both vNICs must be added as slaves under an active-backup bond on the virtual
machine, with the passthrough vNIC as the primary interface. See Configure
Network Bonding in the Red Hat Enterprise Linux Networking Guide for more
information.
The Auto Converge migrations option allows you to set whether auto-convergence is
used during live migration of virtual machines. Large virtual machines with high workloads
can dirty memory more quickly than the transfer rate achieved during live migration, and
prevent the migration from converging. Auto-convergence capabilities in QEMU allow you
to force convergence of virtual machine migrations. QEMU automatically detects a lack of
convergence and triggers a throttle-down of the vCPUs on the virtual machine.
The Enable migration compression option allows you to set whether migration
compression is used during live migration of the virtual machine. This feature uses Xor
Binary Zero Run-Length-Encoding to reduce virtual machine downtime and total live
migration time for virtual machines running memory write-intensive workloads or for any
application with a sparse memory update pattern.
# engine-config -s DefaultAutoConvergence=True
100
CHAPTER 6. ADMINISTRATIVE TASKS
# engine-config -s DefaultMigrationCompression=True
a. Select a cluster.
b. Click Edit.
d. From the Auto Converge migrations list, select Inherit from global
setting, Auto Converge, or Don't Auto Converge.
e. From the Enable migration compression list, select Inherit from global
setting, Compress, or Don't Compress.
b. Click Edit.
d. From the Auto Converge migrations list, select Inherit from cluster
setting, Auto Converge, or Don't Auto Converge.
e. From the Enable migration compression list, select Inherit from cluster
setting, Compress, or Don't Compress.
Before migration
After migration
Before hibernation
After hibernation
101
Virtual Machine Management Guide
The executing user on Linux systems is ovirtagent. If the script needs root permissions,
the elevation must be executed by the creator of the hook script.
The Manager automatically initiates live migration of virtual machines in order to maintain
load balancing or power saving levels in line with scheduling policy. While no scheduling
policy is defined by default, it is recommended that you specify the scheduling policy which
best suits the needs of your environment. You can also disable automatic, or even manual,
live migration of specific virtual machines where required.
The ability to disable automatic migration and require a virtual machine to run on a
particular host is useful when using application high availability products, such as Red Hat
High Availability or Cluster Suite.
2. Click Edit.
102
CHAPTER 6. ADMINISTRATIVE TASKS
4. Use the Start Running On radio buttons to specify whether the virtual machine
should run on any host in the cluster, or a specific host or group of hosts.
WARNING
IMPORTANT
If the virtual machine has host devices directly attached to it, and a
different host is specified, the host devices from the previous host will
be automatically removed from the virtual machine.
103
Virtual Machine Management Guide
5. Select Allow manual migration only or Do not allow migration from the
Migration Options drop-down list.
6. Optionally, select the Use custom migration downtime check box and specify a
value in milliseconds.
7. Click OK.
NOTE
When you place a host into maintenance mode, the virtual machines running
on that host are automatically migrated to other hosts in the same cluster.
You do not need to manually migrate these virtual machines.
NOTE
1. Click the Virtual Machines tab and select a running virtual machine.
2. Click Migrate.
NOTE
4. Click OK.
During migration, progress is shown in the Migration progress bar. Once migration is
complete the Host column will update to display the host the virtual machine has been
migrated to.
104
CHAPTER 6. ADMINISTRATIVE TASKS
involved in a migration event are not included in the migration cycle until their migration
event has completed. When there is a migration request in the queue and available hosts
in the cluster to action it, a migration event is triggered in line with the load balancing
policy for the cluster.
You can influence the ordering of the migration queue by setting the priority of each virtual
machine; for example, setting mission critical virtual machines to migrate before others.
Migrations will be ordered by priority; virtual machines with the highest priority will be
migrated first.
2. Click Edit.
5. Click OK.
Example 6.1. Notification in the Events Tab of the Web Admin Portal
This log can be found on the Red Hat Virtualization Manager at /var/log/ovirt-
engine/engine.log:
105
Virtual Machine Management Guide
High availability is possible because the Red Hat Virtualization Manager constantly monitors
the hosts and storage, and automatically detects hardware failure. If host failure is
detected, any virtual machine configured to be highly available is automatically restarted
on another host in the cluster. With storage domains V4 or later, virtual machines have the
additional capability to acquire a lease on a special volume on the storage, enabling a
virtual machine to start on another host even if the original host loses power. The
functionality also prevents the virtual machine from being started on two different hosts,
which may lead to corruption of the virtual machine disks.
With high availability, interruption to service is minimal because virtual machines are
restarted within seconds with no user intervention required. High availability keeps your
resources balanced by restarting guests on a host with low current resource utilization, or
based on any workload balancing or power saving policies that you configure. This ensures
that there is sufficient capacity to restart virtual machines at all times.
High availability can ensure that virtual machines are restarted in the following scenarios:
A high availability virtual machine is automatically restarted, either on its original host or
another host in the cluster.
106
CHAPTER 6. ADMINISTRATIVE TASKS
Power management must be configured for the hosts running the highly available
virtual machines.
The host running the highly available virtual machine must be part of a cluster
which has other available hosts.
The source and destination host must have access to the data domain on which the
virtual machine resides.
The source and destination host must have access to the same virtual networks and
VLANs.
There must be enough CPUs on the destination host that are not in use to support
the virtual machine's requirements.
There must be enough RAM on the destination host that is not in use to support the
virtual machine's requirements.
2. Click Edit.
107
Virtual Machine Management Guide
4. Select the Highly Available check box to enable high availability for the virtual
machine.
5. Select the storage domain to hold the virtual machine lease, or select No VM Lease
to disable the functionality, from the Target Storage Domain for VM Lease drop-
down list. See Section 6.14.1, “What is High Availability?” for more information
about virtual machine leases.
IMPORTANT
6. Select Low, Medium, or High from the Priority drop-down list. When migration is
triggered, a queue is created in which the high priority virtual machines are
migrated first. If a cluster is running low on resources, only the high priority virtual
machines are migrated.
7. Click OK.
108
CHAPTER 6. ADMINISTRATIVE TASKS
2. Click Edit.
4. Select sap_agent from the drop-down list. Ensure the secondary drop-down menu is
set to True.
If previous properties have been set, select the plus sign to add a new property rule
and select sap_agent.
5. Click OK.
6.15.2. Configuring Red Hat Enterprise Linux 5.4 and later Virtual
Machines to use SPICE
SPICE is a remote display protocol designed for virtual environments, which enables you to
view a virtualized desktop or server. SPICE delivers a high quality user experience, keeps
CPU consumption low, and supports high quality video streaming.
Using SPICE on a Linux machine significantly improves the movement of the mouse cursor
on the console of the virtual machine. To use SPICE, the X-Windows system requires
109
Virtual Machine Management Guide
additional QXL drivers. The QXL drivers are provided with Red Hat Enterprise Linux 5.4 and
later. Earlier versions are not supported. Installing SPICE on a virtual machine running Red
Hat Enterprise Linux significantly improves the performance of the graphical user interface.
NOTE
Typically, this is most useful for virtual machines where the user requires the
use of the graphical user interface. System administrators who are creating
virtual servers may prefer not to configure SPICE if their use of the graphical
user interface is minimal.
You must manually install QXL drivers on virtual machines running Red Hat Enterprise Linux
5.4 or later. This is unnecessary for virtual machines running Red Hat Enterprise Linux 6 or
Red Hat Enterprise Linux 7 as the QXL drivers are installed by default.
You can configure QXL drivers using either a graphical interface or the command line.
Perform only one of the following procedures.
1. Click System.
2. Click Administration.
3. Click Display.
7. Restart X-Windows by logging out of the virtual machine and logging back in.
1. Back up /etc/X11/xorg.conf:
# cp /etc/X11/xorg.conf /etc/X11/xorg.conf.$$.backup
Section "Device"
Identifier "Videocard0"
110
CHAPTER 6. ADMINISTRATIVE TASKS
Driver "qxl"
Endsection
Edit the /etc/X11/xorg.conf file to enable SPICE for your virtual machine's tablet devices.
Procedure 6.41. Configuring a Virtual Machine's Tablet and Mouse to use SPICE
If there is no output from the command, do not continue configuring the tablet.
2. Back up /etc/X11/xorg.conf:
# cp /etc/X11/xorg.conf /etc/X11/xorg.conf.$$.backup
Section "ServerLayout"
Identifier "single head configuration"
Screen 0 "Screen0" 0 0
InputDevice "Keyboard0" "CoreKeyboard"
InputDevice "Tablet" "SendCoreEvents"
InputDevice "Mouse" "CorePointer"
EndSection
Section "InputDevice"
Identifier "Mouse"
Driver "void"
#Option "Device" "/dev/input/mice"
#Option "Emulate3Buttons" "yes"
EndSection
Section "InputDevice"
Identifier "Tablet"
Driver "evdev"
Option "Device" "/dev/input/event2"
Option "CorePointer" "true"
EndSection
4. Log out and log back into the virtual machine to restart X-Windows.
111
Virtual Machine Management Guide
KVM works around this issue by providing virtual machines with a paravirtualized clock. The
KVM pvclock provides a stable source of timing for KVM guests that support it.
Presently, only Red Hat Enterprise Linux 5.4 and later virtual machines fully support the
paravirtualized clock.
Virtual machines can have several problems caused by inaccurate clocks and counters:
Clocks can fall out of synchronization with the actual time which invalidates sessions
and affects networks.
These problems exist on other virtualization platforms and timing should always be tested.
IMPORTANT
The Network Time Protocol (NTP) daemon should be running on the host and
the virtual machines. Enable the ntpd service and add it to the default startup
sequence:
Using the ntpd service should minimize the affects of clock skew in all cases.
The NTP servers you are trying to use must be operational and accessible to
your hosts and virtual machines.
If any output is given your CPU has the constant_tsc bit. If no output is given follow the
instructions below.
IMPORTANT
112
CHAPTER 6. ADMINISTRATIVE TASKS
If the CPU lacks the constant_tsc bit, disable all power management features
(BZ#513138). Each system has several timers it uses to keep time. The TSC is not stable
on the host, which is sometimes caused by cpufreq changes, deep C state, or migration to
a host with a faster TSC. Deep C sleep states can stop the TSC. To prevent the kernel using
deep C states append "processor.max_cstate=1" to the kernel boot options in the
grub.conf file on the host:
Disable cpufreq (only necessary on hosts without the constant_tsc) by editing the
/etc/sysconfig/cpuspeed configuration file and change the MIN_SPEED and MAX_SPEED
variables to the highest frequency available. Valid limits can be found in the
/sys/devices/system/cpu/cpu*/cpufreq/scaling_available_frequencies files.
Using the engine-config tool to receive alerts when hosts drift out of sync.
You can use the engine-config tool to configure alerts when your hosts drift out of sync.
There are 2 relevant parameters for time drift on hosts: EnableHostTimeDrift and
HostTimeDriftInSec. EnableHostTimeDrift, with a default value of false, can be enabled
to receive alert notifications of host time drift. The HostTimeDriftInSec parameter is used
to set the maximum allowable drift before alerts start being sent.
Using the paravirtualized clock with Red Hat Enterprise Linux virtual machines
For certain Red Hat Enterprise Linux virtual machines, additional kernel parameters are
required. These parameters can be set by appending them to the end of the /kernel line in
the /boot/grub/grub.conf file of the virtual machine.
NOTE
The table below lists versions of Red Hat Enterprise Linux and the parameters required for
virtual machines on systems without a constant Time Stamp Counter.
113
Virtual Machine Management Guide
5.4 AMD64/Intel 64 with the paravirtualized Additional parameters are not required
clock
5.4 x86 with the paravirtualized clock Additional parameters are not required
114
CHAPTER 7. TEMPLATES
CHAPTER 7. TEMPLATES
A template is a copy of a virtual machine that you can use to simplify the subsequent,
repeated creation of similar virtual machines. Templates capture the configuration of
software, configuration of hardware, and the software installed on the virtual machine on
which the template is based. The virtual machine on which a template is based is known as
the source virtual machine.
When you create a template based on a virtual machine, a read-only copy of the virtual
machine's disk is created. This read-only disk becomes the base disk image of the new
template, and of any virtual machines created based on the template. As such, the
template cannot be deleted while any virtual machines created based on the template exist
in the environment.
Virtual machines created based on a template use the same NIC type and driver as the
original virtual machine, but are assigned separate, unique MAC addresses.
You can create a virtual machine directly from the Templates tab, as well as from the
Virtual Machines tab. In the Templates tab, right-click the required template and select
New VM. For more information on selecting the settings and controls for the new virtual
machine see Section A.1.1, “Virtual Machine General Settings Explained”.
The Sysprep file can be edited to affect various aspects of the Windows virtual machines
created from the template that the Sysprep file is attached to. These include the
provisioning of Windows, setting up the required domain membership, configuring the
hostname, and setting the security policy.
115
Virtual Machine Management Guide
Replacement strings can be used to substitute values provided in the default files in the
/usr/share/ovirt-engine/conf/sysprep/ directory. For example, "<Domain><!
[CDATA[$JoinDomain$]]></Domain>" can be used to indicate the domain to join.
IMPORTANT
Before starting Sysprep, verify that the following settings are configured:
If not, click Edit the Virtual Machines tab and enter the required information
in the Operating System and Cluster fields.
The correct product key has been defined in an override file on the Manager.
If not, copy the default values for your Windows operating system from /etc/ovirt-
engine/osinfo.conf.d/00-defaults.properties into the override file, and input
your values in the productKey.value and sysprepPath.value fields.
Seal a Windows 7, Windows 2008, or Windows 2012 template before using the template to
deploy virtual machines.
116
CHAPTER 7. TEMPLATES
Select the Generalize check box if you need to change the computer's system
identification number (SID).
3. Click OK to complete the sealing process; the virtual machine shuts down
automatically upon completion.
The Windows 7, Windows 2008, or Windows 2012 template is sealed and ready for
deploying virtual machines.
When creating a template, you can choose the format of the disk: RAW or QCOW2. QCOW2
always implies that a disk is thin provisioned. RAW on file storage implies thin provisioned,
while RAW on block storage implies preallocated virtual disks.
1. Click the Virtual Machines tab and select the source virtual machine.
2. Ensure the virtual machine is powered down and has a status of Down.
3. Click Make Template. For more details on all fields in theNew Template window, see
Section A.4, “Explanation of Settings in the New Template Window”.
5. Select the cluster with which to associate the template from the Cluster drop-down
list. By default, this is the same as that of the source virtual machine.
6. Optionally, select a CPU profile for the template from the CPU Profile drop-down
list.
7. Optionally, select the Create as a Template Sub Version check box, select a Root
Template, and enter a Sub Version Name to create the new template as a sub
template of an existing template.
8. In the Disks Allocation section, enter an alias for the disk in theAlias text field.
Select the disk format in the Format drop-down, the storage domain on which to
store the disk from the Target drop-down, and the disk profile in theDisk Profile
drop-down. By default, these are the same as those of the source virtual machine.
9. Select the Allow all users to access this Template check box to make the
template public.
117
Virtual Machine Management Guide
10. Select the Copy VM permissions check box to copy the permissions of the source
virtual machine to the template.
11. Select the Seal Template check box (Linux only) to seal the template.
NOTE
The virtual machine displays a status of Image Locked while the template is being created.
The process of creating a template may take up to an hour depending on the size of the
virtual disk and the capabilities of your storage hardware. When complete, the template is
added to the Templates tab. You can now create new virtual machines based on the
template.
NOTE
When a template is made, the virtual machine is copied so that both the
existing virtual machine and its template are usable after template creation.
2. Click Edit.
3. Change the necessary properties. Click Show Advanced Options and edit the
template's settings as required. The settings that appear in the Edit Template
window are identical to those in the Edit Virtual Machine window, but with the
relevant fields only. See Section A.1, “Explanation of Settings in the New Virtual
Machine and Edit Virtual Machine Windows” for details.
4. Click OK.
118
CHAPTER 7. TEMPLATES
2. Click Remove.
3. Click OK.
NOTE
Export templates into the export domain to move them to another data domain, either in
the same Red Hat Virtualization environment, or another one. This procedure requires
access to the Administration Portal.
2. Click Export.
3. Select the Force Override check box to replace any earlier version of the template
on the export domain.
4. Click OK to begin exporting the template; this may take up to an hour, depending on
the virtual disk size and your storage hardware.
Repeat these steps until the export domain contains all the templates to migrate before
you start the import process.
Click the Storage tab, select the export domain, and click the Template Import tab in the
details pane to view all exported templates in the export domain.
1. Click the Disks tab and select the template disk(s) to copy.
119
Virtual Machine Management Guide
2. Click Copy.
4. Click OK.
A copy of the template's virtual hard disk has been created, either on the same, or a
different, storage domain. If you were copying a template disk in preparation for moving a
virtual hard disk, you can now move the virtual hard disk.
NOTE
Import templates from a newly attached export domain. This procedure requires access to
the Administration Portal.
1. Click the Storage tab and select the newly attached export domain.
2. Click the Template Import tab in the details pane and select a template.
3. Click Import.
5. Use the drop-down lists to select the Destination Cluster and Storage domain.
Alter the Suffix if applicable.
The template is imported into the destination data center. This can take up to an hour,
depending on your storage hardware. You can view the import progress in the Events tab.
Once the importing process is complete, the templates will be visible in the Templates
resource tab. The templates can create new virtual machines, or run existing imported
virtual machines based on that template.
120
CHAPTER 7. TEMPLATES
Virtual disks managed by an OpenStack Image Service can be imported into the Red Hat
Virtualization Manager if that OpenStack Image Service has been added to the Manager as
an external provider. This procedure requires access to the Administration Portal.
1. Click the Storage tab and select the OpenStack Image Service domain.
2. Click the Images tab in the details pane and select the image to import.
3. Click Import.
NOTE
If you are importing an image from a Glance storage domain, you have
the option of specifying the template name.
4. Select the Data Center into which the virtual disk will be imported.
5. Select the storage domain in which the virtual disk will be stored from the Domain
Name drop-down list.
8. Select the Cluster in which the virtual disk will be made available as a template.
9. Click OK.
The image is imported as a template and is displayed in the Templates tab. You can now
create virtual machines based on the template.
121
Virtual Machine Management Guide
NOTE
122
CHAPTER 7. TEMPLATES
1. Use the resource tabs, tree mode, or the search function to find and select the
resource in the results list.
2. Click the Permissions tab in the details pane to list the assigned users, the user's
role, and the inherited permissions for the selected resource.
3. Click Add.
4. Enter the name or user name of an existing user into the Search text box and click
Go. Select a user from the resulting list of possible matches.
6. Click OK.
You have assigned a role to a user; the user now has the inherited permissions of that role
enabled for that resource.
1. Use the resource tabs, tree mode, or the search function to find and select the
resource in the results list.
2. Click the Permissions tab in the details pane to list the assigned users, the user's
role, and the inherited permissions for the selected resource.
123
Virtual Machine Management Guide
5. Click OK.
You have removed the user's role, and the associated permissions, from the resource.
To use this tool, the cloud-init package must first be installed on the virtual machine. Once
installed, the Cloud-Init service starts during the boot process to search for instructions on
what to configure. You can then use options in the Run Once window to provide these
instructions one time only, or options in the New Virtual Machine, Edit Virtual Machine
and Edit Template windows to provide these instructions every time the virtual machine
starts.
You can use the Cloud-Init options in the Initial Run section of the Run Once
window to initialize a virtual machine that was created based on a template. This
allows you to customize the virtual machine the first time that virtual machine is
started.
You can use the Use Cloud-Init/Sysprep options in the Initial Run tab of the
New Template and Edit Template windows to specify options for customizing
virtual machines created based on that template.
You can use the Use Cloud-Init/Sysprep options in the Initial Run tab of the
New Pool window to specify options for customizing virtual machines taken from
that virtual machine pool. This allows you to specify a set of standard settings that
will be applied every time a virtual machine is taken from that virtual machine pool.
You can inherit or override the options specified for the template on which the
virtual machine is based, or specify options for the virtual machine pool itself.
124
CHAPTER 7. TEMPLATES
installed, you can create a template based on this virtual machine. Virtual machines
created based on this template can leverage Cloud-Init functions, such as configuring the
host name, time zone, root password, authorized keys, network interfaces, DNS service, etc
on boot.
NOTE
While the following procedure outlines how to use Cloud-Init when preparing a
template, the same settings are also available in the New Virtual Machine,
Edit Template, and Run Once windows.
2. Click Edit.
3. Click the Initial Run tab and select the Use Cloud-Init/Sysprep check box.
5. Select the Configure Time Zone check box and select a time zone from theTime
Zone drop-down list.
125
Virtual Machine Management Guide
6. Expand the Authentication section and select the Use already configured
password check box to use the existing credentials, or clear that check box and
enter a root password in the Password and Verify Password text fields to specify a
new root password.
7. Enter any SSH keys to be added to the authorized hosts file on the virtual machine
in the SSH Authorized Keys text area.
8. Select the Regenerate SSH Keys check box to regenerate SSH keys for the virtual
machine.
9. Expand the Networks section and enter any DNS servers in the DNS Servers text
field.
10. Enter any DNS search domains in the DNS Search Domains text field.
11. Select the Network check box and use the+ and - buttons to add or remove
network interfaces to or from the virtual machine.
IMPORTANT
You must specify the correct network interface name and number (for
example, eth0, eno3, enp0s). Otherwise, the virtual machine's interface
connection will be up, but it will not have the cloud-init network
configuration.
12. Expand the Custom Script section and enter any custom scripts in theCustom
Script text area.
You can now provision new virtual machines using this template.
This procedure starts a virtual machine with a set of Cloud-Init settings. If the relevant
settings are included in the template the virtual machine is based on, review the settings,
make changes where appropriate, and click OK to start the virtual machine.
126
CHAPTER 7. TEMPLATES
3. Expand the Initial Run section and select the Cloud-Init check box.
5. Select the Configure Time Zone check box and select a time zone from theTime
Zone drop-down menu.
6. Select the Use already configured password check box to use the existing
credentials, or clear that check box and enter a root password in the Password and
Verify Password text fields to specify a new root password.
7. Enter any SSH keys to be added to the authorized hosts file on the virtual machine
in the SSH Authorized Keys text area.
8. Select the Regenerate SSH Keys check box to regenerate SSH keys for the virtual
machine.
10. Enter any DNS search domains in the DNS Search Domains text field.
11. Select the Network check box and use the+ and - buttons to add or remove
network interfaces to or from the virtual machine.
IMPORTANT
You must specify the correct network interface name and number (for
example, eth0, eno3, enp0s). Otherwise, the virtual machine's interface
connection will be up, but it will not have the cloud-init network
configuration.
12. Enter a custom script in the Custom Script text area. Make sure the values
specified in the script are appropriate. Otherwise, the action will fail.
NOTE
Sysprep generates a complete unattended installation answer file. Default values for
several Windows operating systems are available in the /usr/share/ovirt-
engine/conf/sysprep/ directory. You can also create a customSysprep file and reference
127
Virtual Machine Management Guide
Copy the default values for your Windows operating system from /etc/ovirt-
engine/osinfo.conf.d/00-defaults.properties into the override file, and input your
values in the productKey.value and sysprepPath.value fields.
Replacement strings can be used to substitute values provided in the default files in the
/usr/share/ovirt-engine/conf/sysprep/ directory. For example, "<Domain><!
[CDATA[$JoinDomain$]]></Domain>" can be used to indicate the domain to join.
IMPORTANT
Prerequisites
If not, click Edit the Virtual Machines tab and enter the required information
in the Operating System and Cluster fields.
The correct product key has been defined in an override file on the Manager.
128
CHAPTER 7. TEMPLATES
1. Build the Windows virtual machine with the required patches and layered software.
2. Seal the Windows virtual machine. See Section 7.1, “Sealing Virtual Machines in
Preparation for Deployment as Templates”
3. Create a template based on the Windows virtual machine. See Section 7.2,
“Creating a Template”
4. Update the Sysprep file with a text editor if additional changes are required.
You can now provision new virtual machines using this template.
This procedure starts a virtual machine with a set of Sysprep settings. If the relevant
settings are included in the template the virtual machine is based on, review the settings
and make changes where required.
2. Click the Virtual Machines tab and select the virtual machine.
4. Expand the Boot Options section, select the Attach Floppy check box, and select
the [sysprep] option.
5. Select the Attach CD check box and select the required Windows ISO from the
drop-down list.
7. Configure any further Run Once options as required. See Section A.5, “Explanation of
Settings in the Run Once Window” for more details.
8. Click OK.
129
Virtual Machine Management Guide
NOTE
When creating a virtual machine from a template, you can choose the format of the disk:
either RAW or QCOW2. If the Storage Allocation is Thin, the format of the disk will be
marked as QCOW2 and you will not be able to change it. If the Storage Allocation is
Clone, you can select either QCOW2 or RAW.
5. Enter a Name, Description, and any Comments, and accept the default values
inherited from the template in the rest of the fields. You can change them if needed.
8. Use the Target drop-down list to select the storage domain on which the virtual
machine's virtual disk will be stored.
9. Click OK.
NOTE
If you clone a virtual machine from a template, the name of the template on
which that virtual machine was based is displayed in the General tab of the
Edit Virtual Machine window for that virtual machine. If you change the
name of that template, the name of the template in the General tab will also
be updated. However, if you delete the template from the Manager, the
original name of that template will be displayed instead.
130
CHAPTER 7. TEMPLATES
When creating a virtual machine from a template, you can choose the format of the disk:
either RAW or QCOW2. If the Storage Allocation is Thin, the format of the disk will be
marked as QCOW2 and you will not be able to change it. If the Storage Allocation is
Clone, you can select either QCOW2 or RAW.
5. Enter a Name, Description and any Comments. You can accept the default values
inherited from the template in the rest of the fields, or change them if required.
8. Select the disk format from the Format drop-down list. This affects the speed of the
clone operation and the amount of disk space the new virtual machine initially
requires.
Selecting QCOW2 results in a faster clone operation and provides optimized usage
of storage capacity. Disk space is allocated only as it is required. This is the
default selection.
Selecting Raw results in a slower clone operation and provides optimized virtual
machine read and write operations. All disk space requested in the template is
allocated at the time of the clone operation.
9. Use the Target drop-down menu to select the storage domain on which the virtual
machine's virtual disk will be stored.
NOTE
Cloning a virtual machine may take some time. A new copy of the template's
disk must be created. During this time, the virtual machine's status is first
Image Locked, then Down.
The virtual machine is created and displayed in the Virtual Machines tab. You can now
assign users to it, and can begin using it when the clone operation is complete.
131
Virtual Machine Management Guide
132
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
133
Virtual Machine Management Guide
Start in Pause Mode Select this check box to always start the virtual
machine in pause mode. This option is suitable
for virtual machines which require a long time
to establish a SPICE connection; for example,
virtual machines in remote locations.
134
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Cores per Virtual Socket The number of cores assigned to each virtual
socket.
Custom Emulated Machine This option allows you to specify the machine
type. If changed, the virtual machine will only
run on hosts that support this machine type.
Defaults to the cluster's default machine type.
Custom CPU Type This option allows you to specify a CPU type. If
changed, the virtual machine will only run on
hosts that support this CPU type. Defaults to
the cluster's default CPU type.
135
Virtual Machine Management Guide
Hardware Clock Time Offset This option sets the time zone offset of the
guest hardware clock. For Windows, this
should correspond to the time zone set in the
guest. Most default Linux installations expect
the hardware clock to be GMT+00:00.
Provide custom serial number policy This check box allows you to specify a serial
number for the virtual machine. Select either:
Use Cloud- Linux, Windows This check box toggles whether Cloud-Init or
Init/Sysprep Sysprep will be used to initialize the virtual
machine.
136
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Configure Time Zone Linux, Windows The time zone for the virtual machine. Select
this check box and select a time zone from the
Time Zone list.
137
Virtual Machine Management Guide
Custom Locale Windows Custom locale options for the virtual machine.
Locales must be in a format such as en-US.
Click the disclosure arrow to display the
settings for this option.
138
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Custom Script Linux Custom scripts that will be run on the virtual
machine when it starts. The scripts entered in
this field are custom YAML sections that are
added to those produced by the Manager, and
allow you to automate tasks such as creating
users and files, configuring yum repositories
and running commands. For more information
on the format of scripts that can be entered in
this field, see the Custom Script
documentation.
139
Virtual Machine Management Guide
IMPORTANT
VNC Keyboard Layout Defines the keyboard layout for the virtual
machine. This option is only available when
using the VNC protocol.
140
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
141
Virtual Machine Management Guide
Disable strict user checking Click the Advanced Parameters arrow and
select the check box to use this option. With
this option selected, the virtual machine does
not need to be rebooted when a different user
connects to it.
Enable SPICE file transfer Defines whether a user is able to drag and
drop files from an external host into the virtual
machine's SPICE console. This option is only
available for virtual machines using the SPICE
protocol. This check box is selected by default.
Enable SPICE clipboard copy and Defines whether a user is able to copy and
paste paste content from an external host into the
virtual machine's SPICE console. This option is
only available for virtual machines using the
SPICE protocol. This check box is selected by
default.
142
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Enable VirtIO serial console The VirtIO serial console is emulated through
VirtIO channels, using SSH and key pairs, and
allows you to access a virtual machine's serial
console directly from a client machine's
command line, instead of opening a console
from the Administration Portal or the User
Portal. The serial console requires direct
access to the Manager, since the Manager acts
as a proxy for the connection, provides
information about virtual machine placement,
and stores the authentication keys. Select the
check box to enable the VirtIO console on the
virtual machine.
Any Host in
Cluster - The virtual
machine can start and
run on any available
host in the cluster.
Specific Host(s) -
The virtual machine
will start running on a
particular host in the
cluster. However, the
Manager or an
administrator can
migrate the virtual
machine to a different
host in the cluster
depending on the
migration and high-
availability settings of
the virtual machine.
Select the specific
host or group of hosts
from the list of
available hosts.
143
Virtual Machine Management Guide
Allow manual
migration only -
The virtual machine
can only be migrated
from one host to
another manually by
an administrator.
Do not allow
migration - The
virtual machine
cannot be migrated,
either automatically or
manually.
144
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Legacy - Legacy
behavior of 3.6
version. Overrides in
vdsm.conf are still
applied. The guest
agent hook
mechanism is
disabled.
Minimal downtime -
Allows the virtual
machine to migrate in
typical situations.
Virtual machines
should not experience
any significant
downtime. The
migration will be
aborted if virtual
machine migration
does not converge
after a long time
(dependent on QEMU
iterations, with a
maximum of 500
milliseconds). The
guest agent hook
mechanism is
enabled.
Suspend workload
if needed - Allows
the virtual machine to
migrate in most
situations, including
when the virtual
machine is running a
heavy workload.
Virtual machines may
experience a more
significant downtime.
The migration may
still be aborted for
extreme workloads.
The guest agent hook
mechanism is
enabled.
145
Virtual Machine Management Guide
146
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Select Auto
Converge to override
the cluster setting or
global setting and
allow auto-
convergence for the
virtual machine.
147
Virtual Machine Management Guide
Select Compress to
override the cluster
setting or global
setting and allow
compression for the
virtual machine.
Select Don't
compress to override
the cluster setting or
global setting and
prevent compression
for the virtual
machine.
148
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Strict : Memory
allocation will fail if
the memory cannot
be allocated on the
target node.
Preferred: Memory
is allocated from a
single preferred node.
If sufficient memory is
not available, memory
can be allocated from
other nodes.
Interleave: Memory
is allocated across
nodes in a round-robin
algorithm.
149
Virtual Machine Management Guide
Target Storage Domain for VM Lease Select the storage domain to hold a virtual
machine lease, or select No VM Lease to
disable the functionality. When a storage
domain is selected, it will hold a virtual
machine lease on a special volume that allows
the virtual machine to be started on another
host if the original host loses power or
becomes unresponsive.
Priority for Run/Migration queue Sets the priority level for the virtual machine
to be migrated or restarted on another host.
150
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
151
Virtual Machine Management Guide
Low - 512
Medium - 1024
High - 2048
Custom - A custom
level of CPU shares
defined by the user.
152
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Migration
Options: Do not
allow migration
Pass-Through Host
CPU
153
Virtual Machine Management Guide
154
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
155
Virtual Machine Management Guide
The following table details the options available on the Boot Options tab of the New
Virtual Machine and Edit Virtual Machine windows
Hard Disk
CD-ROM
Network (PXE)
Enable menu to select boot device Enables a menu to select the boot device.
After the virtual machine starts and connects
to the console, but before the virtual machine
starts booting, a menu displays that allows you
to select the boot device. This option should
be enabled before the initial boot to allow you
to select the required installation media.
156
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
157
Virtual Machine Management Guide
WARNING
158
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Maximum size: 24 KB
159
Virtual Machine Management Guide
160
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
161
Virtual Machine Management Guide
Data Center The data center in which the virtual disk will
be available.
162
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
163
Virtual Machine Management Guide
The Direct LUN settings can be displayed in either Targets > LUNs or LUNs > Targets.
Targets > LUNs sorts available LUNs according to the host on which they are discovered,
whereas LUNs > Targets displays a single list of LUNs.
Table A.15. New Virtual Disk and Edit Virtual Disk Settings: Direct LUN
164
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Data Center The data center in which the virtual disk will
be available.
165
Virtual Machine Management Guide
Allow Privileged SCSI I/O Available when the Enable SCSI Pass-
Through check box is selected. Selecting this
check box enables unfiltered SCSI Generic I/O
(SG_IO) access, allowing privileged SG_IO
commands on the disk. This is required for
persistent reservations.
Fill in the fields in the Discover Targets section and click Discover to discover the target
server. You can then click the Login All button to list the available LUNs on the target
server and, using the radio buttons next to each LUN, select the LUN to add.
Using LUNs directly as virtual machine hard disk images removes a layer of abstraction
between your virtual machines and their data.
The following considerations must be made when using a direct LUN as a virtual machine
hard disk image:
166
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Live storage migration of direct LUN hard disk images is not supported.
The Cinder settings form will be disabled if there are no available OpenStack Volume
storage domains on which you have permissions to create a disk in the relevant Data
Center. Cinder disks require access to an instance of OpenStack Volume that has been
added to the Red Hat Virtualization environment using the External Providers window;
see Adding an OpenStack Volume (Cinder) Instance for Storage Managementfor more
information.
Table A.16. New Virtual Disk and Edit Virtual Disk Settings: Cinder
Data Center The data center in which the virtual disk will
be available.
Volume Type The volume type of the virtual disk. The drop-
down list shows all available volume types.
The volume type will be managed and
configured on OpenStack Cinder.
167
Virtual Machine Management Guide
IMPORTANT
Mounting a journaled file system requires read-write access. Using the Read
Only option is not appropriate for virtual disks that contain such file systems
(e.g. EXT3, EXT4, or XFS).
Field Description/Action
168
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Field Description/Action
169
Virtual Machine Management Guide
Field Description/Action
170
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
The Boot Options section defines the virtual machine's boot sequence, running options,
and source images for installing the operating system and required drivers.
Enable menu to select boot device Enables a menu to select the boot device.
After the virtual machine starts and connects
to the console, but before the virtual machine
starts booting, a menu displays that allows you
to select the boot device. This option should
be enabled before the initial boot to allow you
to select the required installation media.
Start in Pause Mode Starts and then pauses the virtual machine to
enable connection to the console. Suitable for
virtual machines in remote locations.
The Linux Boot Options section contains fields to boot a Linux kernel directly instead of
through the BIOS bootloader.
171
Virtual Machine Management Guide
The Initial Run section is used to specify whether to use Cloud-Init or Sysprep to initialize
the virtual machine. For Linux-based virtual machines, you must select the Use Cloud-Init
check box in the Initial Run tab to view the available options. For Windows-based virtual
machines, you must attach the [sysprep] floppy by selecting the Attach Floppy check
box in the Boot Options tab and selecting the floppy from the list.
The options that are available in the Initial Run section differ depending on the operating
system that the virtual machine is based on.
Configure Time Zone The time zone for the virtual machine. Select
this check box and select a time zone from the
Time Zone list.
Authentication > User Name Creates a new user account on the virtual
machine. If this field is not filled in, the default
user is root.
Authentication > Use already This check box is automatically selected after
configured password you specify an initial root password. You must
clear this check box to enable the Password
and Verify Password fields and specify a
new password.
Authentication > Password The root password for the virtual machine.
Enter the password in this text field and the
Verify Password text field to verify the
password.
172
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
Authentication > SSH Authorized SSH keys to be added to the authorized keys
Keys file of the virtual machine.
Authentication > Regenerate SSH Regenerates SSH keys for the virtual machine.
Keys
Networks > DNS Servers The DNS servers to be used by the virtual
machine.
Networks > DNS Search Domains The DNS search domains to be used by the
virtual machine.
173
Virtual Machine Management Guide
Configure Time Zone The time zone for the virtual machine. Select
this check box and select a time zone from the
Time Zone list.
Admin Password > Use already This check box is automatically selected after
configured password you specify an initial administrative user
password. You must clear this check box to
enable the Admin Password and Verify
Admin Password fields and specify a new
password.
Admin Password > Admin Password The administrative user password for the
virtual machine. Enter the password in this
text field and the Verify Admin Password
text field to verify the password.
Custom Locale > Input Locale The locale for user input.
Custom Locale > UI Language The language used for user interface elements
such as buttons and menus.
Custom Locale > System Locale The locale for the overall system.
174
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
The System section enables you to define the supported machine type or CPU type.
Custom Emulated Machine This option allows you to specify the machine
type. If changed, the virtual machine will only
run on hosts that support this machine type.
Defaults to the cluster's default machine type.
Custom CPU Type This option allows you to specify a CPU type. If
changed, the virtual machine will only run on
hosts that support this CPU type. Defaults to
the cluster's default CPU type.
175
Virtual Machine Management Guide
Enable SPICE file transfer Determines whether you can drag and drop
files from an external host into the virtual
machine's SPICE console. This option is only
available for virtual machines using the SPICE
protocol. This check box is selected by default.
Enable SPICE clipboard copy and Defines whether you can copy and paste
paste content from an external host into the virtual
machine's SPICE console. This option is only
available for virtual machines using the SPICE
protocol. This check box is selected by default.
The Custom Properties section contains additional VDSM options for running virtual
machines.
176
APPENDIX A. REFERENCE: SETTINGS IN ADMINISTRATION PORTAL AND USER PORTAL WINDOWS
177
Virtual Machine Management Guide
Only operations marked with * are performed during the template sealing process.
# virt-sysprep --list-operations
abrt-data * Remove the crash data generated by ABRT
bash-history * Remove the bash history in the guest
blkid-tab * Remove blkid tab in the guest
ca-certificates Remove CA certificates in the guest
crash-data * Remove the crash data generated by kexec-tools
cron-spool * Remove user at-jobs and cron-jobs
customize * Customize the guest
dhcp-client-state * Remove DHCP client leases
dhcp-server-state * Remove DHCP server leases
dovecot-data * Remove Dovecot (mail server) data
firewall-rules Remove the firewall rules
flag-reconfiguration Flag the system for reconfiguration
fs-uuids Change filesystem UUIDs
kerberos-data Remove Kerberos data in the guest
logfiles * Remove many log files from the guest
lvm-uuids * Change LVM2 PV and VG UUIDs
machine-id * Remove the local machine ID
mail-spool * Remove email from the local mail spool directory
net-hostname * Remove HOSTNAME in network interface configuration
net-hwaddr * Remove HWADDR (hard-coded MAC address) configuration
pacct-log * Remove the process accounting log files
package-manager-cache * Remove package manager cache
pam-data * Remove the PAM data in the guest
puppet-data-log * Remove the data and log files of puppet
rh-subscription-manager * Remove the RH subscription manager files
rhn-systemid * Remove the RHN system ID
rpm-db * Remove host-specific RPM database files
samba-db-log * Remove the database and log files of Samba
script * Run arbitrary scripts against the guest
smolt-uuid * Remove the Smolt hardware UUID
ssh-hostkeys * Remove the SSH host keys in the guest
ssh-userdir * Remove ".ssh" directories in the guest
sssd-db-log * Remove the database and log files of sssd
tmp-files * Remove temporary files
udev-persistent-net * Remove udev persistent net rules
user-account Remove the user accounts in the guest
utmp * Remove the utmp file
yum-uuid * Remove the yum UUID
178