question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Question] Support of nvidia eGPU with nvidia Optimus GPU ?

See original GitHub issue

Hi , I recently acquired an eGPU enclose and equipped it with and RTX2060 to work on CAD because my MX150 was struggling a little on some projects. On Windows 10, thanks to the Nvidia driver, switching between the two GPU is really easy and it made me wondering if something similar could be achieved on linux thanks to this tool.

I’m running an ArchLinux (kernel 5.3.1) with Xorg 1.20.5, nvidia driver 435.21 and optimus-manager 1.2

I configured the xorg-nvidia-config with the following lines to enable the support of eGPU and eGPU outputs:

Option "AllowExternalGpus" "true"
Option "AllowEmptyInitialConfiguration" "true"

I run the nvidia-smi and saw that my eGPU was indeed loaded:

+-----------------------------------------------------------------------------+
| NVIDIA-SMI 435.21       Driver Version: 435.21       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce MX150       Off  | 00000000:01:00.0 Off |                  N/A |
| N/A   42C    P0    N/A /  N/A |    411MiB /  2002MiB |      2%      Default |
+-------------------------------+----------------------+----------------------+
|   1  GeForce RTX 2060    Off  | 00000000:09:00.0 Off |                  N/A |
|  0%   34C    P8     6W / 170W |      1MiB /  5934MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID   Type   Process name                             Usage      |
|=============================================================================|
|    0      7931      G   /usr/lib/Xorg                                202MiB |
|    0      8042      G   /usr/bin/kwin_x11                            121MiB |
|    0      8053      G   /usr/bin/plasmashell                          71MiB |
+-----------------------------------------------------------------------------+

But when i ran the glxinfo utility, i saw that my optimus GPU is still being used as the OpenGL renderer:

lucasgrelaud@lg-laptop ~]$ glxinfo -B
name of display: :0
display: :0  screen: 0
direct rendering: Yes
Memory info (GL_NVX_gpu_memory_info):
    Dedicated video memory: 2048 MB
    Total available memory: 2048 MB
    Currently available dedicated video memory: 1589 MB
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce MX150/PCIe/SSE2
OpenGL core profile version string: 4.6.0 NVIDIA 435.21
OpenGL core profile shading language version string: 4.60 NVIDIA
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile

OpenGL version string: 4.6.0 NVIDIA 435.21
OpenGL shading language version string: 4.60 NVIDIA
OpenGL context flags: (none)
OpenGL profile mask: (none)

OpenGL ES profile version string: OpenGL ES 3.2 NVIDIA 435.21
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20

So i’m wondering if I can disable the MX150 so the RTX2060 willl be set as the main OpenGL / Xorg rernderer and use its power under archlinux.

Any idea of the feasibility of this request ?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

3reactions
jorritsmitcommented, Mar 25, 2020

@Askannz I know this is closed, but i had the same problem and i think i have a solution. i would make a pull request for this, but lets check first if this is a sane idea. I saw that optimus-manager looks for the available nvida gpu bus ids and picks the first one. Would it be an idea to give a “preferred bus id” or “prefered product ID” option in the config for nvidia cards. If then the eGPU is not connected, the dGPU will be selected, but if it is connected the eGPU will be selected. the eGPU will then act as the dGPU.

I would like this feature in optimus-manager because:

  • advantage of using this constantly update repo, with all improvements to config files
  • tray icon to easily switch to intel
  • flexibility in every setup
  • not messing around with Xorg configs myself

If you like the idea i will start to make it and make a pull request in the near future

0reactions
jorritsmitcommented, Jan 18, 2021

@MilesConn no I didn’t get a response so I didn’t bother with it anymore. Maybe someone else did?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Nvidia optimus question – Expresscard, mPCIe, M.2 eGPU
Problem : When i boot with the egpu connected, the intel hd graphics simply dissapears from the device manager and when i try...
Read more >
eGPU issue: how to enable the external GPU to recognize the ...
I am struggling to set up the external GPU on my laptop computer (Fujitsu ... I found an option in BIOS to disable...
Read more >
NVIDIA Advanced Optimus Overview
NVIDIA Advanced Optimus Overview · Display-specific features available on discrete GPU (like NVIDIA® G-SYNC®, higher refresh rates) may not be ...
Read more >
W530, Expresscard, Nvidia Optimus, beginner questions
Dumb questions: Is Optimus possible only with an Nvidia card in the eGPU? (using external monitor only). Should i be expecting x16.2 speed ......
Read more >
eGPU Window 10 optimus mode problem - Tech|Inferno
My eGPU(GTX650TI) works with Windows 10 but not in optimus mode,Both ... nvidia gpu... if I don't actually connect a monitor to my...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found