Glynn Clements wrote:

> Sebastian Helms wrote:
>
> > Using SuSE 6.1, I want to run "expect fetch" every 2 hours by cron. This
> > expect script runs wvdial, waits for the connection, runs fetchmail and
> > sendmail -q and hangs up.
> >
> > When starting "expect fetch" manually, it all works fine. But when run by
> > cron, I get the following error message:
> >
> > spawn wvdial
> > failed to get controlling terminal using TIOCSCTTYparent sync byte write:
> > broken pipe
> >
> > I have no clue what this means. Any ideas ?
>
> Something is complaining about the fact that it doesn't have a
> controlling terminal (when run manually, it will inherit the shell's
> controlling terminal, but not when run from cron). Examine your expect
> script for possible errors.
>
> > I know some things: wvdial writes to stderr, but calling "wvdial 2>&1"
> > doesn't work as wvdial takes 2>&1 as an option.
>
> Not if it's run from a shell, it won't. It's the shell that handles
> the '2>&1' bit. You can't just use shell constructs wherever you feel
> like it and expect them to work.
>
> --
> Glynn Clements <[EMAIL PROTECTED]>
>
> -====---====---====---====---====---====---====---====---====---====---====-
>  to unsubscribe email "unsubscribe linux-admin" to [EMAIL PROTECTED]
>  See the linux-admin FAQ: http://www.kalug.lug.net/linux-admin-FAQ/


Reply via email to