Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Two Graphic cards: one for X and one for GPU computing

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
User avatar
larry77
Posts: 582
Joined: 2006-09-24 17:59
Has thanked: 6 times
Been thanked: 1 time

Two Graphic cards: one for X and one for GPU computing

#1 Post by larry77 »

Dear All,
I run debian stable on my box with the liquorix kernel and I have the nouveau driver installed.
I have a seasoned nvidia card which works without a glitch (just to watch movies, no gaming or computing).
I would like to buy a second, more powerful nvidia card for computing.
Is it complicated to set up the following: use the old card for the desktop graphical environment and the new one for computing only?
I found some tutorials onlines, but they are all a bit seasoned and things may have changed in the last 2-3 years.
Any suggestion is welcome
Thanks!

User avatar
ruwolf
Posts: 623
Joined: 2008-02-18 05:04
Location: Banovce nad Bebravou
Has thanked: 35 times
Been thanked: 26 times

Re: Two Graphic cards: one for X and one for GPU computing

#2 Post by ruwolf »

In my opinion, it should work, because you can specify used card in xorg.conf by BusID.

User avatar
larry77
Posts: 582
Joined: 2006-09-24 17:59
Has thanked: 6 times
Been thanked: 1 time

Re: Two Graphic cards: one for X and one for GPU computing

#3 Post by larry77 »

Thanks. Can you point me to a recent example/tutorial?

User avatar
ruwolf
Posts: 623
Joined: 2008-02-18 05:04
Location: Banovce nad Bebravou
Has thanked: 35 times
Been thanked: 26 times

Re: Two Graphic cards: one for X and one for GPU computing

#4 Post by ruwolf »

I think, you can understand it e.g from this pseudo-bug report and solution:
bugs.FreeDesktop.org: BusID disregarded in xorg.conf in dual graphics card and single monitor setup
As you see, BusID in xorg.conf differs a bit from denoting in Xorg.0.log (different order and separator):
The format is assumed to be "bus@domain:device:func", where domain bus, device and func are decimal integers. domain and func may be omitted and assumed to be zero, although doing this isn't encouraged.
So, what is in Xorg.0.log specified as

Code: Select all

PCI: (1:6:0:0)
it is in xorg.conf specified as

Code: Select all

BusID	"PCI:6@1:0:0"

User avatar
larry77
Posts: 582
Joined: 2006-09-24 17:59
Has thanked: 6 times
Been thanked: 1 time

Re: Two Graphic cards: one for X and one for GPU computing

#5 Post by larry77 »

Thanks again.
As soon as I get the card, I will cross my fingers and give it a go.
Have a nice weekend.

CwF
Global Moderator
Global Moderator
Posts: 2636
Joined: 2018-06-20 15:16
Location: Colorado
Has thanked: 41 times
Been thanked: 192 times

Re: Two Graphic cards: one for X and one for GPU computing

#6 Post by CwF »

Similar, resist creating a master xorg.conf:
http://forums.debian.net/viewtopic.php? ... le#p721672

Will the "gpu compute" component be requiring Nvidia drivers? Cuda is not supported by nouveau.

User avatar
larry77
Posts: 582
Joined: 2006-09-24 17:59
Has thanked: 6 times
Been thanked: 1 time

Re: Two Graphic cards: one for X and one for GPU computing

#7 Post by larry77 »

Hello,
For what I have in mind, I see no way to avoid installing nvidia-driver.
I plan to use that in combination with the liquorix kernel.
I had horrible experiences with nvidia drivers in the past, but it looks like a necessary evil.
Also, I am waiting for a gtx 1070 8GB. It is a reasonable card in my budget. The idea is to be able to prototype stuff on my home workstation and deploy somewhere else.
Wish me good luck!

CwF
Global Moderator
Global Moderator
Posts: 2636
Joined: 2018-06-20 15:16
Location: Colorado
Has thanked: 41 times
Been thanked: 192 times

Re: Two Graphic cards: one for X and one for GPU computing

#8 Post by CwF »

larry77 wrote: I see no way to avoid installing nvidia-driver.
maybe not...
In an area I've been playing, I suggest it might be possible to use both drivers.
This would depend on how nice the nvidia driver is and a failure would be the nividia drivers fault, file the bug with them.

Anyway, my guess is to install the nvidia driver, remove any nouveau blacklist, and delete any generated xorg.conf. The theory from there is the machine boots up on the first seen (bios boot gpu) and loads nouveau and works fine. With no declarations on what to do with the secondary card the system should ignore it, but you should find it also bound to nouveau.

Checkpoint - no idea if nvidia's packages will allow this? They should.

Now we unbind the secondary card from nouveau and rebind it to nvidia. I'll be lazy and not correct the following, but it gives the idea. directory would be 'nvidia' or 'nouveau' and the addresses and pcid's according to your hardware.

Code: Select all

echo "10de 1380" > /sys/bus/pci/drivers/nvidia/new_id
echo "0000:04:00.0" > /sys/bus/pci/devices/0000:04:00.1/driver/unbind
echo "0000:04:00.0" > /sys/bus/pci/drivers/nvidia/bind
echo "10de 1380" > /sys/bus/pci/drivers/nvidia/remove_id
Checkpoint - should work out without affecting the primary card and it's desktop. Did it blow up?
I assume the cuda stuff doesn't need interaction with xorg and actually does not run an independent display. If that is the case then there is no need for any declarations for xorg concerning the secondary card. Maybe...

Obviously the nvidia package could object, no idea. IF this works up to this point then it is up to whatever packages you run to have the sense to not error on sensing a nouveau in the system and stopping, and/or being able to be directed to the right hardware, maybe finding it itself, maybe... The 4:00.1 audio subsystem might need attention too? ? Unbind it and let it float in limbo?

I have a dual nvidia and might get to this in 6 months and a day. Code for not likely. So I'm guessing, nouveau and radeon are graceful with this, amdgpu is mostly nice, no idea with nvidia.

Enjoy!

Post Reply