UnixServerAdmin

Server Administration & Management

How to enable print last login option for SSH

To enable print last login information after login in to shell, we have to login in to shell as root user and make following changes in sshd_config file. Open sshd_config file in your favorite editor.

# vi /etc/ssh/sshd_config

find line “PrintLastLog” and change it from “No” to “Yes”.

PrintLastLog Yes

Save and exit file. Restart the sshd service.

# /etc/init.d/sshd restart

Now open duplicate ssh session and check PrintLastLog option is working or not.

September 2, 2011 Posted by | SSH | , | Leave a comment