Using multiple gpus linux

Currently using Aurora Linux, would be willing to switch to anything but the ubuntu, vanilla fedora, bazzite are pretty much behaving the same way.

I am trying to use multiple GPUs, the iGPU and an eGPU. the eGPU through USB4 (although I have a riser cable to plug it directly and a way to provide external power). Drivers are up i can se the card on the system The issue that is driving me nuts is that the nvidia card is showing up as GPU0 always; regardless of any kernel parameter, hard coding paths, udev rules, that I could think to change so that it is listed as GPU1.

My issue is that I dont want to add a launch parameter to every app. I want ALL of the system to use the iGPU except for 1 container.

suggestions? (thanks in advance)

I don’t have an answer to your problem, but I would be interested in hearing how you’re getting on with your eGPU. Are you using it for graphics or AI compute?

I use it for compute. Mostly playing around with machine learning.

I still have not solved it. Seems in general multiple GPUs in linux is still a mess. Seems KDE and wayland are working on it.

I read here in the framework community someone used the GPU pcie address instead of the GPU position in the env variables to achieve a similar behavior I have not tried it yet.

Even through USB4 and addings several seconds of model loading some tasks just run much faster on nvidia. Mind you, im not using a ‘good’ GPU, it is an RTX 3060 12GB.

So currently I run most things on the iGPU except for those rare instances where the Nvidia does give me significantly better times and does not require more than 12GB of vram.

Once I test a few more things I will post what did work and what didn’t.

1 Like

I’ll be interested to see what you find. I think I’ll order a FW Desktop in a few weeks. After a fair bit of research, I am expecting the unified arch to produce better reasoning that than an eGPU, just on the basis that more advanced models will fit in 60-80GB of VRAM. I think your card will run much faster, but at the cost of only being able to fit a smaller model; you’ll be trading reasoning for speed.

But if you can find an inference task that is parallelisable, of course you could run both GPUs at the same time.

You are absolutely correct. It is only in some very niche cases i still use the egpu. For almost everything i use the igpu.

Im happy with the desktop. If you do AI workloads it is one useful little machine.

Adding a note to this thread: I had not appreciated previously that the USB4 interface should outperform the PCIe interface by a significant margin. Thus, I am hoping there are no issues in getting the two GPUs working happily in Linux at the same time.

Hopefully I will get to try it myself, though I want to be experimenting with AI, not fighting driver-level issues :face_with_tongue: