This article is going to show how to compile and install the Nginx module – ngx_http_vhost_traffic_status.
The module gathers traffic information per the server blocks and upstream servers and shows information for Nginx proxy cache like used space.
In addition, the module shows the type of the Response – 1xx, 2xx, 3xx, 4xx, 5xx and total. So when if problems occur in a server block or an upstream server
This module nginx-module-vts offers really extended status information for your Nginx.
Here is one the status page of our web servers with 18 virtual hosts:
The status page shows all virtual hosts in section “Server zones” and all upstream servers for the FastCGI PHP backend servers.
Traffic, requests, and status codes are available. All data is available in JSON, too.
Server zones information
- Requests – Total, Requests/s, Time
- Responses – 1xx, 2xx, 3xx, 4xx, 5xx, Total
- Traffic – Sent, Received, Sent/s, Received/s
- Cache – Miss, Bypass, Expired, Stale, Updating, Revalidated, Hit, Scarce, Total
In addition to the information above there are State, Response Time, Weight, MaxFails and FileTimeout for all the upstream servers. And for the Nginx proxy cache there are Size, Capacity (live information!) and all information above per zone – there is an additional article here Live status information like used space and more for nginx proxy cache.
Keep on reading!