Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] stdin/stderr redirection under Solaris



Hi
maybe I`m missing something


--- Jean-Christian Imbeault
<jean-christian.imbeault@example.com> wrote:

> Gerald Naughton wrote:
> >
> >  The nohup command accepts just one utility as an
> > argument.
> > To apply nohup to a pipeline or list of commands,
> > enter the
> > pipeline or list in a	shell script file.  Then run
> > sh as utility using the following format:
> >
> > nohup	sh -c file
> 
> I thought about that but when I tried the process
> was still attached to 
> the console, and stderr was redirected to nohup.out.
> I guess I could 
> live with nohup high jacking stderr and just pipe
> that (?), as long as 
> stdout id being pipe separately?
> 
> bash-2.03$ cat t.sh
> (ls -R / | /usr/local/sbin/cronolog
> logs/%Y/%m/%d/stdout.log) |& 
> /usr/local/sbin/cronolog logs/%Y/%m/%d/stderr.log
> bash-2.03$ nohup sh -c t.sh
> Sending output to nohup.out
> ^Cbash-2.03$
> bash-2.03$ cat nohup.out
> /lost+found: Permission denied
> /proc/0: Permission denied
> /proc/1: Permission denied
> [...]

Why don`t you try
nohup  ls -l / ttt  2> errfile | wc -l 


Dump the Stderr into a Temporary File

It depends on what you want to do

I tried the above Linux and no problem

g



		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
http://promotions.yahoo.com/new_mail 


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links