![centos记录所有登陆用户的IP操作日志-豫章小站](https://blog.mydns.vip/wp-content/uploads/2021/12/cdc872db616ac66-220x150.jpg)
centos记录所有登陆用户的IP操作日志
将以下代码添加到/etc/profile文件底部 history USER=`whoami` USER_IP=`who -u am i 2>/dev/null| awk '{print $NF}'|sed -e 's/[()]//g'...
将以下代码添加到/etc/profile文件底部 history USER=`whoami` USER_IP=`who -u am i 2>/dev/null| awk '{print $NF}'|sed -e 's/[()]//g'...