Oracle Solaris System Administration (MOSC)

MOSC Banner

script command lacks the -c flag

edited Dec 8, 2011 8:06AM in Oracle Solaris System Administration (MOSC) 2 commentsAnswered
I'm writing a cross-platform wrapper for an interactive perl script. Linux, Solaris 8 and 10. We need to be able to log everything shown on the screen to a text file.
The perl script is menu-driven with refreshes, colors, etc. so we can't use tee. In Linux we use script -c but Solaris lacks the -c flag. I tried a here doc with script but this is what I got:
bash-2.03$ script /tmp/deleteme.txt.scr << EOF
> who
> EOF
Script started, file is /tmp/deleteme.txt.scr
Script done, file is /tmp/deleteme.txt.scr
Bad address

We might be able to use the screen command, but do you know a way to get script working? Any other apps which could do the job?

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center