GPU-accelerated instances installed with the NVIDIA GRID driver can deliver high-performance computing capabilities or provide smoother graphics display effects in specific scenarios. The scenarios include general-purpose computing scenarios such as AI scenarios, and graphics acceleration scenarios such as Open Graphics Library (OpenGL), Direct3D, and cloud gaming scenarios. This topic describes how to install the GRID driver on a vGPU-accelerated Linux instance by using Cloud Assistant.
Before you use Cloud Assistant to install the GRID driver, we recommend that you familiarize yourself with the concepts of Cloud Assistant. For more information, see Overview. The system automatically installs Cloud Assistant plug-ins when you create GPU-accelerated instances.
Supported instances
You can use Cloud Assistant to install the GRID driver only on vGPU-accelerated Linux instances that belong to the sgn8ia, vgn6i-vws, vgn7i-vws, and sgn7i-vws instance families. For more information, see vgn and sgn series of vGPU-accelerated instance families. The following table lists the GRID driver versions and CUDA versions that can be installed on the instances.
Instance family | Public image version | NVIDIA GRID driver version | CUDA version |
sgn8ia |
| 535.183.06 | 12.2 |
vgn6i-vws, vgn7i-vws, and sgn7i-vws |
| 470.239.06 | 11.4 |
GPU-accelerated compute-optimized Linux instances such as gn7i, gn6i, ebmgn7i, and ebmgn6i instances support graphics acceleration by using official NVIDIA drivers. You do not need to install the GRID driver on the instances. For more information, see gn, ebm, and scc series of GPU-accelerated compute-optimized instance families.
Procedure
Log on to the ECS console.
In the left-side navigation pane, choose .
In the top navigation bar, select the region where the desired instance resides.
On the ECS Instances tab, find the desired instance and click Run Command in the Actions column.
In the Create Command panel, configure parameters in the Command Information section.
The following section describes the main parameters. Use default values for other parameters. For more information, see Create a command in the ECS console.
ImportantConfigure the parameters based on the values that are provided in the following section. Otherwise, Cloud Assistant may fail to run the command.
① Command Type: Select the command type. In this example, Shell is selected.
② Command content: Paste the following command. For more information about sample shell commands, see View the system configurations of ECS instances.
Cloud Assistant command for a sgn8ia instance:
if acs-plugin-manager --list --local | grep gpu_grid_driver_install > /dev/null 2>&1 then acs-plugin-manager --remove --plugin gpu_grid_driver_install fi acs-plugin-manager --exec --plugin gpu_grid_driver_install
Cloud Assistant command for a vgn6i-vws, vgn7i-vws, or sgn7i-vws instance:
if acs-plugin-manager --list --local | grep grid_driver_install > /dev/null 2>&1 then acs-plugin-manager --remove --plugin grid_driver_install fi acs-plugin-manager --exec --plugin grid_driver_install
③ Timeout: Specify the timeout period for running the command. When the command execution times out, Cloud Assistant forcefully stops the execution process. In this example, the value is set to 600.
NoteThe value of the Timeout parameter must be a positive integer from 10 to 86,400. Unit: seconds. 86,400 seconds is equal to 24 hours.
Click Run to run the Cloud Assistant command to install the GRID driver.
Wait until the command execution is complete. Then, view the execution result on the Instances tab in the execution details panel.
ImportantIf another GRID driver version is already installed on the instance, Cloud Assistant automatically uninstalls the GRID driver version and installs the latest GRID driver version.
The process of installing the GRID driver takes approximately 5 to 10 minutes to complete. Wait until the driver is installed.
Connect to the GPU-accelerated instance.
For more information, see Use Workbench to connect to a Linux instance over SSH.
Run the following command to check whether the GRID driver is installed:
nvidia-smi
If the following command output is displayed, the GRID driver is upgraded or installed.
Test and verify the graphics acceleration effect
This section provides an example on how to use an OpenGL Extension to the X Window System (GLX) test program to verify the graphics acceleration effect on an instance that has the GRID driver installed. In this example, an instance that runs Ubuntu 18.04 64-bit is used.
Prepare an environment that is used to test the graphics acceleration effect.
Run the following command to install x11vnc:
apt-get install x11vnc
Run the
lspci | grep NVIDIA
command to query the BusID value of the GPU that is used by the instance.In this example, the queried BusID value is
00:07.0
.Configure the X Server environment and restart the system.
Run the
nvidia-xconfig --enable-all-gpus --separate-x-screens
command.Modify the /etc/X11/xorg.conf file. In
Section "Device"
, add the BusID setting. In this example, theBusID "PCI:0:7:0"
setting is added.Run the
reboot
command to restart the system.
Run the following command to install the GLX test program:
apt-get install mesa-utils
Run the
startx
command to start X Server.If the
startx
command does not take effect, run theapt-get install xinit
command to install xinit.When you run the
startx
command, thehostname: Name or service not known
error message may appear. The error message does not affect the startup of X Server. You can run thehostname
command to query the hostname of your instance. Then, you can modify the /etc/hosts file by replacing thehostname
that follows127.0.0.1
with the hostname of your instance.
Start an SSH terminal session on a client and run the following command to start x11vnc:
x11vnc -display :1
If the following command output is displayed, x11vnc is started. In this case, you can connect to the instance by using a Virtual Network Computing (VNC) remote access application, such as VNC Viewer.
Log on to the ECS console and configure a security group rule that allows inbound traffic on TCP port 5900 for the instance.
For more information, see Add a security group rule.
On your on-premises computer, use a VNC application, such as VNC Viewer, and enter
<Public IP address of the instance>:5900
to connect to the instance and go to a K Desktop Environment (KDE) desktop.Run the
glxinfo
command to view the configurations that are supported by the GRID driver.Start a new terminal session on the SSH client.
Run the
export DISPLAY=:1
command.Run the
glxinfo -t
command to query the configurations that are supported by the GRID driver.
Run the
glxgears
command to test the GRID driver.On the KDE desktop, right-click the desktop and select Run Command.
Run the
glxgears
command to start the GLX test program.If the following window appears, the GRID driver works as expected.
References
If you purchase a vGPU-accelerated Windows instance and install the GRID driver on the instance, you can use the instance in graphics acceleration and rendering scenarios, such as OpenGL, Direct3D, and cloud gaming scenarios. For more information, see Install the GRID driver on a GPU-accelerated compute-optimized or vGPU-accelerated Windows instance.
The system can automatically load the GRID driver when you create a GPU-accelerated instance. For more information, see Create a GPU-accelerated instance.