获取上次成功登录失败的登录尝试次数 / CentOS 7

获取上次成功登录失败的登录尝试次数 / CentOS 7

尝试为 SSH 登录会话创建自定义登录统计欢迎信息,但也想保留原始消息,即:

Last failed login: Sun Feb 19 03:52:25 CET 2017 from 125.x.x.x on ssh:notty
There were 41 failed login attempts since the last successful login.
Last login: Sat Feb 18 19:58:07 2017 from 109.255.x.x

但是当我为自定义脚本创建/etc/profile.d/shell_welcome.sh文件时,原始脚本不再加载。有什么办法可以保留吗?或者如何复制相同的消息?具体来说这部分:
There were 41 failed login attempts since the last successful login.

相关内容