Our NGINX integration collects and sends inventory, logs, and metrics from your NGINX server to our platform, where you can see data on connections and client requests so that you can find the source of any problems.
To install the NGINX monitoring integration, you must run through the following steps:
- Enable your NGINX Server.
- Install and activate the integration.
- Configure the integration.
- Find and use data.
- Optionally, see NGINX's configuration settings.
Our integration is compatible with both NGINX Open Source and NGINX Plus. Before installing the integration, ensure you meet the following requirements:
- A New Relic account. Don't have one? Sign up for free! No credit card required.
- NGINX extension enabled, as described in the Enable your NGINX Server section.
- If NGINX is not running on Kubernetes or Amazon ECS, you must install the infrastructure agent on a Linux or Windows OS host that's running NGINX. Otherwise:
For a comprehensive list of specific Windows and Linux versions, check the table of compatible operating systems.
To capture data from the NGINX integration, you must first enable and configure the applicable extension module:
- For NGINX Open Source, see HTTP stub status module.
- For NGINX Plus, see HTTP status module and HTTP API module.
To install the NGINX integration, follow the instructions for your environment:
Install the infrastructure agent, and replace the
Change the directory to the integrations configuration folder by running:bash$cd /etc/newrelic-infra/integrations.d
Copy the sample configuration file by running:bash$sudo cp nginx-config.yml.sample nginx-config.yml
nginx-config.ymlconfiguration file with your favorite editor. Check out some configuration file examples..
Restart the infrastructure agent. See how to restart the infrastructure agent in different Linux environments.
To enable automatic NGINX access and error log parsing and forwarding, copy (or rename) the
nginx-log.yml. No need to restart the agent.bash$sudo cp /etc/newrelic-infra/logging.d/nginx-log.yml.example /etc/newrelic-infra/logging.d/nginx-log.yml
- Advanced: Integrations are also available in tarball format to allow for install outside of a package manager.
- On-host integrations do not automatically update. For best results, regularly update the integration package and the infrastructure agent.
Did this doc help with your installation?
There are several ways to configure the integration, depending on how it was installed:
- If it was enabled via Kubernetes, see Monitor services running on Kubernetes.
- If it was enabled via Amazon ECS, see Monitor services running on ECS.
- If it was installed on-host, edit the integration's
nginx-config.ymlconfiguration file. An integration's YAML-format configuration is where you can place required login credentials and configure how data is collected. The options you change depend on your setup and preference. The configuration file has common settings applicable to all integrations such as
inventory_source. To read about these common settings, see configuration format.
If you are still using our Legacy configuration and definition files, refer to this document for help.
Specific settings related to NGINX are defined using the
env section of the configuration file. These settings control the connection to your NGINX instance as well as other security settings and features. The list of valid settings is described in the next section of this document.
For more on how to find and use your data, see NGINX's configuration settings.
After you've configured and installed the integration, you can start monitoring:
- Data from this service, which is reported to an integration dashboard.
- Metrics that are attached to the
NginxSampleevent type. You can query this data for troubleshooting purposes or to create custom charts and dashboards.
- Logs will be visible in the logs UI.
For more on how to find and use your data, see how to understand integration data.
The NGINX integration collects the following metrics: