Re: nohup and xargs?
- From: Dan Stromberg <dstromberglists@xxxxxxxxx>
- Date: Mon, 30 Jun 2008 00:58:43 GMT
On Sun, 29 Jun 2008 06:58:38 -0700, howa wrote:
Hello,
How to combine nohup and xargs together?
Conside I have a simple perl program, which take a string as input
E.g.
test.pl foo
I have a file contains all the input to be run, so I use xargs,
E.g
cat input.txt | xargs ... test.pl
It run well, but I want to run in background and not affected by ssh
exit,
I tried to use nohup,
E.g.
nohup cat input.txt | xargs ... test.pl
However, when I end the ssh, the program did not continue to run...
any idea?
Thanks.
I believe nohup wants to see a simple command.
You'll probably get what you want by doing something like:
echo 'cat input.txt | xargs ... test.pl" > /tmp/cmd
chmod 755 /tmp/cmd
nohup /tmp/cmd
....or just run it under screen instead of using nohup - that's probably
easier. You can detach from a screen session with ^Ad. Then you can re-
attach later with screen -r, and see what your command did. It should be
sitting there waiting at a command prompt after the command finishes, as
though you'd been connected the whole time.
.
- References:
- nohup and xargs?
- From: howa
- nohup and xargs?
- Prev by Date: Re: What Linux distro to use for old Intel machine, that fits on CDs?
- Next by Date: Re: directory data structure
- Previous by thread: nohup and xargs?
- Next by thread: Re: The Tocquevillian philosophy
- Index(es):
Relevant Pages
|