CentOS7下Supervisor安装与配置(Linux/Un

2018-09-29  本文已影响0人  素年锦时2021
easy_install supervisor
[include]
files = /etc/supervisord.conf.d/*.conf(放置自定义服务配置的目录,文件夹可以自己创建)
[program:beepkg]
directory = /opt/app/beepkg
command = /opt/app/beepkg/api
autostart = true
startsecs = 5
user = root
redirect_stderr = true
stdout_logfile = /tmp/beepkg.log
supervisord -c /etc/supervisord.conf
supervisorctl status
supervisorctl stop tomcat
supervisorctl start tomcat
supervisorctl restart tomcat
supervisorctl reread
supervisorctl update

解决办法:
(1)关闭所有supervisor服务(supervisorctl stop all)
(2)杀掉supervisor进程(kill -9 pid,具体pid可以到/tmp/supervisord.pid中查看,或者采用ps -ef | grep supervisor命令查看)。

image.png

(3)到/etc/supervisord.conf中修改supervisor.sock的存放目录(因为 linux 系统会不定期的清理 tmp 文件夹,注意,此处需要修改两处),然后重新启动服务(supervisord -c /etc/supervisord.conf
)。
【2】supervisor.sock refused connection
解决办法:重启服务。

上一篇下一篇

猜你喜欢

热点阅读