Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cu -l /dev/ttyXX Run in Background

Status
Not open for further replies.

bgarlock

MIS
Jan 23, 2002
173
US
I am trying to setup logging on a serial port that a Router is connected to. I can use cu to accomplish this, but I would like to have it run in the background, and keep getting this message:

cu -l /dev/ttyD015 1>>/var/log/router.log &

[1]+ Stopped (tty output) cu -l /dev/ttyD015 >>/var/log/router.log

Running in the foreground works fine, and logs everything the way I need it, but I'd like to wrap this in an init script, so it is started upon boot.

Thanks for any suggestions.

Bruce Garlock
bruceg@tiac.net
 
I found a soltion to my problem. I need to specify the -tostop parameter to stty. Here is a command that works for me:

(stty -tostop) |cu -l /dev/ttyD015 1>>/var/log/router.log &

I now can log all messages from my router to a file, for further examination. Bruce Garlock
bruceg@tiac.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top