Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Redirecting output afterwards
- X-seq: zsh-users 3039
- From: Ville Herva <vherva@xxxxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxxxxxx
- Subject: Redirecting output afterwards
- Date: Thu, 27 Apr 2000 11:20:04 +0300
- Mailing-list: contact zsh-users-help@xxxxxxxxxxxxxx; run by ezmlm
Often I've logged in from another location and then began executing a
large job, say "tar czvf foo /". Later, it turns out that the job will
take hours to complete, and I'll have to log out before that. Of course, I
will then ^Z, bg and disown the job, but I will lose the output. Sometimes
it is essential to know if the job returned errors or warnings. The output
itself is sometimes crucial (du, for example, can take hours in ~70GB data
dir).
Now, if I had been clever enough to realize this when I launched the job,
this would be no problem:
prompt % nohup job
prompt % job >& file &
or even
prompt % screen job
but now the job has already been running for hours, and I wouldn't wan't
to start it all over again just to be able to log out and later see the
result.
What I was thinking is that could something like
prompt % job &
[1] 6643
(after some hours)
prompt % %1 >& output.file # redirect output of a running job
prompt % disown %1
prompt % exit
be possible in theory?
--
"Sillä minä en ole mukava mies, enkä siksi syyttä huou tätä mykistävää
kyynisyyttä ja kaltaiseni luonne vaatii vuosikausien harjoituksen, en ole
mukava mies! Hyväntahtoisuuteni loppuu tähän! Painukaa helvettiin! Niin!
En ole mukava mies! E-en! En ole mukava, En ole mukava mies!" - YUP
Messages sorted by:
Reverse Date,
Date,
Thread,
Author