系统日志的管理(linux)(System log management (Linux)).docVIP

  • 10
  • 0
  • 约 16页
  • 2017-10-07 发布于河南
  • 举报

系统日志的管理(linux)(System log management (Linux)).doc

系统日志的管理(linux)(System log management (Linux))

系统日志的管理(linux)(System log management (Linux)) Linux system log management Log classification: 1. log of connection time The connection time log is usually recorded by the two files, /var/log/wtmp and /var/run/utmp, but this The two file cannot be viewed directly by cat, and the file is automatically updated by the system, as follows: W/who/finger/id/last/lastlog/ac for review [root@xhot who ~]# Root tty1 2010-10-06 22:56 Root pts/0 2010-10-06, 22:26 () Root pts/1 2010-10-06, 23:41 () Root pts/3 2010-10-06, 23:18 () [root@xhot w ~]# 01:01:02, up, 2:36, 4, users, load, average: 0.15, 0.03, 0.01 USER, TTY, FROM, LOGIN@, IDLE, JCPU, PCPU, WHAT Root tty1 - 22:56, 1:20m, 0.16s, 0.16s, -bash Root, pts/0, , 22:26, 2:05m, 0.18s, 0.18s, -bash Root, pts/1, , 23:41, 0.00s, 0.41s, 0.00s, w Root, pts/3, , 23:18, 1:38m, 0.03s, 0.03s, -bash [root@xhot AC -p / / ~]# connection time view each user U51 1.23 U55 0.04 Root 95.21 / root connection can be seen for the longest time. Xhot 0.06 User1 3.93 Total 100.48 [root@xhot -a / / AC connection time ~]# view all users Total 100.49 [root@xhot -d / / AC connection time ~]# view user every day Sep 24 total 0.14 Sep 25 total 14.60 Sep 26 total 13.71 Sep 27 total 21.47 Sep 28 total 11.74 Sep 29 total 6.60 Sep 30 total 8.81 Oct 1 total 9.04 Oct 2 total 0.47 / / I can see 3, 4, 5, the national day to go out to play Oct 6 total 8.62 Today total 5.29 Several other orders are not specifically introduced 2. process monitoring log The process statistics monitor log is very effective in monitoring users operation instructions. When servers are discovered recently, often You can use the process statistics log to log off without any reason to shutdown or delete files without reason: [root@xhot Accton /var/account/pacct / / ~]# open process log monitoring statistics [root@xhot lastcomm / / ~]# view process log statistics Accton, S, root, pts/1, 0, secs, Thu, Oct, 7, 01:20 Accton, root, pts/1 0, secs, Thu, Oct, 7, 01:20 AC, root, pts/1 0, secs, Thu, Oct

您可能关注的文档

文档评论(0)

1亿VIP精品文档

相关文档