NGINX
Monitor active connections, connection states, and request rates from the local NGINX server.
The agent probes the NGINX stub status module exposed on localhost.
You need to enable and configure the stub_status directive for the collector to work.
Configuration
1. Create a dedicated NGINX configuration file
Add a minimal site configuration to expose NGINX statistics locally. For example, create /etc/nginx/sites-enabled/status.conf with the following content:
server {
listen 127.0.0.1:80;
listen [::1]:80;
location /nginx_status {
stub_status on;
allow 127.0.0.1;
allow ::1;
deny all;
}
}
2. Restart NGINX
Once the file is created, reload or restart NGINX:
sudo nginx -tto validate syntaxsudo systemctl reload nginxorsudo systemctl restart nginx
3. Verify that stub status works
Test locally:
You should see output similar to:
Active connections: 18
server accepts handled requests
360192 360192 2481072
Reading: 0 Writing: 1 Waiting: 17
4. Restart the agent
After NGINX is exposing the stub status, restart simob so it runs metrics discovery
Warning
Without restarting, the agent may not detect the new endpoint.
5. Enable NGINX collection from the UI
Once the agent discovers NGINX (usually within a few seconds), it will appear in your server configuration panel. You must explicitly enable the NGINX collector from the UI for this server.
Info
After enabling, the change may take up to 5 minutes to propagate to the agent depending on your agent state.
Metrics collected
| Metric | Description |
|---|---|
nginx_connections_active_total |
Number of active client connections |
nginx_connections_reading_total |
Connections where NGINX is reading requests |
nginx_connections_writing_total |
Connections where NGINX is writing responses |
nginx_connections_waiting_total |
Idle connections waiting for requests |
nginx_requests_total |
Total number of client requests since start |
nginx_requests_rate |
Rate of requests per second |
FAQ
Does this affect my existing NGINX configuration?
No. It adds a separate small site, isolated from your existing configuration. It does not modify your current virtual hosts or SSL setup.
Does the endpoint need to be publicly reachable?
No. It must remain local-only. simob queries 127.0.0.1, so exposing it publicly would be unnecessary and insecure.