Get work, Do work then Shutdown?

Message boards : Questions and problems : Get work, Do work then Shutdown?
Message board moderation

To post messages, you must log in.

AuthorMessage
Yamanipanuchi

Send message
Joined: 14 Aug 12
Posts: 8
United States
Message 45273 - Posted: 14 Aug 2012, 18:36:07 UTC

I've searched for something similar to this, No luck.

I wanted to know if there is a way where you can setup a system to get X amount of work, Process it and then shutdown?

The idea is that I want to setup a PC to process work but I do not want to leave it on continuously but I also want it to finish its current work. So I want to be able to just hit the power button every once and while and just let it go. When its done it shuts itself off eliminating the power usage automatically.

Anyone out there attempt this, Or know how it can be done?
ID: 45273 · Report as offensive
Profile Jord
Volunteer tester
Help desk expert
Avatar

Send message
Joined: 29 Aug 05
Posts: 15483
Netherlands
Message 45276 - Posted: 14 Aug 2012, 19:56:33 UTC - in response to Message 45273.  

Check the command line options for the BOINC binary.
Things as:

--exit_after_app_start N
Exit N seconds after an application starts.

--exit_after_finish
Exit right after finishing a job.

--exit_before_start
Exit right before starting a job.

--exit_before_upload
Exit right before starting an upload.

--exit_when_idle
Exit when there are no tasks.

--fetch_minimal_work
Get only one task per CPU core or GPU.

In this case you best run with boinc.exe --fetch_minimal_work --exit_after_finish
This will get one task per CPU core/GPU, run it and when the task has finished, exit BOINC.
ID: 45276 · Report as offensive
Yamanipanuchi

Send message
Joined: 14 Aug 12
Posts: 8
United States
Message 45278 - Posted: 14 Aug 2012, 20:26:14 UTC - in response to Message 45276.  

Hmm that actually will probably work! I just have to figure out how to shut the PC down, but that cant be to hard.

I think I can actually put that right into the service itself...

ID: 45278 · Report as offensive
Yamanipanuchi

Send message
Joined: 14 Aug 12
Posts: 8
United States
Message 45286 - Posted: 15 Aug 2012, 18:58:47 UTC - in response to Message 45278.  

I see that you have to put these values into the cc_config.xml.
ID: 45286 · Report as offensive
Profile Jord
Volunteer tester
Help desk expert
Avatar

Send message
Joined: 29 Aug 05
Posts: 15483
Netherlands
Message 45290 - Posted: 15 Aug 2012, 20:52:55 UTC - in response to Message 45286.  

No, these are switches for use after the BOINC binary, so you can start BOINC with them.
The <exit_after_finish/> and <fetch_minimal_work/> flags can be used from a cc_config.xml, but it's not necessary to do so.

See this BOINC FAQ for all command line switches.
ID: 45290 · Report as offensive
Yamanipanuchi

Send message
Joined: 14 Aug 12
Posts: 8
United States
Message 45302 - Posted: 16 Aug 2012, 13:52:41 UTC - in response to Message 45290.  

Where would you put these switches in. Last I messed with Boinc it was ran as a service. I'm running a few Windows 7 machines and I do not see a service for the software.
ID: 45302 · Report as offensive
BilBg
Avatar

Send message
Joined: 18 Jun 10
Posts: 73
Bulgaria
Message 45308 - Posted: 16 Aug 2012, 19:11:18 UTC - in response to Message 45302.  

Where would you put these switches in.

As for any other program that uses command line switches:

Make shortcut (.lnk) for boinc.exe
Edit shortcut (Properties) and put the command line switches at the end of the line, e.g.:
"C:\Program Files\boinc.exe" --fetch_minimal_work --exit_after_finish --detach

(You can also use .bat/.cmd file)





- ALF - "Find out what you don't do well ..... then don't do it!" :)
ID: 45308 · Report as offensive

Message boards : Questions and problems : Get work, Do work then Shutdown?

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.