Hello,
I want to use VirtualGL inside a headless container (running on a remote server) and access it via VNC. I installed VirtualGL in a Centos container, configured using ‘/opt/VirtualGL/bin/vglserver_config’ and started a vnc session. Unfortunately, I get an error when trying to start glxgears
$ vglrun glxgears
[VGL] ERROR: Could not open display :0.
I can access the gpu inside the container,
$ nvidia-smi
Fri Nov 22 05:21:54 2019
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 440.31 Driver Version: 440.31 CUDA Version: 10.2 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
|===============================+======================+======================|
| 0 Quadro P2000 Off | 00000000:82:00.0 Off | N/A |
| 79% 46C P0 19W / 75W | 0MiB / 5059MiB | 1% Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: GPU Memory |
| GPU PID Type Process name Usage |
|=============================================================================|
| No running processes found |
+-----------------------------------------------------------------------------+
The configuration log is as follows
# /opt/VirtualGL/bin/vglserver_config
1) Configure server for use with VirtualGL
2) Unconfigure server for use with VirtualGL
X) Exit
Choose:
1
Restrict 3D X server access to vglusers group (recommended)?
[Y/n]
Restrict framebuffer device access to vglusers group (recommended)?
[Y/n]
Disable XTEST extension (recommended)?
[Y/n]
... Creating vglusers group ...
groupadd: group 'vglusers' already exists
Could not add vglusers group (probably because it already exists.)
... Creating /etc/opt/VirtualGL/ ...
... Granting read permission to /etc/opt/VirtualGL/ for vglusers group ...
... Modifying /etc/security/console.perms to disable automatic permissions
for DRI devices ...
... Creating /etc/modprobe.d/virtualgl.conf to set requested permissions for
/dev/nvidia* ...
... Attempting to remove nvidia module from memory so device permissions
will be reloaded ...
rmmod: ERROR: Module nvidia is in use by: nvidia_uvm nvidia_modeset
... Granting write permission to /dev/nvidia-uvm /dev/nvidia-uvm-tools /dev/nvidia0 /dev/nvidiactl for vglusers group ...
chmod: changing permissions of '/dev/nvidia-uvm': Read-only file system
chmod: changing permissions of '/dev/nvidia-uvm-tools': Read-only file system
chmod: changing permissions of '/dev/nvidiactl': Read-only file system
chown: changing ownership of '/dev/nvidia-uvm': Read-only file system
chown: changing ownership of '/dev/nvidia-uvm-tools': Read-only file system
chown: changing ownership of '/dev/nvidiactl': Read-only file system
... Granting write permission to /dev/dri/card0 for vglusers group ...
... Modifying /etc/X11/xorg.conf.d/99-virtualgl-dri to enable DRI permissions
for vglusers group ...
... Modifying /etc/X11/xorg.conf to enable DRI permissions
for vglusers group ...
... Adding vglgenkey to /etc/gdm/Init/Default script ...
... Creating /usr/share/gdm/greeter/autostart/virtualgl.desktop ...
... Disabling XTEST extension in /etc/gdm/custom.conf ...
... Setting default run level to 5 (enabling graphical login prompt) ...
... Commenting out DisallowTCP line (if it exists) in /etc/gdm/custom.conf ...
Done. You must restart the display manager for the changes to take effect.
IMPORTANT NOTE: Your system uses modprobe.d to set device permissions. You
must execute rmmod nvidia with the display manager stopped in order for the
new device permission settings to become effective.
I dont have any display manager running inside the container. How can i get VirtualGL running in an lxd container?
Thanks