0

Before:

root@haproxy:/# ps aux | grep rsyslog
root       420  0.0  0.1   8860   648 ?        S+   12:38   0:00 grep --color=auto rsyslog

Start Supervisord and error:

root@haproxy:/# /usr/bin/supervisord
/usr/lib/python2.7/dist-packages/supervisor/options.py:295: UserWarning: Supervisord is running as root and it is searching for its configuration file in default locations (including its current working directory); you probably want to specify a "-c" argument specifying an absolute path to a configuration file for improved security.
  'Supervisord is running as root and it is searching '
2015-11-25 12:06:59,742 CRIT Supervisor running as root (no user in config file)
2015-11-25 12:06:59,743 WARN Included extra file "/etc/supervisor/conf.d/supervisord.conf" during parsing
2015-11-25 12:06:59,769 INFO RPC interface 'supervisor' initialized
2015-11-25 12:06:59,770 CRIT Server 'unix_http_server' running without any HTTP authentication checking
2015-11-25 12:06:59,770 INFO supervisord started with pid 211
2015-11-25 12:07:00,774 INFO spawned: 'rsyslog' with pid 214
2015-11-25 12:07:00,845 INFO exited: rsyslog (exit status 0; not expected)
2015-11-25 12:07:01,849 INFO spawned: 'rsyslog' with pid 232
2015-11-25 12:07:01,874 INFO exited: rsyslog (exit status 0; not expected)
2015-11-25 12:07:03,879 INFO spawned: 'rsyslog' with pid 243
2015-11-25 12:07:03,902 INFO exited: rsyslog (exit status 0; not expected)
2015-11-25 12:07:06,907 INFO spawned: 'rsyslog' with pid 254
2015-11-25 12:07:06,926 INFO exited: rsyslog (exit status 0; not expected)
2015-11-25 12:07:07,928 INFO gave up: rsyslog entered FATAL state, too many start retries too quickly

After:

root@haproxy:/# ps aux | grep rsyslog
syslog     435  0.1  0.2 116572  1208 ?        Ssl  12:39   0:00 /usr/sbin/rsyslogd
root       474  0.0  0.1   8860   648 ?        S+   12:39   0:00 grep --color=auto rsyslog

File /etc/supervisor/conf.d/supervisord.conf:

[supervisord]
nodaemon=true

[program:rsyslog]
command=service rsyslog start
startsecs=5

I can start up rsyslog manually without any issue with:

service rsyslog start

So as you can see, before I go ahead and start supervisord rsyslog is not running. After I run the supervisord it does indeed start rsyslog however spawns and exits. Anyone know the reason behind this?

0

Found this little diamond which works:

[program:rsyslog]
command=rsyslogd -n -c5
autostart=true
autorestart=true
redirect_stderr=true

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.