linux 服务器登录显示lastlogin

1、参数修改:

/etc/ssh/sshd_config 文件里边的 printlastlog 设置为yes

/etc/ssh/sshd_config 文件里边的 printmotd 设置为yes

 

2、添加lastlog日子文件

/var/log/文件夹里边添加  lastlog文件。

 

3、添加登录欢迎语句

/etc/motd 文件中添加登录欢迎语句

posted @ 2021-03-08 16:11  千里走单琦  阅读(1796)  评论(0编辑  收藏  举报