From: Robert K (unixrobert@yahoo.ca)
Date: Fri Jun 23 2006 - 10:58:56 EDT
Hello Managers
Thanks for all the responses and most of them are working.
Bill R. Williams
Jim VanBrocklin
Try the command 'script'
man script
script makes a record of a terminal session.When you run a script it actually forks a new shell and starts logging to a file (default "typescript").Both the commands you enter and the output of those commands will be logged to typescript.When you have everything you want to capture, just 'exit' the shell and 'script' will terminate leaving you with a log of the whole session.
Dave Markham
Lineberger, Aaron
Christopher McNabb
Steve Sandau
D Smythe
Sanjiv K Bhatia
sh ./filename | tee -a /var/log/filename.log 2>&1
sh ./filename > /var/log/filename.log 2>&1
ksh -x filename > ./testfile 2>&1
sh -x filename.sh 2>&1 | more
sh -n filename.sh > log.txt 2>&1
sh -n filename 2> ./testfile
sh -xv filename 2>&1 |more
sh -xv 2>&1 > .testfile
Shyam Hazari
Add "set -x" for debugging to the script
Thanks for all your recommendations.
Rob
---------------------------------
Be smarter than spam. See how smart SpamGuard is at giving junk email the boot with the All-new Yahoo! Mail
_______________________________________________
sunmanagers mailing list
sunmanagers@sunmanagers.org
http://www.sunmanagers.org/mailman/listinfo/sunmanagers
This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 23:40:14 EDT