CWP7은 monit 오류에서 nginx 연결 실패 문제를 해결합니다.

CWP7 주소 지정 모니터링 모니터링오류 문제: nginx 연결 fai모니터에서 주도

CWP7은 monit 오류에서 nginx 연결 실패 문제를 해결합니다.

마지막으로천 웨이량모니터 모니터링을 설치하기 위한 CWP 제어판(CWP7)软件时 ,해결 모니터 시작 모니터링 프로세스 사라짐 monit.service가 실패했습니다.

이제 새로운 문제가 있습니다. Nginx 연결 모니터링에 실패했습니다...

모니터에서 nginx 연결 실패를 해결하는 방법은 무엇입니까?

nginx 연결을 해결하는 방법은 monit 오류 문제에서 실패했습니다.

먼저 다음 명령어로 SSH 접속 ▼

ps -ef|grep nginx

nginx 구성 파일을 찾았습니다.

[root@ten ~]# ps -ef|grep nginx
root 11550 1 0 02:12 ? 00:00:00 nginx: master process /usr/sbin/nginx -c /etc/nginx/nginx.conf
nobody 11551 11550 0 02:12 ? 00:00:04 nginx: worker process
nobody 11552 11550 0 02:12 ? 00:00:08 nginx: worker process
nobody 11553 11550 0 02:12 ? 00:00:02 nginx: worker process
nobody 11554 11550 0 02:12 ? 00:00:01 nginx: worker process
nobody 11555 11550 0 02:12 ? 00:00:00 nginx: cache manager process
root 19827 9820 0 02:37 pts/0 00:00:00 grep --color=auto nginx

æ ‰“å¼ €nginx 설정 파일:

/etc/nginx/nginx.conf

nginx.pid의 경로 위치를 찾았습니다.

pid /var/run/nginx.pid;

Monit 모니터링 프로그램의 설정 파일에서 nginx를 모니터링하기 위한 다음 설정을 입력합니다▼

check process nginx with pidfile /var/run/nginx.pid
start program "/usr/bin/systemctl start nginx.service"
stop program "/usr/bin/systemctl stop nginx.service"
if failed port 8181 protocol http then restart
if 4 restarts within 8 cycles then timeoutif 4 restarts within 8 cycles then timeout

모니터 모니터링 프로그램 재시작▼

systemctl restart monit.service

모니터 모니터링 프로그램 상태 보기▼

systemctl status monit.service

이 단계에 도달하면 오류 메시지가 계속 나타납니다.nginx Connection failed in monit

모니터링 nginx 구성의 포트 번호를 "8181" 또는 "80"으로 수정하십시오.

if failed port 8181 protocol http then restart
if failed port 80 protocol http then restart

그런 다음 모니터 모니터링 프로그램을 다시 시작하세요▼

systemctl restart monit.service

모니터 모니터링 프로그램 상태 보기▼

systemctl status monit.service

monit에서 nginx 연결 실패 문제가 드디어 해결되었습니다!

发表 评论

귀하의 이메일 주소는 공개되지 않습니다. 必填 项 已 用 * 标注

위쪽으로 스크롤