Documentation forSolarWinds Observability

Configure NGINX integration

To integrate NGINX with SolarWinds Observability:

  1. In SolarWinds Observability, click Add Data at the top.

  2. In the Add Data dialog, click Integration, and then click NGINX.

  3. In the Add NGINX dialog, select a host with the SolarWinds Observability Agent you want to use for NGINX and click Next.

    To only display Agents running in a Kubernetes cluster, click the List only Agents... toggle.

    If you want to install a dedicated Agent on a dedicated host, add the host and then add the NGINX integration. See Add a self-managed host.

    If you prefer using Docker, see Run the SolarWinds Observability Agent as a Docker image or Kubernetes deployment.

  4. Select where the NGINX service is located:

    • On Host: The NGINX service runs on the same physical or virtual machine as the Agent.

    • Off Host: The NGINX service runs on a different physical or virtual machine than the Agent.

  5. Make sure that NGINX is ready to be integrated. NGINX must expose status information.

    1. Run a command to check that the status module is enabled.

    2. nginx -V 2>&1 | grep -o with-http_stub_status_module
    3. Search for with-http_stub_status_module in the output. If the output file doesn't include it, enable the https_stub_status_module. Refer to NGINX documentation for details.

    4. Open the NGINX configuration file and make sure the stub_status_module is enabled. By default, the configuration file is located at /etc/nginx/sites-available/default.

      Example: enabled stub_status_module

      location /status {
      	allow; #only allow requests from localhost
      	deny all; #deny all other hosts}

      Example: stub_status_module not configured

      server {
      	listen 80 default_server;
      	listen [::]:80 default_server;
      	root /var/www/html;
      	location /status {ADD STUB_STATUS INFO HERE}
    5. Run the following command to check the NGINX configuration file for errors. If there are errors, resolve them.

      nginx -t
    6. If there are no errors, restart the NGINX service using this command.

      nginx -s reload
    7. Run the command to call the status URL. The call should return basic status data.

      curl http://localhost:80/status
    8. Click Next.

  6. Review the configuration and click Deploy to deploy the changes to the agent.

    • Provide a Display Name.

    • Review the NGINX Endpoint.

    • Review the Collection Interval.

    • For On Host integrations, you can collect logs. Click Enable log monitoring and configure logs.

  7. Optional for On Host integrations: Configure logs.

    If you enabled logs:

    1. Grant the Agent access to the NGINX log folder. Use the following command:

      sudo usermod -a -G adm swagent
    2. Restart the Agent. Run the following command.

      sudo service uamsclient restart
    3. Review the default path for storing logs. Adjust it if appropriate.

  8. When the installation is complete, you can continue to observe NGINX data. Use the buttons on the Summary screen.

To view data collected for the newly configured entity in the Entity Explorer, click the name of the NGINX instance in the confirmation dialog in the lower-left corner. It may take a few seconds for data to appear for the newly created entity. See Entity Explorer for details.