좋아 브라이언 달에 의해 GearmanManager을 사용할 수 있습니다. 이전 문제에 대한 해결책을 찾았습니다. 그것은 Supermanord를 사용하여 기어맨 작업자를 탈모하는 것을 포함합니다. 다음
chmod +x /etc/init.d/supervisord
update-rc.d -f supervisord defaults
당신 :
여기 Supervisord가
여기
apt-get install python-setuptools
easy_install supervisor
echo_supervisord_conf > /etc/supervisord.conf
이 (첫번째 here에서 init 스크립트를 얻고 /etc/init.d/supervisord
에 저장)를 구성하는 방법은 다음, 다음과 같이 설치하는 방법 슈퍼 바이저에게 데몬으로 실행할 명령을 알려주도록 supervisor.conf 파일을 업데이트해야합니다 (물론 이것은 기어맨 작업자가됩니다). 아래는 supervisord.conf 파일에 추가 할 샘플의 예입니다. 사용자 고유의 특정 상황으로 업데이트해야합니다. 작업이 완료되면
[program:gearman]
command=/usr/bin/php php_gearman_worker.php
numprocs=1
directory=/root/gearman
stdout_logfile=/root/gearman/supervisord.log
environment=GEARMAN_USER=gearman
autostart=true
autorestart=true
user=gearman
stopsignal=KILL
, 다음 supervisord 즉 /etc/init.d/supervisord start
시작합니다.
이렇게하면 Gearman 작업자가 활성화되어 이제 명령 줄이나 브라우저를 사용하여 gearman 클라이언트를 실행할 수 있습니다.
이 정보가 도움이되기를 바랍니다.
''apt-get install supervisor' 그리고'[program : gearman]'과'command = '명령으로'/ etc/supervisor/conf.d// usr/bin/php php_gearman_worker.php'이 저에게 필요한 전부였습니다. –