大网数据广告活动
服务器运维问答

What does "-/filepath" ACTION mean in rsyslog configuration

· 52CE 我爱测

I came across this one Debian Linux installation (6.0.6), and examining its /etc/rsyslog.conf, I see configuration lines like this: auth,authpriv.* /var/log/auth.log *.*;auth,authpriv.none -/var/log/syslog I can't find anything a…

问题原文

原帖链接 · Pawel Veselov · CC BY-SA 3.0

I came across this one Debian Linux installation (6.0.6), and examining its /etc/rsyslog.conf, I see configuration lines like this:

auth,authpriv.*                 /var/log/auth.log
*.*;auth,authpriv.none          -/var/log/syslog

I can't find anything about prepending dashes to the file action in rsyslog.conf(5), and what the meaning of it might be, and would like to know what they actually do.

已采纳解答

原帖链接 · Pawel Veselov · CC BY-SA 4.0

Googled this a bit more, and found this.

In essence, it means to not synchronize the log file to disk every time there is a write, if synchronization behavior is on by default.

It is stated that since v3 the default behavior is not sync, and it's possible to change this by specifying "$ActionFileEnableSync on/off".

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2013-01-04)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0 / CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。