Advanced search

Message boards : Graphics cards (GPUs) : GPU sometimes not recognized after Linux boot

Author Message
Greg Beach
Avatar
Send message
Joined: 5 Jul 10
Posts: 21
Credit: 50,844,220
RAC: 0
Level
Thr
Scientific publications
watwatwatwatwatwatwatwat
Message 20516 - Posted: 25 Feb 2011 | 20:26:14 UTC

I've noticed that sometimes BOINC does not recognize my GPU after a reboot until I manually restart the BOINC client. It had to do with the BOINC client starting before the X server.

To solve this I added the following to my /etc/rc.d/rc.local:

echo "service boinc-client restart" | at now + 1 minutes

If someone has a better/different solution I'd be interested in seeing it.

Greg

Profile skgiven
Volunteer moderator
Volunteer tester
Avatar
Send message
Joined: 23 Apr 09
Posts: 3968
Credit: 1,995,359,260
RAC: 0
Level
His
Scientific publications
watwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwat
Message 20517 - Posted: 25 Feb 2011 | 21:04:43 UTC - in response to Message 20516.
Last modified: 25 Feb 2011 | 21:06:02 UTC

Add the line,

<start_delay>30</start_delay>

to the cc_config.xml file (or create the cc_config.xml file and add the line if you have to).

A possible alternative for some Fedora systems with network driver not loading fast enough (but might also work here, as it forces a delay).

Add the line NETWORKWAIT=yes to /etc/sysconfig/network to delay system startup for 10 seconds or until a network connection is up.

From http://boinc.berkeley.edu/wiki/Network_related_problems

Richard Haselgrove
Send message
Joined: 11 Jul 09
Posts: 1434
Credit: 3,542,634,351
RAC: 398,572
Level
Arg
Scientific publications
watwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwatwat
Message 20518 - Posted: 25 Feb 2011 | 21:40:40 UTC - in response to Message 20517.
Last modified: 25 Feb 2011 | 21:41:17 UTC

Add the line,

<start_delay>30</start_delay>

to the cc_config.xml file (or create the cc_config.xml file and add the line if you have to).

That won't help, I'm afraid.

As documented in client configuration, that tag inserts a delay before "running applications after client startup."

As greg notes, the requirement is for BOINC (the "client") to recognise the GPU at startup, by querying the already-started driver. If BOINC fails to detect the GPU, no amount of additional delay after the event will help: the science applications with still be running in a GPU-free environment.

Your second suggestion stands a better chance of success, depending on the load order of network drivers and the X server.

Lem Novantotto
Send message
Joined: 11 Feb 11
Posts: 18
Credit: 377,139
RAC: 0
Level

Scientific publications
watwatwatwatwat
Message 20521 - Posted: 25 Feb 2011 | 23:08:42 UTC - in response to Message 20516.

With Ubuntu I solved changing the /etc/init.d/boinc-client starting prefix to 98.

# update-rc.d -f boinc-client remove
# update-rc.d boinc-client defaults 98 02

I don't know which is the proper command for Fedora, though.

Bye.


Greg Beach
Avatar
Send message
Joined: 5 Jul 10
Posts: 21
Credit: 50,844,220
RAC: 0
Level
Thr
Scientific publications
watwatwatwatwatwatwatwat
Message 20523 - Posted: 26 Feb 2011 | 1:46:45 UTC - in response to Message 20521.

With Ubuntu I solved changing the /etc/init.d/boinc-client starting prefix to 98.

# update-rc.d -f boinc-client remove
# update-rc.d boinc-client defaults 98 02

I don't know which is the proper command for Fedora, though.

Bye.

In Fedora an init script can recommend it's own settings by including a chkconfig directive in the script itself. The Fedora provided BOINC client script has the line:

# chkconfig: - 98 02

which means that the script will be started at all runlevels ("-"), it's start order is 98 and the stop order is 02.

If you make any changes to the chkconfig value in the script you run:

chkconfig boinc-client resetpriorities

As you can see the BOINC client install from the Fedora repository already sets it up as start order 98 but depending on the services that are installed on a given system there may or may not be a problem.

However, if, as you suggest, changing the start order corrects the problem then I think that's preferable.

