Home  >  Article  >  Operation and Maintenance  >  ngix_http_stub_status_module

ngix_http_stub_status_module

巴扎黑
巴扎黑Original
2017-06-23 14:13:041573browse

1.ngx_http_stub_status_module is a built-in HTTP module of Nginx, which can provide Nginx status information. By default, this module is not compiled in, so you must specify to load this module when compiling Nginx--with-http_stub_status_module

2. First check if nginx is installed ngx_http_stub_status_module module

If it is not installed, you need to recompile.

# nginx -V | grep http_stub

#ngx_http_stub_status_module (static)

# nginx -v

##Tengine version: Tengine/2.1.1 (nginx/1.6. 2)

3, first in nginx server Information corresponding to segment configuration

server {

listen 80;

server_name xxx;

## location /

ngx_status Customized module name<strong></strong>## {

## stub_status on ; Turn on status access

## Access_log off;

##  #allow all; You can set which hosts need to be accessed

##  #deny all;## }

}

4, reload

nginx,Access test

service nginx reload

curl 127.0.0.1:80/ngx_status

##Active connections: 135

<strong></strong>server accepts handled requests request_time

13711907 25715823 5175039843

Reading: 0 Writing: 12 Waiting: 123

##Description:

Active connections: 135

#//Number of active connections<strong></strong>

server accepts handled requests <strong></strong>#13711907 25715823 5175039843

#Processed

13711907

connections and created 25715823 handshakes, a total of 5175039843ask. ##Reading: 0 Writing: 1 Waiting: 1 # Reading :Read the client<br>headernumber,

Writing:Return the client<strong></strong>header Number, Waiting:The request is completed, waiting for the next connection.

 <br>

The above is the detailed content of ngix_http_stub_status_module. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn