climateprediction.net (CPDN) home page
Thread 'How do I run BOINC without a parent terminal?'

Thread 'How do I run BOINC without a parent terminal?'

Questions and Answers : Unix/Linux : How do I run BOINC without a parent terminal?
Message board moderation

To post messages, you must log in.

AuthorMessage
hako
Avatar

Send message
Joined: 29 Jun 06
Posts: 3
Credit: 4,077,141
RAC: 0
Message 23431 - Posted: 3 Jul 2006, 3:23:15 UTC

Hi,

This is nothing critical, I just dont like to keep the terminal window open in X.

I tried the command \"sh run_client &\" but it doesn\'t seem to have the effect. When I close the terminal window in X or log off from the tty that I started the process, the client exits. Is there another way to do this?

Thanks,

hako
ID: 23431 · Report as offensive     Reply Quote
USTL-FIL (Lille Fr)

Send message
Joined: 16 Jun 05
Posts: 10
Credit: 20,676,311
RAC: 0
Message 23440 - Posted: 3 Jul 2006, 14:00:36 UTC

Hi,

you can try this:

cd BOINC_DIR;
nohup ./BOINC_BIN >/dev/null 2>&1 &

Mike.
ID: 23440 · Report as offensive     Reply Quote
hako
Avatar

Send message
Joined: 29 Jun 06
Posts: 3
Credit: 4,077,141
RAC: 0
Message 23455 - Posted: 5 Jul 2006, 3:09:35 UTC - in response to Message 23440.  


nohup ./BOINC_BIN >/dev/null 2>&1 &

Thanks,
This worked excellently. May I ask two questions though?

  • I read about nohup command but could not understand the argument you used. Would you be so kind to explain what \">/dev/null 2>&1\" argument does?
  • Is there a way that I can start the client this way with liest processor priority (nice +19)?


Thanks again in advance.
hako


ID: 23455 · Report as offensive     Reply Quote
old_user29115

Send message
Joined: 9 Nov 04
Posts: 1
Credit: 20,896
RAC: 0
Message 26171 - Posted: 19 Jan 2007, 6:53:11 UTC

>/dev/null sends all the output that would normally be shown on the terminal screen to a linux version of \'nowhere\'.

The ampersands release the terminal from the job (works with any command so you can carry on using the terminal after the job has run). Not sure about the 2>&1.
ID: 26171 · Report as offensive     Reply Quote
Romeo Mikulić

Send message
Joined: 17 Dec 04
Posts: 2
Credit: 1,161,971
RAC: 572
Message 26185 - Posted: 19 Jan 2007, 18:52:26 UTC - in response to Message 26171.  

Not sure about the 2>&1.


\"2>&1\" expression redirects standard error to standard output, and since the latter has already been redirected to nothing (/dev/null) with the previous statement (>/dev/null), that makes both standard output and error redirected into nothingness :) (and your terminal screen free of any messages). The same thing can be accomplished with a single expression (they can both be redirected into nothingness): &>/dev/null
If you wanna know more:
\"man bash\"
\"REDIRECTION\" paragraph
ID: 26185 · Report as offensive     Reply Quote

Questions and Answers : Unix/Linux : How do I run BOINC without a parent terminal?

©2024 cpdn.org