puppet-rsyslog
puppet-rsyslog copied to clipboard
Nested variables in rsyslog_default.erb cause failure in rsyslog startup
Hi,
it appears the default installation on Amazon AMIs creates an /etc/sysconfig/rsyslog file with the following content:
# File is managed by puppet
RSYSLOGD_OPTIONS=""
# CentOS, RedHat, Fedora
SYSLOGD_OPTIONS="${RSYSLOGD_OPTIONS}"
derived from puppet-rsyslog/templates/rsyslog_default.erb.
Upon service startup systemd fails to start the daemon with the following logs:
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: Starting System Logging Service...
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: rsyslog.service: main process exited, code=exited, status=1/FAILURE
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: Failed to start System Logging Service.
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: Unit rsyslog.service entered failed state.
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: rsyslog.service failed.
May 13 18:20:30 ip-172-31-32-117.eu-central-1.compute.internal systemd[1]: rsyslog.service holdoff time over, scheduling restart.
Starting rsyslogd from the shell with no reference to the rsyslog_default or changing SYSLOGD_OPTIONS="${RSYSLOGD_OPTIONS}" to SYSLOGD_OPTIONS="" works.
It is my understanding that nesting variables breaks something in the service unit startup while on systems still free of systemd like CentOS 6 everything appears to be working fine.