课程: Linux: Kernels and Logging for System Administration
免费学习该课程!
今天就开通帐号,24,700 门业界名师课程任您挑!
Use rsyslog actions - Linux教程
课程: Linux: Kernels and Logging for System Administration
Use rsyslog actions
- [Instructor] An Rsyslog rule consists of the selector on the left that contains a filter and priority, and on the right is the action. For this video, I will focus entirely on the action. For every Rsyslog filter, there is an Rsyslog log action. The action for a log filter usually involves saving the log message to a file. For instance, in this case, all cron messages are saved to /var/log/cron.log. As this line is written, this file is synchronized on every write. This can create a lot of overhead if there are a lot of writes to the log. To keep from sinking the file system every time the log is written, you can proceed the path with a dash. Beware that the data is held in RAM since it's not run to the disc right away. This opens the possibility that you may lose data if the server shuts down unexpectedly. Paths for logs can either be static, as we saw in our previous example, or dynamic. With a dynamic path, you create a template and then use that template name prefixed with a…
内容
-
-
-
-
-
-
(已锁定)
About Linux logging3 分钟 45 秒
-
(已锁定)
Make journald logs persistent53 秒
-
(已锁定)
Rsyslog configuration2 分钟 58 秒
-
(已锁定)
View system log files4 分钟 5 秒
-
(已锁定)
Use rsyslog filters2 分钟 12 秒
-
(已锁定)
Use rsyslog actions3 分钟 17 秒
-
(已锁定)
Rotate log files1 分钟 53 秒
-
(已锁定)
Clear old system journals2 分钟 4 秒
-
(已锁定)
Retrieve systemd journal1 分钟 59 秒
-
(已锁定)
Log to a remote logging server7 分钟 36 秒
-
(已锁定)
-