Thursday, 12 April 2012

ssh welcome banner

[root@station1 ~]# ssh station2
root@station2 password:
Last login: Mon Apr 10 18:58:43 2012 from localhost.localdomain
[root@station2 ~]#
Changing this message requires editing two different files. Open /etc/motd file and enter banner message.
[root@station2 ~]# vim /etc/motd
welcome to station2
Save and exit the file.
Now open sshd configuration file /etc/ssh/sshd_config,
[root@station2 ~]# vim /etc/ssh/sshd_config
PrintLastLog no ----->find this line and edit
Save and exit the file. Restart SSH service,
[root@station2 ~]# service sshd restart
[root@station2 ~]# exit
Now when you login, we will get below message,
[root@station1 ~]# ssh station2
root@station2 password:
Last login: Mon Apr 10 18:58:43 2012 from localhost.localdomain
Welcome to station2      ---------> see your welcome message
[root@ station2 ~]#

No comments:

Post a Comment