×ðÁú¿­Ê±¹ÙÍøµÇ¼

nginxÔËÐÐ״̬ÔõôÉó²é

¿ÉÒÔͨ¹ýÒÔÏÂÒªÁìÉó²é nginx ÔËÐÐ״̬£ºnginx -t£º¼ì²éÉèÖÃÎļþÓï·¨ÊÇ·ñ׼ȷ¡£nginx -v£ºÏÔʾ nginx °æ±¾ºÍÆäËû±àÒëÐÅÏ¢¡£service nginx status£ºÉó²é nginx ЧÀ͵ÄÔËÐÐ״̬£¨ÊÊÓÃÓÚ linux ϵͳ£©¡£ps -ef | grep nginx£º²éÕÒÕýÔÚÔËÐÐµÄ nginx Àú³Ì¡£netstat -nlp | grep nginx£ºÉó²é nginx ¼àÌýµÄ¶Ë¿ÚºÍµØµã¡£

nginx ÔËÐÐ״̬Éó²é

ÔõÑùÉó²é nginx ÔËÐÐ״̬£¿

ʹÓÃÒÔÏÂÏÂÁîÖ®Ò»£º

nginx -t: ¼ì²é nginx ÉèÖÃÎļþÓï·¨ÊÇ·ñ׼ȷ£¬¶ø²»Æô¶¯ nginx¡£

nginx -V: ÏÔʾ nginx °æ±¾ºÍÆäËû±àÒëÐÅÏ¢£¬¶ø²»Æô¶¯ nginx¡£

service nginx status: Éó²éϵͳЧÀÍÖÐ nginx µÄÔËÐÐ״̬£¨ÊÊÓÃÓÚ Linux ϵͳ£©¡£

ps -ef | grep nginx: ²éÕÒËùÓÐÕýÔÚÔËÐÐµÄ nginx Àú³Ì£¬²¢ÏÔʾÆä״̬ºÍÆäËûÐÅÏ¢¡£

netstat -nlp | grep nginx: Éó²é nginx ÕýÔÚ¼àÌýÄÄЩ¶Ë¿ÚºÍµØµã¡£

ÏêϸڹÊÍ£º

nginx -t

´ËÏÂÁî¼ì²é nginx ÉèÖÃÎļþ£¨Í¨³£Î»ÓÚ /etc/nginx/nginx.conf£©µÄÓï·¨¡£ÈôÊÇÉèÖÃÎļþ׼ȷ£¬½«ÏÔʾÒÔÏÂÐÂÎÅ£º

nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful

µÇ¼ºó¸´ÖÆ

nginx -V

´ËÏÂÁîÏÔʾ nginx °æ±¾ÒÔ¼°ÓйØÆä±àÒëÑ¡ÏîºÍÆäËûÐÅÏ¢¡£

service nginx status

´ËÏÂÁîÊÊÓÃÓÚ Linux ϵͳ£¬ËüÏÔʾ nginx ЧÀ͵ÄÔËÐÐ״̬¡£Êä³öͨ³£ÈçÏÂËùʾ£º

nginx is running (pid 12345)

µÇ¼ºó¸´ÖÆ

ps -ef | grep nginx

´ËÏÂÁîÏÔʾϵͳÖÐËùÓÐÕýÔÚÔËÐÐµÄ nginx Àú³Ì¡£Êä³öÀàËÆÓÚ£º

root      12345  15122 15:02 ?        00:00:05 nginx: master process /usr/sbin/nginx -g daemon on; master_process on;
root      12346  15125 15:02 ?        00:00:00 nginx: worker process

µÇ¼ºó¸´ÖÆ

netstat -nlp | grep nginx

´ËÏÂÁîÏÔʾ nginx ¼àÌýµÄ¶Ë¿ÚºÍµØµã¡£Êä³öͨ³£ÈçÏÂËùʾ£º

tcp        0      0 0.0.0.0:80             0.0.0.0:*               LISTEN
tcp        0      0 :::80                  :::*                    LISTEN

µÇ¼ºó¸´ÖÆ

ÒÔÉϾÍÊÇnginxÔËÐÐ״̬ÔõôÉó²éµÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡

ÃâÔð˵Ã÷£ºÒÔÉÏչʾÄÚÈÝȪԴÓÚÏàÖúýÌå¡¢ÆóÒµ»ú¹¹¡¢ÍøÓÑÌṩ»òÍøÂçÍøÂçÕûÀí£¬°æȨÕùÒéÓë±¾Õ¾Î޹أ¬ÎÄÕÂÉæ¼°¿´·¨Óë¿´·¨²»´ú±í×ðÁú¿­Ê±¹ÙÍøµÇ¼ÂËÓÍ»úÍø¹Ù·½Ì¬¶È£¬Çë¶ÁÕß½ö×ö²Î¿¼¡£±¾ÎĽӴýתÔØ£¬×ªÔØÇë˵Ã÷À´ÓÉ¡£ÈôÄúÒÔΪ±¾ÎÄÇÖÕ¼ÁËÄúµÄ°æȨÐÅÏ¢£¬»òÄú·¢Ã÷¸ÃÄÚÈÝÓÐÈκÎÉæ¼°ÓÐÎ¥¹«µÂ¡¢Ã°·¸Ö´·¨µÈÎ¥·¨ÐÅÏ¢£¬ÇëÄúÁ¬Ã¦ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼ʵʱÐÞÕý»òɾ³ý¡£

Ïà¹ØÐÂÎÅ

ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼

18523999891

¿É΢ÐÅÔÚÏß×Éѯ

ÊÂÇéʱ¼ä£ºÖÜÒ»ÖÁÖÜÎ壬9:30-18:30£¬½ÚãåÈÕÐÝÏ¢

QR code
ÍøÕ¾µØͼ