[buug] tee command hanging

Ian Zimmerman itz at speakeasy.org
Thu Jul 25 07:16:51 PDT 2002

Nick> I'm attempting to use 'tee' within a wrapper script to log
Nick> stdout & stderr to a file. Specifically it executes the
Nick> following:

Nick> 	command args 2>&1 | tee <logfile>

Nick> However we have dsicovered that for certain 3rd-party commands
Nick> (i.e.  executables) that the tee hangs and requires the operator
Nick> to <control-C> to complete the command, e.g.

Nick> ndunphy at bandon% mskstart cdsp 2>&1 | tee nick
Nick> # Warning: Starting framework module cdsp ...

Nick> # Done
Nick> <hanging here>
Nick> ^Cndunphy at bandon%

Are you so sure tee is to blame here?  What happens in these cases:

1/ mskstart cdsp >nick 2>&1

2/ script nick ; mskstart cdsp

3/ run under a real shell (bash/ash/ksh)

btw, do we know you?

Ian Zimmerman, Oakland, California, U.S.A.
GPG: 433BA087  9C0F 194F 203A 63F7 B1B8  6E5A 8CA3 27DB 433B A087
EngSoc adopts market economy: cheap is wasteful, efficient is expensive.

More information about the buug mailing list