What did I do to make BOINC restart my app?

Message boards : API : What did I do to make BOINC restart my app?
Message board moderation

To post messages, you must log in.

AuthorMessage
Ken_g6

Send message
Joined: 29 May 07
Posts: 11
Message 34302 - Posted: 21 Aug 2010, 16:09:02 UTC
Last modified: 21 Aug 2010, 16:23:48 UTC

Hi,

Since I last posted here, I've managed to make a couple of BOINC applications for PrimeGrid. They're both single-threaded now, so don't worry about that. But one of them, a CUDA app, is doing strange things in some cases.

Here's the main problem (that I'm asking about here): The app completes, apparently successfully, but then for some reason BOINC restarts it. Also, although the app ran for ~10 CPU-seconds at a time four times (that's normal for CUDA apps), BOINC recorded 0 seconds of runtime.

After that last fprintf, I do only two things. First, I re-raise any SIGINT, SIGTERM, or SIGHUP that the process may have received. And second I call boinc_finish, with the argument EXIT_SUCCESS as evidenced by another line in that result.

So why did BOINC restart my app? And why didn't it count any of the runtime? Should I not re-raise those signals? I built the app with the development files that came with Ubuntu 9.04: version 6.2.18-3ubuntu1. Is that too old? Any other ideas?

Thanks!

Edit: I should add that there are also cases where the app restarts on failure. Here's one. The reason for failure isn't relevant here (trying to run on the CUDA emulator.) The fact that it tried it again, after once calling boinc_finish(1), is. Plus, there are no signals trapped on that path.
ID: 34302 · Report as offensive
Profile Jord
Volunteer tester
Help desk expert
Avatar

Send message
Joined: 29 Aug 05
Posts: 15477
Netherlands
Message 34304 - Posted: 21 Aug 2010, 16:54:38 UTC - in response to Message 34302.  

To get a quicker answer, you better email the BOINC Development or BOINC projects email list (lists). Then add the complete stderr.txt output to the email, as those outputs don't stay long on the PG server.
ID: 34304 · Report as offensive
Ken_g6

Send message
Joined: 29 May 07
Posts: 11
Message 34317 - Posted: 22 Aug 2010, 19:45:04 UTC

By the way, I solved it: I'd made a bad Makefile and hadn't #defined USE_BOINC, so the code was ending with exit(0) instead of boinc_finish(0).
ID: 34317 · Report as offensive
Profile Jord
Volunteer tester
Help desk expert
Avatar

Send message
Joined: 29 Aug 05
Posts: 15477
Netherlands
Message 34319 - Posted: 22 Aug 2010, 20:52:59 UTC - in response to Message 34317.  

I saw that. Congratulations. :-)
ID: 34319 · Report as offensive

Message boards : API : What did I do to make BOINC restart my app?

Copyright © 2024 University of California.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.