linux:egpu

This is an old revision of the document!


Legacy data. I used this in the past but it is not very useful today. If I had to do it again nowadays, I would go into it with an LLM. This page will probably be retired in the near future.

Razer Core X eGPU

Updated procedure for Linux Mint 22 and eGPU running Nvidia GTX 1060 6GB

Thunderbolt (TB3/TB4) is explicitly designed for hot-plugging.

It uses :

  • Hot-plug–safe PCIe tunneling
  • Overcurrent protection
  • Digital handshaking before enabling high-power lanes
  • Cable and device negotiation before link-up
  • Mandatory protective circuitry required by Intel’s TB certification

You are supposed to plug and unplug TB devices while the system is powered — that’s how eGPUs, docks, displays, and drives are meant to work.

There is no scenario in which hot-plugging a functioning Thunderbolt cable damages the hardware.

- Power on laptop normally
- Log into desktop
- Turn ON the eGPU enclosure
- Wait 2–3 seconds (GPU initializes)
- Plug in the Thunderbolt cable
- Wait for the OS to detect/authorize the eGPU
- Close any apps using the eGPU (optional but safer)
- Save your work
- Unplug the Thunderbolt cable
- Wait 2–3 seconds
- Power OFF the eGPU enclosure if desired

Note: On older Thunderbolt 3 laptops (e.g. 2017 Razer Blade Stealth), the eGPU must be plugged after boot, otherwise the system may hang during startup.

sudo apt install bolt thunderbolt-tools

Ensure the bolt service is running:

systemctl status bolt
lspci | grep -i thunderbolt
lsmod | grep thunderbolt

Expected:

  • Intel Thunderbolt controller listed
  • thunderbolt kernel module loaded

In BIOS:

  • Thunderbolt: Enabled
  • Security Level: No Security (SL0)

⚠️ Simplest option, and may be needed on this BIOS if devices do not enumerate under Linux. SL0 disables DMA protection: with bolt installed (step 1), user authorization (SL1) can work too.

Boot the laptop without the eGPU connected.

Then:

  • Power ON the Core X
  • Plug the Thunderbolt cable

Check detection:

boltctl list

If needed:

sudo boltctl authorize <UUID>

Verify PCIe device:

lspci | grep -i nvidia

Install the driver flagged recommended in Driver Manager. For the GTX 1060 that is the 580 branch, the last one to support it:

sudo apt install nvidia-driver-580

⚠️ Do NOT use NVIDIA .run installer (breaks package management and updates)

Only if nouveau still loads, as the nvidia-driver-* packages already blacklist it. Check with:

lsmod | grep nouveau

If it is listed:

echo "blacklist nouveau" | sudo tee /etc/modprobe.d/blacklist-nouveau.conf
echo "options nouveau modeset=0" | sudo tee -a /etc/modprobe.d/blacklist-nouveau.conf
sudo update-initramfs -u

Reboot (without eGPU connected).

Linux Mint 22 does not provide prime-run by default.

Create it manually:

sudo nano /usr/local/bin/prime-run

Content:

#!/ bin / sh
__NV_PRIME_RENDER_OFFLOAD=1 \
__GLX_VENDOR_LIBRARY_NAME=nvidia \
__VK_LAYER_NV_optimus=NVIDIA_only \
__NV_PRIME_RENDER_OFFLOAD_PROVIDER=NVIDIA-G0 \
exec "$@"

Make executable:

sudo chmod +x /usr/local/bin/prime-run

Connect the eGPU after boot, then run:

nvidia-smi

You should see the GTX 1060 listed.

Test offloading (glxinfo needs the mesa-utils package):

prime-run glxinfo | grep "OpenGL renderer"

Run applications on the eGPU:

prime-run <application>

Example:

prime-run blender
prime-run steam
  • Laptop must boot without eGPU connected (known limitation on this hardware)
  • eGPU must be hot-plugged after login
  • Internal display introduces a ~20–30% performance penalty (PCIe copy-back)
  • External monitor connected to the GPU removes this penalty completely
  • Cycles rendering (Blender) is not affected by this limitation
  • linux/egpu.1793482437.txt.gz
  • Last modified: 2026/10/31 22:33
  • by claude