Greg Beach
Avatar
Send message
Joined: 5 Jul 10
Posts: 21
Credit: 50,844,220
RAC: 0
Level
Thr
Scientific publications
watwatwatwatwatwatwatwat
Message 20524 - Posted: 26 Feb 2011 | 1:54:47 UTC - in response to Message 20517.

Add the line,
<start_delay>30</start_delay>

to the cc_config.xml file (or create the cc_config.xml file and add the line if you have to).

A possible alternative for some Fedora systems with network driver not loading fast enough (but might also work here, as it forces a delay).

Add the line NETWORKWAIT=yes to /etc/sysconfig/network to delay system startup for 10 seconds or until a network connection is up.

From http://boinc.berkeley.edu/wiki/Network_related_problems

I did try that originally and it didn't correct the problem.

And to be clear, it has nothing to do with the network driver. It's the X Window server loading after the BOINC client has started that causes the problem.

Lem Novantotto
Send message
Joined: 11 Feb 11
Posts: 18
Credit: 377,139
RAC: 0
Level

Scientific publications
watwatwatwatwat
Message 20526 - Posted: 26 Feb 2011 | 8:51:37 UTC - in response to Message 20523.

The Fedora provided BOINC client script has the line:

# chkconfig: - 98 02

which means that the script will be started at all runlevels ("-"), it's start order is 98 and the stop order is 02.


All runlevels? So even at S (single user from boot, 1 in Fedora)? This is clearly wrong, and is the cause of the "GPU not recognized" problem.
In Ubuntu I start it at 2345 and stop it at 601.
In Fedora I'd suggest to start it just at 5.

Bye.

Greg Beach
Avatar
Send message
Joined: 5 Jul 10
Posts: 21
Credit: 50,844,220
RAC: 0
Level
Thr
Scientific publications
watwatwatwatwatwatwatwat
Message 20539 - Posted: 28 Feb 2011 | 16:06:33 UTC - in response to Message 20526.

All runlevels? So even at S (single user from boot, 1 in Fedora)? This is clearly wrong, and is the cause of the "GPU not recognized" problem.
In Ubuntu I start it at 2345 and stop it at 601.
In Fedora I'd suggest to start it just at 5.

Bye.

I looked at the actual levels it was running at and it was only running at 3, 4 and 5. So even though the script indicated that it could run at all levels Fedora didn't run it at levels 1 and 2.

After your suggestion of only runlevel 5 I dropped runlevels 3 and 4 rebooting after each and the only way to get boinc-client to start on Fedora and properly recognize the GPU is to ONLY start at runlevel 5.

Thanks for your help Lev.

Greg Beach
Avatar
Send message
Joined: 5 Jul 10
Posts: 21
Credit: 50,844,220
RAC: 0
Level
Thr
Scientific publications
watwatwatwatwatwatwatwat
Message 20540 - Posted: 28 Feb 2011 | 16:13:41 UTC

I can't edit my original post so I hope people will read this far down. Thanks to Lem Novantotto the preferred solution is to only run the BOINC client at runlevel 5. On Fedora run the following command to correct the runlevel and reboot:

sudo chkconfig --level 1234 boinc-client off

If for some reason this still doesn't work then I guess my original solution would still work.

Lem Novantotto
Send message
Joined: 11 Feb 11
Posts: 18
Credit: 377,139
RAC: 0
Level

Scientific publications
watwatwatwatwat
Message 20545 - Posted: 28 Feb 2011 | 18:01:03 UTC - in response to Message 20540.

I can't edit my original post so I hope people will read this far down. Thanks to Lem Novantotto the preferred solution is to only run the BOINC client at runlevel 5. On Fedora run the following command to correct the runlevel and reboot:

sudo chkconfig --level 1234 boinc-client off

If for some reason this still doesn't work then I guess my original solution would still work.


You're welcome, but there's no need to thank me. :)

It's clear you're doing a very good job with Fedora: I cannot be of much help, because I really never used neither that distro nor RedHat nor CentOS. Besides, my skills are poor and I haven't got much spare time.

However if we can help each other, get smoother crunching and gain better performance, of course that's good for the sake of the project. :)

Bye.

Post to thread

Message boards : Graphics cards (GPUs) : GPU sometimes not recognized after Linux boot

//