[Sticky] Xorg config for Arch linux; Dell XPS 9360 TB3  

  RSS

(@snugghash)
New Member
Joined: 5 months ago
Posts: 1
August 10, 2018 11:13 pm  

Greetings,
I've been looking around and this one critical piece of info is not anywhere except where I found it - in the Xorg logs for some arcane config. This needs to be added to the official sticky perhaps.

To get eGPU working with external monitor and internal one disabled:

  • Install the correct version and build of drivers (nvidia or nvidia-dkms or equivalent for other makes)
  • Use something like the following for the Xorg config:
Section "Module"
 Load "modesetting"
EndSection

Section "Device"
 Identifier "nvidia"
 Driver "nvidia"
 BusID "PCI:6:0:0"
 Option "AllowEmptyInitialConfiguration"
 Option "AllowExternalGpus"
EndSection

The critical thing is the `Option "AllowExternalGpus"`. The existence of this isn't documented on the threads on nvidia support, or on egpu.io. First section turns off the internal display. If that's missing the systemd output will stay on internal display screen, frozen. Nothing else is necessary, no DM config files, or nvidia-xconfig, or adding drivers to KMS, or using secure TB3 like Da_blitz's guide suggests. Once nvidia-smi works, this should be it - no bumblebee necessary either.

This was particularly infuriating because nvidia-xsettings --query-gpu-info recognizes the external monitor. Yet xrandr doesn't. And using most configs crashes Xorg with a multitude of errors, from "No screens found" to "no usable config", to "Failed to get display number from pipe". All were rabbit holes.

I doubt I missed something in my scouring of the internet, but you're welcome to point it out if so.
Thanks

EDIT:
So as it turns out, keeping bumblebee installed uses the LLVM software rendering for X. Not what we want. Uninstall LLVM, use the standard modesetting params in the DM startup config files to get X rendered by the graphics card. And as a bonus, we also get extended displays in this config.

Soon I will add my build link or system & eGPU details to this my signature to give context to my posts


nu_ninja and theitsage liked
ReplyQuote
nu_ninja
(@nu_ninja)
Trusted Member
Joined: 9 months ago
Posts: 95
September 28, 2018 3:47 am  

I know this post is 2 months old, but I found it useful so for any passers-by this was the final step in getting my RX460 recognized and used in Linux Mint 19. See my signature for build post. I used the following config text:

Section "Device"
     Identifier "AMD"
     Driver "amdgpu"
     BusID "PCI:10:0:0" ##ID in decimal, convert from hex if necessary
     Option "AllowEmptyInitialConfiguration"
     Option "AllowExternalGpus"
EndSection

Mid-2012 13" Macbook Pro (MacBookPro9,2) TB1 -> RX 460 (AKiTiO Node)
+ macOS 10.14.1+Win10
+ Linux Mint 19


ReplyQuote
nix8
 nix8
(@nix8)
New Member
Joined: 2 months ago
Posts: 2
November 6, 2018 5:04 pm  
Posted by: snugghash

Greetings,
I've been looking around and this one critical piece of info is not anywhere except where I found it - in the Xorg logs for some arcane config. This needs to be added to the official sticky perhaps.

To get eGPU working with external monitor and internal one disabled:

  • Install the correct version and build of drivers (nvidia or nvidia-dkms or equivalent for other makes)
  • Use something like the following for the Xorg config:
Section "Module"
 Load "modesetting"
EndSection

Section "Device"
 Identifier "nvidia"
 Driver "nvidia"
 BusID "PCI:6:0:0"
 Option "AllowEmptyInitialConfiguration"
 Option "AllowExternalGpus"
EndSection

The critical thing is the `Option "AllowExternalGpus"`. The existence of this isn't documented on the threads on nvidia support, or on egpu.io. First section turns off the internal display. If that's missing the systemd output will stay on internal display screen, frozen. Nothing else is necessary, no DM config files, or nvidia-xconfig, or adding drivers to KMS, or using secure TB3 like Da_blitz's guide suggests. Once nvidia-smi works, this should be it - no bumblebee necessary either.

