SSH session logging By admin on August 24, 2009 in General Add the following line to /etc/profile to setup full logging of all ssh sessions: script -q /var/log/sessions/ssh-date +%d-%M-%Y-%Hh-%Mm-%Ss–whoami-$$.log && exit Of course this is a security risk and violates user privacy. Related posts: Sendmail Logging Content Sync For Load Balancer With Unison