美文网首页
supervisor

supervisor

作者: jojo1313 | 来源:发表于2023-08-03 16:36 被阅读0次

    centos7.x

    yum install epel-release
    yum install supervisor -y
    
    vim /etc/supervisord.d/lvs-metrics.ini
    [program:lvs-metrics]
    command=/home/go/src/lvs-metrics-master/lvs-metrics -c /home/go/src/lvs-metrics-master/cfg.json 
    directory=/home/go/src/lvs-metrics-master
    user=anzhuu 
    autostart=true
    autorestart=true
    stderr_logfile=/var/log/lvs-metrics.err.log 
    stdout_logfile=/var/log/lvs-metrics.out.log
    

    Unit not found ...

    systemctl list-unit-files --type=service 看服务列表有没有这个服务
    systemctl enable supervisord #改disable为enable

    systemctl stop/start supervisord.service

    systemctl status supervisord

    centos6

    /usr/local/python3/bin/pip install supervisor
    mkdir -p /etc/supervisord.d
    mkdir -p /etc/supervisor
    vim /etc/supervisord.d/lvs-metrics.ini
    /usr/local/python3/bin/echo_supervisord_conf > /etc/supervisor/supervisord.conf
    ln -s /usr/local/python3/bin/supervisord /usr/bin/supervisord
    ln -s /usr/local/python3/bin/supervisorctl /usr/bin/supervisorctl
    supervisord -c /etc/supervisor/supervisord.conf && supervisorctl -c /etc/supervisor/supervisord.conf
    

    相关文章

      网友评论

          本文标题:supervisor

          本文链接:https://www.haomeiwen.com/subject/ttbmpdtx.html