I use a terminal logging method on my Ubuntu Desktop for the GNOME-terminal (it's good when I use SSH in GNOME-terminal):
Implementation
As root:
apt-get install bsdutilsAs the normal user:
mkdir ~/logsappend this to your
~/.bashrc- must be the last line!STARTTIME=`date +%F-%Hh-%Mm-%Ss-%N`; script -q -t 2> \ /home/USERNAMEHERE/logs/$STARTTIME-timing.txt \ -c 'bash --rcfile /home/USERNAMEHERE/.bashrc-cp' \ -f /home/USERNAMEHERE/logs/$STARTTIME-log.txt; exit 0make sure the 1) is the last line of bashrc, then [this is needed to avoid "fork bomb"..]:
sed -e '$d' /home/USERNAMEHERE/.bashrc > /home/USERNAMEHERE/.bashrc-cp
Replay
Rename the filenames to you're needs! You can only play 1 file at one time.
scriptreplay "/home/USERNAMEHERE/logs/$STARTTIME-timing.txt" \
"/home/USERNAMEHERE/logs/$STARTTIME-log.txt"
With this method I can log steps in ncurses menu, great! It's working perfectly.
Question
I need this great terminal logging method in putty too. How can I do that? (so for ex.: I need to log smitty menus on AIX machines with putty too.)
p.s.: Coul my logging method be better? (Can anyone update it?)