2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-24 15:05:36 +00:00

Fix the issue for stateless node in debug mode, /dev/log is not available (#5086)

(#4929) - use imjournal to make rsyslogd work well with journald
This commit is contained in:
Bin Xu
2018-04-11 14:19:35 +08:00
committed by yangsong
parent fe249bfb70
commit fc4bbd33fe
2 changed files with 7 additions and 2 deletions

View File

@ -16,7 +16,7 @@ install() {
local _installs
if type -P rsyslogd >/dev/null; then
_installs="rsyslogd"
inst_libdir_file rsyslog/lmnet.so rsyslog/imklog.so rsyslog/imuxsock.so
inst_libdir_file rsyslog/lmnet.so rsyslog/imklog.so rsyslog/imuxsock.so rsyslog/imjournal.so
elif type -P syslogd >/dev/null; then
_installs="syslogd"
elif type -P syslog-ng >/dev/null; then

View File

@ -21,7 +21,12 @@ rsyslog_config() {
# echo "${filter} @${server}"
# done
# In dracut 33, default rsyslogd configuration does not use journald. Then when
# rsyslog in debug mode, it causes `/dev/log` is not available after switch_root (#4929)
echo "\$ModLoad imjournal"
echo "\$OmitLocalLogging on"
echo "\$IMJournalStateFile imjournal.state"
if [ -n "$filters" ];then
confline="${filters}";
else