Grid Vgpu User Guide
Grid Vgpu User Guide
User Guide
TABLE OF CONTENTS
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | ii
Chapter 3. Using vGPU on Linux............................................................................ 27
3.1. Installing vGPU drivers on Linux......................................................................27
3.1.1. Prerequisites for installing the NVIDIA Linux driver.......................................... 27
3.1.2. Running the driver installer...................................................................... 28
3.2. Licensing GRID vGPU on Linux........................................................................ 30
Chapter 4. Performance monitoring........................................................................ 32
4.1. Using nvidia-smi to monitor performance...........................................................32
4.2. Using Citrix XenCenter to monitor performance................................................... 33
Chapter 5. XenServer vGPU Management................................................................. 35
5.1. Management objects for GPUs........................................................................ 35
5.1.1. pgpu - physical GPU............................................................................... 35
5.1.1.1. Listing the pgpu objects present on a platform......................................... 35
5.1.1.2. Viewing detailed information about a pgpu object..................................... 35
5.1.1.3. Viewing physical GPUs in XenCenter...................................................... 36
5.1.2. vgpu-type - virtual GPU type.................................................................... 37
5.1.2.1. Listing the vgpu-type objects present on a platform................................... 37
5.1.2.2. Viewing detailed information about a vgpu-type object............................... 38
5.1.3. gpu-group - collection of physical GPUs....................................................... 38
5.1.3.1. Listing the gpu-group objects present on a platform...................................38
5.1.3.2. Viewing detailed information about a gpu-group object............................... 38
5.1.4. vgpu - virtual GPU................................................................................. 39
5.2. Creating a vGPU using xe..............................................................................39
5.3. Controlling vGPU allocation........................................................................... 39
5.3.1. GPU allocation policy............................................................................. 40
5.3.1.1. Controlling GPU allocation policy by using xe........................................... 40
5.3.1.2. Controlling GPU allocation policy by using XenCenter................................. 40
5.3.2. Determining the physical GPU that a virtual GPU is resident on...........................41
5.3.3. Controlling the vGPU types enabled on specific physical GPUs............................ 42
5.3.3.1. Controlling vGPU types enabled on specific physical GPUs by using XenCenter....42
5.3.3.2. Controlling vGPU types enabled on specific physical GPUs by using xe.............. 43
5.3.4. Creating vGPUs on specific physical GPUs..................................................... 44
5.4. Cloning vGPU-enabled VMs............................................................................ 45
5.4.1. Cloning a vGPU-enabled VM by using xe....................................................... 46
5.4.2. Cloning a vGPU-enabled VM by using XenCenter............................................. 46
5.5. Using GPU pass-through................................................................................ 46
5.5.1. Configuring a VM for GPU pass-through by using XenCenter................................ 47
5.5.2. Configuring a VM for GPU pass-through by using xe......................................... 47
Chapter 6. XenServer Performance Tuning............................................................... 49
6.1. XenServer tools.......................................................................................... 49
6.2. Using remote graphics..................................................................................49
6.2.1. Disabling console VGA.............................................................................50
6.3. Allocation strategies.................................................................................... 50
6.3.1. NUMA considerations.............................................................................. 50
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | iii
6.3.2. Maximizing performance.......................................................................... 51
Chapter 7. Troubleshooting...................................................................................53
7.1. Known issues............................................................................................. 53
7.2. Troubleshooting steps...................................................................................53
7.2.1. Verifying the NVIDIA kernel driver is loaded.................................................. 53
7.2.2. Verifying that nvidia-smi works..................................................................54
7.2.3. Examining NVIDIA kernel driver output........................................................ 54
7.2.4. Examining GRID Virtual GPU Manager messages.............................................. 54
7.2.4.1. Examining Citrix XenServer vGPU Manager messages...................................54
7.2.4.2. Examining VMware vSphere vGPU Manager messages.................................. 55
7.3. Capturing configuration data for filing a bug report.............................................. 55
7.3.1. Capturing configuration data by running nvidia-bug-report.sh............................. 56
7.3.2. Capturing configuration data by creating a XenServer status report...................... 56
Appendix A. XenServer Basics............................................................................... 58
A.1. Opening a dom0 shell.................................................................................. 58
A.1.1. Accessing the dom0 shell through XenCenter.................................................58
A.1.2. Accessing the dom0 shell through an SSH client............................................. 59
A.2. Copying files to dom0.................................................................................. 59
A.2.1. Copying files by using an SCP client........................................................... 59
A.2.2. Copying files by using a CIFS-mounted file system...........................................60
A.3. Determining a VM’s UUID.............................................................................. 60
A.3.1. Determining a VM’s UUID by using xe vm-list................................................. 61
A.3.2. Determining a VM’s UUID by using XenCenter................................................ 61
A.4. Using more than two vCPUs with Windows client VMs............................................62
A.5. Pinning VMs to a specific CPU socket and cores................................................... 62
A.6. Changing dom0 vCPU Default configuration........................................................ 63
A.6.1. Changing the number of dom0 vCPUs.......................................................... 64
A.6.2. Pinning dom0 vCPUs............................................................................... 64
A.7. How GPU locality is determined..................................................................... 64
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | iv
LIST OF FIGURES
Figure 8 Verifying NVIDIA driver operation using NVIDIA Control Panel ............................... 17
Figure 11 Verifying NVIDIA driver operation using NVIDIA Control Panel .............................. 24
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | v
Figure 25 Using XenCenter to determine a VM's UUID ................................................... 62
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | vi
LIST OF TABLES
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | vii
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | viii
Chapter 1.
INTRODUCTION TO NVIDIA GRID VIRTUAL
GPU
NVIDIA GRID™ vGPU™ enables multiple virtual machines (VMs) to have simultaneous,
direct access to a single physical GPU, using the same NVIDIA graphics drivers that are
deployed on non-virtualized Operating Systems. By doing this, GRID vGPU provides
VMs with unparalleled graphics performance and application compatibility, together
with the cost-effectiveness and scalability brought about by sharing a GPU among
multiple workloads.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 1
Introduction to NVIDIA GRID Virtual GPU
direct access to the GPU for performance-critical fast paths, and a paravirtualized
interface to the GRID Virtual GPU Manager is used for non-performant management
operations.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 2
Introduction to NVIDIA GRID Virtual GPU
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 3
Introduction to NVIDIA GRID Virtual GPU
Maximum
Resolution
GRID Frame Virtual per Maximum Maximum
Physical Virtual Intended Buffer Display Display vGPUs vGPUs
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
4 K180Q Power User 4096 4 2560×1600 1 4
4 K160Q Power User 2048 4 2560×1600 2 8
4 K140Q Power User 1024 2 2560×1600 4 16
4 K120Q Power User 512 2 2560×1600 8 32
4 K100 Knowledge 256 2 1920×1200 8 32
Worker
Maximum
Resolution
GRID Frame Virtual per Maximum
Physical Virtual Intended Buffer Display Display vGPUs Maximum
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
2 K280Q Designer 4096 4 2560×1600 1 2
2 K260Q Power 2048 4 2560×1600 2 4
User,
Designer
2 K240Q Power 1024 2 2560×1600 4 8
User,
Designer
2 K220Q Power 512 2 2560×1600 8 16
User,
Designer
2 K200 Knowledge 256 2 1920×1200 8 16
Worker
Maximum
Resolution
GRID Frame Virtual per Maximum Maximum
Physical Virtual Intended Buffer Display Display vGPUs vGPUs
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
2 M60-8Q Designer 8192 4 4096×2160 1 2
2 M60-4Q Designer 4096 4 4096×2160 2 4
2 M60-2Q Designer 2048 4 4096×2160 4 8
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 4
Introduction to NVIDIA GRID Virtual GPU
Maximum
Resolution
GRID Frame Virtual per Maximum Maximum
Physical Virtual Intended Buffer Display Display vGPUs vGPUs
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
2 M60-1Q Power 1024 2 4096×2160 8 16
User,
Designer
2 M60-0Q Power 512 2 2560×1600 16 32
User,
Designer
2 M60-1B Power User 1024 4 2560×1600 8 16
2 M60-0B Power User 512 2 2560×1600 16 32
2 M60-8A Virtual 8192 1 1280×1024 1 2
Application
User
2 M60-4A Virtual 4096 1 1280×1024 2 4
Application
User
2 M60-2A Virtual 2048 1 1280×1024 4 8
Application
User
2 M60-1A Virtual 1024 1 1280×1024 8 16
Application
User
Maximum
Resolution
GRID Frame Virtual per Maximum Maximum
Physical Virtual Intended Buffer Display Display vGPUs vGPUs
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
1 M6-8Q Designer 8192 4 4096×2160 1 1
1 M6-4Q Designer 4096 4 4096×2160 2 2
1 M6-2Q Designer 2048 4 4096×2160 4 4
1 M6-1Q Power 1024 2 4096×2160 8 8
User,
Designer
1 M6-0Q Power 512 2 2560×1600 16 16
User,
Designer
1 M6-1B Power User 1024 4 2560×1600 8 8
1 M6-0B Power User 512 2 2560×1600 16 16
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 5
Introduction to NVIDIA GRID Virtual GPU
Maximum
Resolution
GRID Frame Virtual per Maximum Maximum
Physical Virtual Intended Buffer Display Display vGPUs vGPUs
GPUs GPU Use Case (Mbytes) Heads Head per GPU per Board
1 M6-8A Virtual 8192 1 1280×1024 1 1
Application
User
1 M6-4A Virtual 4096 1 1280×1024 2 2
Application
User
1 M6-2A Virtual 2048 1 1280×1024 4 4
Application
User
1 M6-1A Virtual 1024 1 1280×1024 8 8
Application
User
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 6
Introduction to NVIDIA GRID Virtual GPU
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 7
Introduction to NVIDIA GRID Virtual GPU
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 8
Chapter 2.
GETTING STARTED
2.1.1. Prerequisites
Before proceeding, ensure that you have these prerequisites:
‣ NVIDIA GRID K1,K2, or Tesla M6, M60 cards.
‣ A server platform capable of hosting XenServer and the NVIDIA GRID or Tesla
cards. Refer to the release notes for a list of recommended servers.
‣ The NVIDIA GRID vGPU software package for Citrix XenServer, consisting of the
GRID Virtual GPU Manager for XenServer, and NVIDIA GRID vGPU drivers for
Windows, 32- and 64-bit.
‣ Citrix XenServer 6.2 SP1 with applicable hotfixes, or later, obtainable from Citrix.
‣ An installed Windows VM to be enabled with vGPU.
To run Citrix XenDesktop with virtual machines running NVIDIA Virtual GPU, you will
also need:
‣ Citrix XenDesktop 7.1 or later, obtainable from Citrix.
Earlier versions of Citrix XenServer and XenDesktop are not supported for use with
NVIDIA Virtual GPU.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 9
Getting Started
Review the release notes and known issues for GRID Virtual GPU before proceeding
with installation.
There are separate Virtual GPU Manager files for different versions of XenServer.
Consult the release notes for guidance on which package to use for each version of
XenServer.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 10
Getting Started
You can query the version of the current GRID package using the rpm –q
command:
GRID Virtual GPU Manager and Guest VM drivers must be matched from the same
release. After updating vGPU Manager, guest VMs will boot with vGPU disabled
until their guest vGPU driver is updated to match the vGPU Manager version.
Consult the release notes for further details.
NVIDIA GRID Virtual GPU Manager supplemental pack installation and update are
supported from XenServer 6.5 SP1 and XenCenter version 6.5 (build 6.5.2.2477)
onwards.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 11
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 12
Getting Started
Running the nvidia-smi command should produce a listing of the GPUs in your
platform.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 13
Getting Started
If nvidia-smi fails to run or doesn’t produce the expected output for all the NVIDIA
GPUs in your system, see Troubleshooting for troubleshooting steps.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 14
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 15
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 16
Getting Started
The VM must be in the powered-off state in order for its vGPU configuration to be
modified or removed.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 17
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 18
Getting Started
2.2.1. Prerequisites
Before proceeding, ensure that you have these prerequisites:
‣ NVIDIA GRID K1,K2, or Tesla M60, M6 cards.
‣ A server platform capable of hosting VMware vSphere Hypervisor (ESXi) and the
NVIDIA GRID or Tesla cards. Refer to the release notes for a list of recommended
servers.
‣ The NVIDIA GRID vGPU software package for VMware vSphere, consisting of
the GRID Virtual GPU Manager for ESXi, and NVIDIA GRID vGPU drivers for
Windows, 32- and 64-bit.
‣ VMware vSphere 2015 or later, obtainable from VMware.
‣ An installed Windows VM to be enabled with vGPU.
To run VMware Horizon with virtual machines running NVIDIA Virtual GPU, you will
also need:
‣ VMware Horizon 6.1 or later, obtainable from VMware.
Earlier versions of VMware vSphere and Horizon are not supported for use with NVIDIA
Virtual GPU.
Review the release notes and known issues for GRID Virtual GPU before proceeding
with installation.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 19
Getting Started
Before proceeding with the vGPU Manager installation make sure that all VMs are
powered off and the ESXi host is placed in maintenance mode. Refer to VMware’s
documentation on how to place an ESXi host in maintenance mode.
Caution GRID Virtual GPU Manager and Guest VM drivers must be matched from
the same release. After updating vGPU Manager, guest VMs will boot with vGPU
disabled until their guest vGPU driver is updated to match the vGPU Manager
version. Consult the release notes for further details.
Before proceeding with the vGPU Manager update, make sure that all VMs are
powered off and the ESXi host is placed in maintenance mode. Refer to VMware’s
documentation on how to place an ESXi host in maintenance mode
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 20
Getting Started
Installation Result
Message: Operation finished successfully.
Reboot Required: false
VIBs Installed: NVIDIA_bootbank_NVIDIA-vGPU-
VMware_ESXi_6.0_Host_Driver_361.40-1OEM.600.0.0.2159203
VIBs Removed: NVIDIA_bootbank_NVIDIA-vGPU-
VMware_ESXi_6.0_Host_Driver_352.70-1OEM.600.0.0.2494585
VIBs Skipped:
2. Reboot the ESXi host and remove it from maintenance mode.
Caution GRID Virtual GPU Manager and Guest VM drivers must be matched from
the same release. After updating vGPU Manager, guest VMs will boot with vGPU
disabled until their guest vGPU driver is updated to match the vGPU Manager
version. Consult the release notes for further details.
Running the nvidia-smi command should produce a listing of the GPUs in your
platform.
[root@esxi:~] nvidia-smi
Tue Mar 10 17:56:22 2015
+------------------------------------------------------+
| NVIDIA-SMI 361.40 Driver Version: 361.40 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 GRID K2 On | 0000:04:00.0 Off | Off |
| N/A 27C P8 27W / 117W | 11MiB / 4095MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 1 GRID K2 On | 0000:05:00.0 Off | Off |
| N/A 27C P8 27W / 117W | 10MiB / 4095MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 2 GRID K2 On | 0000:08:00.0 Off | Off |
| N/A 32C P8 27W / 117W | 10MiB / 4095MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 3 GRID K2 On | 0000:09:00.0 Off | Off |
| N/A 32C P8 27W / 117W | 10MiB / 4095MiB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 4 GRID K2 On | 0000:86:00.0 Off | Off |
| N/A 24C P8 27W / 117W | 10MiB / 4095MiB | 0% Default |
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 21
Getting Started
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| No running processes found |
+-----------------------------------------------------------------------------+
If nvidia-smi fails to report the expected output for all the NVIDIA GPUs in your
system, see Troubleshooting for troubleshooting steps.
Caution VMware vSphere does not support VM console in vSphere Web Client for
VMs configured with vGPU. Make sure that you have installed an alternate means
of accessing the VM (such as VMware Horizon or a VNC server) before you configure
vGPU.
VM console in vSphere Web Client will become active again once the vGPU parameters
are removed from the VM’s configuration.
To configure vGPU for a VM:
1. Select Edit Settings after right-clicking on the VM in the vCenter Web UI.
2. Select the Virtual Hardware tab.
3. In the New device list, select Shared PCI Device and click Add.
The PCI device field should be auto-populated with NVIDIA GRID vGPU, as
shown in Figure 10.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 22
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 23
Getting Started
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 24
Getting Started
This task completes the process of setting up a single vSphere VM to use GRID vGPU.
The VM is now capable of running the full range of DirectX and OpenGL graphics
applications.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 25
Getting Started
license is acquired, users are warned each time a vGPU tries and fails to obtain a license.
These warnings cease after a license is acquired.
Full information on configuring and using GRID licensed features, including vGPU, is
given in GRID Licensing User Guide. Basic configuration information is given here.
To configure vGPU licensing on Windows:
1. Open NVIDIA Control Panel and select the Manage License task in the Licensing
section of the navigation pane.
2. Enter the address of your local GRID License Server in the License Server field.
The address can be a fully-qualified domain name such as
gridlicense.example.com, or an IP address such as 10.31.20.45.
3. Leave the Port Number field unset.
It will default to 7070, which is the default port number used by NVIDIA GRID
License Server.
4. Click Apply to assign the settings.
The system will request the appropriate license for the current vGPU from the
configured license server.
If the system fails to obtain a license, refer to GRID Licensing User Guide for guidance on
troubleshooting.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 26
Chapter 3.
USING VGPU ON LINUX
Tesla M6 and Tesla M60 GPUs support vGPU on Linux VMs. 64-bit Linux guest VMs are
supported on the following virtual GPU types:
Refer to the driver release notes for further information on supported hypervisor and
Linux VM configurations.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 27
Using vGPU on Linux
The installer should launch and display the driver license agreement as shown in
Figure 12:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 28
Using vGPU on Linux
5. When prompted, accept the option to update the X configuration file (xorg.conf)
settings as shown in Figure 13:
The NVIDIA X Server Settings dialog box opens to show that the NVIDIA driver
is operational as shown in Figure 14.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 29
Using vGPU on Linux
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 30
Using vGPU on Linux
Once configured in gridd.conf, licensing settings persist across reboots and need only
be modified if the license server address changes, or the VM is switched to running GPU
passthrough.
# This is a template for the configuration file for NVIDIA Grid Daemon.
# For details on the file format, please refer to the nvidia-gridd(1)
# man page.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 31
Chapter 4.
PERFORMANCE MONITORING
Physical GPU performance monitoring can be done using the nvidia-smi command
line utility and, on Citrix XenServer platforms, using Citrix XenCenter.
It is not currently possible to monitor the performance of GPUs being used for GPU
pass-through.
nvidia-smi will not list any GPU currently allocated for GPU pass-through.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 32
Performance monitoring
|===============================+======================+======================|
| 0 GRID K1 | 0000:04:00.0 Off | N/A |
| N/A 27C P8 8W / 31W | 7% 270MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 1 GRID K1 | 0000:05:00.0 Off | N/A |
| N/A 26C P8 8W / 31W | 26% 1048MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 2 GRID K1 | 0000:06:00.0 Off | N/A |
| N/A 22C P0 13W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 3 GRID K1 | 0000:07:00.0 Off | N/A |
| N/A 25C P0 13W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 4 GRID K1 | 0000:86:00.0 Off | N/A |
| N/A 27C P0 14W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 5 GRID K1 | 0000:87:00.0 Off | N/A |
| N/A 27C P0 13W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 6 GRID K1 | 0000:88:00.0 Off | N/A |
| N/A 29C P0 13W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
| 7 GRID K1 | 0000:89:00.0 Off | N/A |
| N/A 28C P0 12W / 31W | 0% 9MB / 4095MB | 0% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Compute processes: GPU Memory |
| GPU PID Process name Usage |
|=============================================================================|
| 0 10300 /usr/lib/xen/bin/vgpu 256MB |
| 1 10350 /usr/lib/xen/bin/vgpu 256MB |
| 1 10321 /usr/lib/xen/bin/vgpu 256MB |
| 1 11512 /usr/lib/xen/bin/vgpu 256MB |
| 1 10210 /usr/lib/xen/bin/vgpu 256MB |
+-----------------------------------------------------------------------------+
[root@xenserver ~]#
For a list of commands supported by nvidia-smi, run nvidia-smi -h. Note that not
all commands apply to GRID supported GPUs.
Counters are listed for each physical GPU not currently being used for GPU pass-
through.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 33
Performance monitoring
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 34
Chapter 5.
XENSERVER VGPU MANAGEMENT
This chapter describes Citrix XenServer advanced vGPU management techniques using
XenCenter and xe command line operations.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 35
XenServer vGPU Management
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 36
XenServer vGPU Management
[root@xenserver ~]#
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 37
XenServer vGPU Management
[root@xenserver ~]#
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 38
XenServer vGPU Management
[root@xenserver ~]
Creating the vgpu object for a VM does not immediately cause a virtual GPU to
be created on a physical GPU. Instead, the vgpu object is created whenever its
associated VM is started. For more details on how vGPUs are created at VM startup, see
Controlling vGPU allocation.
The owning VM must be in the powered-off state in order for the vgpu-create
command to succeed.
A vgpu object’s owning VM, associated GPU group, and vGPU type are fixed at
creation and cannot be subsequently changed. To change the type of vGPU allocated
to a VM, delete the existing vgpu object and create another one.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 39
XenServer vGPU Management
‣ The GPU group that the vgpu object is associated with is checked for a physical
GPU that can host a vGPU of the required type (i.e. the vgpu object’s associated
vgpu-type). Because vGPU types cannot be mixed on a single physical GPU, the
new vGPU can only be created on a physical GPU that has no vGPUs resident on it,
or only vGPUs of the same type, and less than the limit of vGPUs of that type that
the physical GPU can support.
‣ If no such physical GPUs exist in the group, the vgpu creation fails and the VM
startup is aborted.
‣ Otherwise, if more than one such physical GPU exists in the group, a physical
GPU is selected according to the GPU group’s allocation policy, as described in GPU
allocation policy
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 40
XenServer vGPU Management
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 41
XenServer vGPU Management
[root@xenserver ~]#
If the vGPU is not currently running, the resident-on parameter is not instantiated
for the vGPU, and the vgpu-param-get operation returns:
<not in database>
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 42
XenServer vGPU Management
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 43
XenServer vGPU Management
[root@xenserver ~]
[root@xenserver ~]#
4. If any vGPUs are listed, shut down the VMs associated with them.
5. Change the gpu-group-uuid parameter of the physical GPU to the UUID of the
newly-created GPU group:
[root@xenserver ~]# xe pgpu-param-set uuid=7c1e3cff-1429-0544-df3d-
bf8a086fb70a gpu-group-uuid=585877ef-5a6c-66af-fc56-7bd525bdc2f6
[root@xenserver ~]#
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 44
XenServer vGPU Management
Any vgpu object now created that specifies this GPU group UUID will always have its
vGPUs created on the GPU at PCI bus ID 0000:05:0.0.
You can add more than one physical GPU to a manually-created GPU group – for
example, to represent all the GPUs attached to the same CPU socket in a multi-socket
server platform - but as for automatically-created GPU groups, all the physical GPUs
in the group must of the same type.
In XenCenter, manually-created GPU groups appear in the GPU type listing in a VM’s
GPU Properties. Select a GPU type within the group from which you wish the vGPU to
be allocated:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 45
XenServer vGPU Management
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 46
XenServer vGPU Management
‣ A physical GPU can host GRID vGPUs, or can be used for pass-through, but cannot
do both at the same time.
‣ The performance of a physical GPU passed through to a VM cannot be monitored
through XenCenter or nvidia-smi (see Performance monitoring).
‣ Pass-through GPUs do not provide console output via XenCenter’s VM Console tab.
Use a remote graphics connection directly into the VM to access the VM’s OS.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 47
XenServer vGPU Management
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 48
Chapter 6.
XENSERVER PERFORMANCE TUNING
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 49
XenServer Performance Tuning
vGPU active, but for high performance remote accesses, use an accelerated stack
such as XenDesktop.
The new console VGA setting takes effect the next time the VM is started or rebooted.
With console VGA disabled, the XenCenter console will display the Windows boot
splash screen for the VM, but nothing beyond that.
Caution
If you disable console VGA before you have installed or enabled an alternate
mechanism to access the VM (such as XenDesktop), you will not be able to interact
with the VM once it has booted.
You can recover console VGA access by making one of the following changes:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 50
XenServer Performance Tuning
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 51
XenServer Performance Tuning
XenServer creates GPU groups with a default allocation policy of depth-first. See GPU
allocation policy for details on switching the allocation policy to breadth-first.
Due to vGPU’s requirement that only one type of vGPU can run on a physical GPU at
any given time, not all physical GPUs may be available to host the vGPU type required
by the new VM.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 52
Chapter 7.
TROUBLESHOOTING
This chapter describes basic troubleshooting steps for GRID vGPU on Citrix XenServer
and VMware vSphere, and how to collect debug information when filing a bug report.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 53
Troubleshooting
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 54
Troubleshooting
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 55
Troubleshooting
For Xen open source/XCP users, if you are reporting a domain issue,
please run: nvidia-bug-report.sh --domain-name <"domain_name">
Running nvidia-bug-report.sh...
If the bug report script hangs after this point consider running with
--safe-mode command line argument.
complete
[root@xenserver ~]#
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 56
Troubleshooting
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 57
Appendix A.
XENSERVER BASICS
This appendix outlines basic operations on XenServer that are needed in order to install
and configure GRID vGPU, and optimize XenServer operation with vGPU.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 58
XenServer Basics
‣ If you are running the client from dom0, use the secure copy command scp.
The scp command is part of the SSH suite of applications. It is implemented in
dom0 and can be used to copy from a remote SSH-enabled server:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 59
XenServer Basics
C:\Users\nvidia>
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 60
XenServer Basics
‣ To list all VMs and their associated UUIDs, use xe vm-list without any
parameters:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 61
XenServer Basics
vm-uuid is the VM’s UUID, which you can obtain as explained in Determining a VM’s
UUID.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 62
XenServer Basics
socket_count: 2
vendor: GenuineIntel
speed: 2600.064
modelname: Intel(R) Xeon(R) CPU E5-2670 0 @ 2.60GHz
family: 6
model: 45
stepping: 7
flags: fpu de tsc msr pae mce cx8 apic sep mtrr mca
cmov pat clflush acpi mmx fxsr sse sse2 ss ht nx constant_tsc nonstop_tsc
aperfmperf pni pclmulqdq vmx est ssse3 sse4_1 sse4_2 x2apic popcnt aes
hypervisor ida arat tpr_shadow vnmi flexpriority ept vpid
features: 17bee3ff-bfebfbff-00000001-2c100800
features_after_reboot: 17bee3ff-bfebfbff-00000001-2c100800
physical_features: 17bee3ff-bfebfbff-00000001-2c100800
maskable: full
2. Set VCPUs-params:mask to pin a VM’s vCPUs to a specific socket or to specific
cores within a socket.
This setting persists over VM reboots and shutdowns. In a dual socket platform with
32 total cores, cores 0-15 are on socket 0, and cores 16-31 are on socket 1.
In the examples that follow, vm-uuid is the VM’s UUID, which you can obtain as
explained in Determining a VM’s UUID.
‣ To restrict a VM to only run on socket 0, set the mask to specify cores 0-15:
[root@xenserver ~]# xe vm-param-set uuid=vm-uuid VCPUs-
params:mask=0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15
‣ To restrict a VM to only run on socket 1, set the mask to specify cores 16-31:
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 63
XenServer Basics
‣ The dom0 shell’s vCPUs are unpinned and able to run on any physical CPU in the
system.
CPU pinnings applied this way take effect immediately but do not persist over
reboots.
2. To make settings persistent, add xl vcpu-pin commands into /etc/rc.local.
For example:
xl vcpu-pin 0 0 0-15
xl vcpu-pin 0 1 0-15
xl vcpu-pin 0 2 0-15
xl vcpu-pin 0 3 0-15
xl vcpu-pin 0 4 16-31
xl vcpu-pin 0 5 16-31
xl vcpu-pin 0 6 16-31
xl vcpu-pin 0 7 16-31
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 64
XenServer Basics
has its root ports on a higher bus number, typically bus 0x20 or bus 0x80 depending on
the specific server platform.
www.nvidia.com
GRID Virtual GPU DU-06920-001 _v3.3 (GRID) | 65
Notice
ALL NVIDIA DESIGN SPECIFICATIONS, REFERENCE BOARDS, FILES, DRAWINGS,
DIAGNOSTICS, LISTS, AND OTHER DOCUMENTS (TOGETHER AND SEPARATELY,
"MATERIALS") ARE BEING PROVIDED "AS IS." NVIDIA MAKES NO WARRANTIES,
EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO THE
MATERIALS, AND EXPRESSLY DISCLAIMS ALL IMPLIED WARRANTIES OF
NONINFRINGEMENT, MERCHANTABILITY, AND FITNESS FOR A PARTICULAR
PURPOSE.
Information furnished is believed to be accurate and reliable. However, NVIDIA
Corporation assumes no responsibility for the consequences of use of such
information or for any infringement of patents or other rights of third parties
that may result from its use. No license is granted by implication of otherwise
under any patent rights of NVIDIA Corporation. Specifications mentioned in this
publication are subject to change without notice. This publication supersedes and
replaces all other information previously supplied. NVIDIA Corporation products
are not authorized as critical components in life support devices or systems
without express written approval of NVIDIA Corporation.
HDMI
HDMI, the HDMI logo, and High-Definition Multimedia Interface are trademarks or
registered trademarks of HDMI Licensing LLC.
OpenCL
OpenCL is a trademark of Apple Inc. used under license to the Khronos Group Inc.
Trademarks
NVIDIA and the NVIDIA logo are trademarks or registered trademarks of NVIDIA
Corporation in the U.S. and other countries. Other company and product names
may be trademarks of the respective companies with which they are associated.
Copyright
© 2013-2016 NVIDIA Corporation. All rights reserved.
www.nvidia.com