systemd: Started Session 305 of user root.

方法1:通过脚本特殊处理

# 执行如下SHELL
echo
'if ($programname == "systemd-logind" or $programname == "systemd") and ($msg contains "Starting Session" or $msg contains "Started Session" or $msg contains "Removed session" or $msg contains "New session" or $msg contains "Created slice" or $msg contains "Starting user-") then stop' >/etc/rsyslog.d/ignore-systemd-session-slice.conf

# 重启rsyslog 服务
systemctl restart rsyslog

 

方法2: 修改配置文件

       将/etc/systemd/system.conf 中 LogLevel=info 设置成如下:

#LogLevel=info
LogLevel=notice

 

方法3:系统命令

systemd-analyze set-log-level notice

 

posted @ 2018-09-10 15:15  halberd.lee  阅读(4102)  评论(0编辑  收藏  举报