您的位置:首页 > 运维架构 > Linux

linux下监控用户操作记录的工具

2018-01-30 20:39 211 查看
linux下监控用户操作记录的工具:

apt-get install bsdutils

mkdir /opt/operation_log

chmod 777 -R /opt/operation_log

vi /etc/profile

exec script -t 2> /opt/operation_log/$USER-$UID-
date +%F-%T
.data -a -q -f /opt/operation_log/$USER-$UID-
date +%F-%T
.log

:wq

source /etc/profile

操作记录回放:

scriptreplay /opt/operation_log/root-0-2018-01-30-20\:11\:29.data /opt/operation_log/root-0-2018-01-30-20\:11\:29.log

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  scrip treplay