我在中设置了以下内容/home/david/conf/supervisor.conf
:
[unix_http_server]
file=/home/david/tmp/supervisor.sock
[supervisord]
logfile=/home/david/tmp/supervisord.log ; (main log file;default $CWD/supervisord.log)
logfile_maxbytes=50MB ; (max main logfile bytes b4 rotation;default 50MB)
logfile_backups=10 ; (num of main logfile rotation backups;default 10)
loglevel=info ; (log level;default info; others: debug,warn,trace)
pidfile=/home/david/tmp/supervisord.pid ; (supervisord pidfile;default supervisord.pid)
nodaemon=false ; (start in foreground if true;default false)
minfds=1024 ; (min. avail startup file descriptors;default 1024)
minprocs=200
childlogdir=/home/david/tmp
[rpcinterface:supervisor]
supervisor.rpcinterface_factory = supervisor.rpcinterface:make_main_rpcinterface
[supervisorctl]
serverurl=unix:///home/david/tmp/supervisor.sock
并开始supervisord:
$ supervisord -c /home/david/conf/supervisor.conf
但是为什么supervisorctl
仍然使用默认值http://localhost:9001
作为serverurl
?
$ supervisorctl
http://localhost:9001 refused connection
supervisor>
我检查/home/david/tmp
了文件supervisord.log
并且supervisord.pid
确实存在。