VirtualGL: Difference between revisions
m →Usage |
|||
| Line 1: | Line 1: | ||
<br /> | <br /> | ||
== Installation == | ==Installation== | ||
# Download the .rpm packages from VirtualGL's repository (on SourceForge) and install it. | #Download the .rpm packages from VirtualGL's repository (on SourceForge) and install it. | ||
# Run the configuration helper script at <code>/opt/VirtualGL/bin/vglserver_config</code>. You will be asked some questions: | #Run the configuration helper script at <code>/opt/VirtualGL/bin/vglserver_config</code>. You will be asked some questions: | ||
#* If using VNC with TurboVNC or TigerVNC, do not disable XTEST extension | #*If using VNC with TurboVNC or TigerVNC, do not disable XTEST extension | ||
#* You may restrict certain users access to the <code>vglusers</code> group when prompted. | #*You may restrict certain users access to the <code>vglusers</code> group when prompted. | ||
#* The script writes to various places., including <code>/etc/security/console.perms</code>, <code>/etc/modprobe.d/virtualgl.conf</code>, <code>/etc/X11/xorg.conf.d/99-virtualgl-dri</code> | #*The script writes to various places., including <code>/etc/security/console.perms</code>, <code>/etc/modprobe.d/virtualgl.conf</code>, <code>/etc/X11/xorg.conf.d/99-virtualgl-dri</code> | ||
# I had issues with GDM working with VirtualGL. Install LightDM and configure the seats to generate a key. {{Highlight | #I had issues with GDM working with VirtualGL. Install LightDM and configure the seats to generate a key. {{Highlight | ||
| code = [Seat:seat0] | | code = [Seat:seat0] | ||
display-setup-script=/usr/bin/vglgenkey | display-setup-script=/usr/bin/vglgenkey | ||
| lang = text | | lang = text | ||
}} | }} | ||
# After restarting your login manager, verify that <code>/etc/opt/VirtualGL/</code> has a key file. | #After restarting your login manager, verify that <code>/etc/opt/VirtualGL/</code> has a key file. | ||
If you need to tweak xorg.conf, you may generate one using Nvidia's nvidia-xconfig utility. You may wish to specify the device the screen is to use by looking up the PCI bus ID and passing it as an argument. Eg: | If you need to tweak <code>xorg.conf</code>, you may generate one using Nvidia's <code>nvidia-xconfig</code> utility. You may wish to specify the device the screen is to use by looking up the PCI bus ID and passing it as an argument. Eg: | ||
{{highlight|lang=terminal|code= | {{highlight|lang=terminal|code= | ||
# nvidia-xconfig --use-display-device=none --busid="PCI:6:0:0" | # nvidia-xconfig --use-display-device=none --busid="PCI:6:0:0" | ||
| Line 21: | Line 21: | ||
== Usage == | ==Usage== | ||
The idea with VirtualGL is that the program you wish to have GPU acceleration renders locally (ie. the remote host that's running the login manager) and VirtualGL then copies the framebuffer back to you. As a result, anything you do run with VirtualGL can appear on the local display which could be a security risk for workstations (such as in a lab setting). | The idea with VirtualGL is that the program you wish to have GPU acceleration renders locally (ie. the remote host that's running the login manager) and VirtualGL then copies the framebuffer back to you. As a result, anything you do run with VirtualGL can appear on the local display which could be a security risk for workstations (such as in a lab setting). | ||
To run a specific application with VirtualGL, use the vglrun command. To help debug issues, use the +v flag to enable verbose logging. | To run a specific application with VirtualGL, use the <code>vglrun</code> command. To help debug issues, use the <code>+v</code> flag to enable verbose logging. | ||
A few environment variables you should be aware of: | A few environment variables you should be aware of: | ||
* VGL_DISPLAY should point to the local display with the login manager. (eg. :0) | |||
* DISPLAY or the -display option should be set to the target display (eg. :1.0, or whatever your display is in a VNC session) | *<code>VGL_DISPLAY</code> should point to the local display with the login manager. (eg. :0) | ||
* VGL_VERBOSE enables debugging | *<code>DISPLAY</code> or the -display option should be set to the target display (eg. :1.0, or whatever your display is in a VNC session) | ||
* VGL_LOGO will print 'VGL' on the window to show that it's rendering with VirtualGL | *<code>VGL_VERBOSE</code> enables debugging | ||
*<code>VGL_LOGO</code> will print 'VGL' on the window to show that it's rendering with VirtualGL. | |||
<br /> | |||
Revision as of 18:45, 9 February 2021
Installation
- Download the .rpm packages from VirtualGL's repository (on SourceForge) and install it.
- Run the configuration helper script at
/opt/VirtualGL/bin/vglserver_config. You will be asked some questions:- If using VNC with TurboVNC or TigerVNC, do not disable XTEST extension
- You may restrict certain users access to the
vglusersgroup when prompted. - The script writes to various places., including
/etc/security/console.perms,/etc/modprobe.d/virtualgl.conf,/etc/X11/xorg.conf.d/99-virtualgl-dri
- I had issues with GDM working with VirtualGL. Install LightDM and configure the seats to generate a key.
[Seat:seat0] display-setup-script=/usr/bin/vglgenkey
- After restarting your login manager, verify that
/etc/opt/VirtualGL/has a key file.
If you need to tweak xorg.conf, you may generate one using Nvidia's nvidia-xconfig utility. You may wish to specify the device the screen is to use by looking up the PCI bus ID and passing it as an argument. Eg:
# nvidia-xconfig --use-display-device=none --busid="PCI:6:0:0"
Usage
The idea with VirtualGL is that the program you wish to have GPU acceleration renders locally (ie. the remote host that's running the login manager) and VirtualGL then copies the framebuffer back to you. As a result, anything you do run with VirtualGL can appear on the local display which could be a security risk for workstations (such as in a lab setting).
To run a specific application with VirtualGL, use the vglrun command. To help debug issues, use the +v flag to enable verbose logging.
A few environment variables you should be aware of:
VGL_DISPLAYshould point to the local display with the login manager. (eg. :0)DISPLAYor the -display option should be set to the target display (eg. :1.0, or whatever your display is in a VNC session)VGL_VERBOSEenables debuggingVGL_LOGOwill print 'VGL' on the window to show that it's rendering with VirtualGL.