Docs » Integrations Guide » Integrations Reference » NGINX

../../_images/integrations_nginx.png NGINX 🔗

DESCRIPTION 🔗

This integration primarily consists of the Smart Agent monitor collectd/nginx. Below is an overview of that monitor.

Smart Agent Monitor 🔗

Monitors an NGINX instance using our fork of the collectd nginx plugin based on the collectd nginx plugin.

Note that this montior requires special configuration enabled in NGINX (see Setup).

NGINX-specific configuration 🔗

You must configure NGINX to expose status information by editing the NGINX configuration. Please see ngx_http_stub_status_module for a guide to configuring the NGINX stats module ngx_http_stub_status_module.

INSTALLATION 🔗

This integration is part of the SignalFx Smart Agent as the collectd/nginx monitor. You should first deploy the Smart Agent to the same host as the service you want to monitor, and then continue with the configuration instructions below.

CONFIGURATION 🔗

To activate this monitor in the Smart Agent, add the following to your agent config:

monitors:  # All monitor config goes under this key
 - type: collectd/nginx
   ...  # Additional config

For a list of monitor options that are common to all monitors, see Common Configuration.

Config option Required Type Description
host yes string
port yes integer
name no string
url no string The full URL of the status endpoint; can be a template (default: http://{{.Host}}:{{.Port}}/nginx_status)
username no string
password no string
timeout no integer (default: 0)

USAGE 🔗

Sample of built-in dashboard in SignalFx:

../../_images/dashboard_nginx.png

METRICS 🔗

Metric Name Description Type
connections.accepted Connections accepted by NGINX Web Server cumulative
connections.failed Connections failed by the NGINX Web Server cumulative
connections.handled Connections handled by NGINX Web Server cumulative
nginx_connections.active Connections active in NGINX Web Server gauge
nginx_connections.reading Connections being read by NGINX Web Server gauge
nginx_connections.waiting Connections waited on by NGINX Web Server gauge
nginx_connections.writing Connections being written by NGINX Web Server gauge
nginx_requests Requests handled by NGINX Web Server cumulative

connections.accepted 🔗

cumulative

Connections accepted by NGINX Web Server

connections.failed 🔗

cumulative

Connections failed by the NGINX Web Server

connections.handled 🔗

cumulative

Connections handled by NGINX Web Server

nginx_connections.active 🔗

gauge

Connections active in NGINX Web Server

nginx_connections.reading 🔗

gauge

Connections being read by NGINX Web Server

nginx_connections.waiting 🔗

gauge

Connections waited on by NGINX Web Server

nginx_connections.writing 🔗

gauge

Connections being written by NGINX Web Server

nginx_requests 🔗

cumulative

Requests handled by NGINX Web Server

These are the metrics available for this monitor. Metrics that are categorized as container/host (default) are in bold and italics in the list below.

  • connections.accepted (cumulative)
    Connections accepted by NGINX Web Server
  • connections.failed (cumulative)
    Connections failed by the NGINX Web Server
  • connections.handled (cumulative)
    Connections handled by NGINX Web Server
  • nginx_connections.active (gauge)
    Connections active in NGINX Web Server
  • nginx_connections.reading (gauge)
    Connections being read by NGINX Web Server
  • nginx_connections.waiting (gauge)
    Connections waited on by NGINX Web Server
  • nginx_connections.writing (gauge)
    Connections being written by NGINX Web Server
  • nginx_requests (cumulative)
    Requests handled by NGINX Web Server

Non-default metrics (version 4.7.0+) 🔗

The following information applies to the agent version 4.7.0+ that has enableBuiltInFiltering: true set on the top level of the agent config.

To emit metrics that are not default, you can add those metrics in the generic monitor-level extraMetrics config option. Metrics that are derived from specific configuration options that do not appear in the above list of metrics do not need to be added to extraMetrics.

To see a list of metrics that will be emitted you can run agent-status monitors after configuring this monitor in a running agent instance.

Legacy non-default metrics (version < 4.7.0) 🔗

The following information only applies to agent version older than 4.7.0. If you have a newer agent and have set enableBuiltInFiltering: true at the top level of your agent config, see the section above. See upgrade instructions in Old-style whitelist filtering.

If you have a reference to the whitelist.json in your agent’s top-level metricsToExclude config option, and you want to emit metrics that are not in that whitelist, then you need to add an item to the top-level metricsToInclude config option to override that whitelist (see Inclusion filtering. Or you can just copy the whitelist.json, modify it, and reference that in metricsToExclude.