During my work activities, I do a lot of ssh sessions to routers, switches, servers and so on, and I allways miss a simple way to record all activities I done.... some time to track problems I made, sometimes to recall a command done some time ago. So, with a simple script and one alias I resolve my problem. The script is not very well done and not very robust, but I think for now do a go job.alias ssh='~/bin/ssh_log_wrapper.sh' If for some reason you need to use the ssh binary, for example, do a tunnel, just invoke it with the full path. One goody, to do the logging, I use script command, which can create a time file and with scriptreplay it shows almost the same when the sessions was record. Show each time I do a ssh session to a machine, it is create one folder, one with the output of the session and other file with the timing information. |