Re: "nohup rsync ... >my.log &2>1" does not work
- From: Tobias Nissen <tn@xxxxxxx>
- Date: Mon, 19 May 2008 21:57:57 +0200
Matthew Lincoln wrote:
I logged in through a command shell on a Linux system and entered a
command:
nohup rsync ... >my.log &2>1
First of all: You mean 2>&1, right?
I expected that after the command issue the command prompt
ml@server [/]#
gets visible again.
But the ssh terminal is blocked as if I would have NOT entered
"nohup".
Why is the rsync command still running in foreground although I
prepended the command with "nohup" ?
Do you use the GNU version of hangup or something your shell has
builtin? The behaviour of GNU's hangup is not to spawn a seperate
process, but I don't know about the other implementations.
If you explicitly want to spawn a process, do so:
nohup rsync ... &
Recognize the ampersand at the end of the rsync-command.
Also, your redirection >my.log 2>&1 won't work as expected, because
nohup writes output to a file named 'nohup.out'.
Instead of nohup, you can also use screen with its detach and reattach
features.
.
- Follow-Ups:
- Re: "nohup rsync ... >my.log &2>1" does not work
- From: blmblm
- Re: "nohup rsync ... >my.log &2>1" does not work
- Prev by Date: Re: turn off 1-click open in Konqueror?
- Next by Date: Re: RS232 open souce code API for C++?
- Previous by thread: Re: "nohup rsync ... >my.log &2>1" does not work
- Next by thread: Re: "nohup rsync ... >my.log &2>1" does not work
- Index(es):
Relevant Pages
|