25

I installed Supervisor on CentOS 6.5 and currently experiencing some weird error that I can't seem to fix.

I created a supervisord.conf file in /etc directory and call supervisor like this:

$ supervisord -c /etc/supervisord.conf 

Which looks pretty basic. But this error keeps appearing:

Error: .ini file does not include supervisord section

My supervisord.conf file looks like:

[program:supervisord]
command=/usr/local/bin/run_queue.sh
autostart=true
autorestart=true
stderr_logfile=/var/log/laraqueue.err.log
stdout_logfile=/var/log/laraqueue.out.log

Does anybody know what's the problem here?

nogias
  • 347
  • 1
  • 3
  • 6
  • Do you *also* have a `[supervisord]` section? – Nathan C Oct 23 '14 at 01:53
  • Can you explain a bit more? I don't seem to know this stuff very well. – nogias Oct 23 '14 at 01:58
  • 1
    Take a look at [this](http://supervisord.org/configuration.html). The program section above is right, but you also need the other section I mentioned in the same file as it contains all the global settings. – Nathan C Oct 23 '14 at 01:59

1 Answers1

28

You're probably missing the [supervisord] section in the file. See this.

For example,

[supervisord]
logfile = /tmp/supervisord.log
logfile_maxbytes = 50MB
logfile_backups=10
loglevel = info
pidfile = /tmp/supervisord.pid
nodaemon = false
minfds = 1024
minprocs = 200
umask = 022
user = chrism
identifier = supervisor
directory = /tmp
nocleanup = true
childlogdir = /tmp
strip_ansi = false
environment = KEY1="value1",KEY2="value2"
Nathan C
  • 15,059
  • 4
  • 43
  • 62
  • Is there any particularly important options I need to specify for the [supervisord] section? I currently leave it blank. – nogias Oct 23 '14 at 02:13
  • 3
    All the options are optional and are mostly related to logging, so nothing too important unless you need them. – Nathan C Oct 23 '14 at 13:30
  • 11
    this doesn't fix the problem for me – bachr Feb 12 '16 at 17:39
  • 1
    You should check if your supervisord is using correct configuration file. Also empty `[supervisord]` block is enough because none of its fields is required. – zored Sep 21 '19 at 07:40