This was particularly infuriating because nvidia-xsettings --query-gpu-info recognizes the external monitor. Yet xrandr doesn't. And using most configs crashes Xorg with a multitude of errors, from "No screens found" to "no usable config", to "Failed to get display number from pipe". All were rabbit holes.

I doubt I missed something in my scouring of the internet, but you're welcome to point it out if so.
Thanks

EDIT:
So as it turns out, keeping bumblebee installed uses the LLVM software rendering for X. Not what we want. Uninstall LLVM, use the standard modesetting params in the DM startup config files to get X rendered by the graphics card. And as a bonus, we also get extended displays in this config.

This config works for me (no bumblebee) while the eGPU is plugged in. X won't start when I'm running the internal GPU (intel UHD 620), such as when I unplug from my desk (after fully shutting down) to go mobile. I have the XORG config in `/etc/X11/xorg.conf.d/10-egpu.conf`--if I delete this file when booting without the eGPU, X works fine.

Has anyone seen anything like this?

Also, unrelated: has anyone figured out how to make this setup plug-and-play? I'd like to be able to unplug and go back to the internal GPU without rebooting.

Soon I will add my build link or system & eGPU details to this my signature to give context to my posts


ReplyQuote
nu_ninja
(@nu_ninja)
Trusted Member
Joined: 9 months ago
Posts: 95
November 7, 2018 4:36 am  

@nix8

Are you using Nvidia? I assume you are from the bumblebee comment. If so check out this thread which seems to give a nicer setup using the proprietary drivers. If not I get the same issue using my amd card and will post a build guide with a plug and play solution soon when I have time.

Mid-2012 13" Macbook Pro (MacBookPro9,2) TB1 -> RX 460 (AKiTiO Node)
+ macOS 10.14.1+Win10
+ Linux Mint 19


ReplyQuote
nix8
 nix8
(@nix8)
New Member
Joined: 2 months ago
Posts: 2
November 8, 2018 12:46 am  
Posted by: nu_ninja

@nix8

Are you using Nvidia? I assume you are from the bumblebee comment. If so check out this thread which seems to give a nicer setup using the proprietary drivers. If not I get the same issue using my amd card and will post a build guide with a plug and play solution soon when I have time.

Yep, I have a 1080 inside a Sonnet Breakaway Box 650, using the nvidia drivers on Arch Linux. I'll check out that thread, thanks. Would love a guide. 🙂

Soon I will add my build link or system & eGPU details to this my signature to give context to my posts


ReplyQuote
nu_ninja
(@nu_ninja)
Trusted Member
Joined: 9 months ago
Posts: 95
November 8, 2018 11:29 pm  

@nix8

Posted my build guide. See Step 4.

Mid-2012 13" Macbook Pro (MacBookPro9,2) TB1 -> RX 460 (AKiTiO Node)
+ macOS 10.14.1+Win10
+ Linux Mint 19


ReplyQuote
(@christopher_herrmann)
New Member
Joined: 9 hours ago
Posts: 1
January 16, 2019 5:44 pm  

Normally I am content with just browsing forums, but at the 10+ hour mark of debugging that is when I will ask for help.

The config file only sort of works for me. Nvidia-smi is showing that my card is being used to run the internal laptop screen but none of my other external monitors are showing any activity. I am on Ubuntu 18.04 with an Asus XG Station. I am using nvidia-415 for my drivers and nvidia-smi shows that my GTX 1070 Ti is recognized. 

That leads me to believe my issue is with my xorg.config file.

Any help would be much appreciated.

This post was modified 9 hours ago

Soon I will add a build link or my system & eGPU details to this my signature to give context to my posts


ReplyQuote
nu_ninja
(@nu_ninja)
Trusted Member
Joined: 9 months ago
Posts: 95
January 16, 2019 6:33 pm  

More info is needed to help figure out what's going on. Could you post the output of xrandr and say what your exact laptop model is?

This post was modified 8 hours ago

Mid-2012 13" Macbook Pro (MacBookPro9,2) TB1 -> RX 460 (AKiTiO Node)
+ macOS 10.14.1+Win10
+ Linux Mint 19


ReplyQuote