• English日本語한국어
  • Log inStart now

Apache monitoring integration

Our Apache integration reports data from your Apache web server to the New Relic platform. You can view dashboards of your Apache metric data, create alert policies, and create your own custom queries and charts.

Compatibility and requirements

Before installation, ensure you meet these requirements:

Quick start

If you're not running Apache in Kubernetes or ECS environments, we recommend our guided install. Our guided install uses our infrastructure agent and our CLI to set up the Apache integration, and discovers other applications and log sources running in your environment and then recommends which ones you should instrument.

The guided install works with most setups. But if it doesn't suit your needs, there are other install options below.

Ready to get started? Click the relevant button, depending on which data center region you use. When you're done with the install, return to this documentation to review the configuration options.

Guided install, US region

Install

If you're not using the guided install, follow the instructions for your environment:

Update your integration

This integration doesn't automatically update. For best results, regularly update the integration package and the infrastructure agent.

Post-installation tasks

When you're done with the install, you can set configuration options. Some configurations are required to get the integration to work, while some are optional.

Enabling your Apache server

To capture data from our Apache integration, you must:

  • Ensure the Apache status module is enabled and configured for Apache instance.
  • Ensure the Apache status module endpoint (default server-status) is available from the host containing the Apache integration.

Configure the integration

If you enabled this integration via our ECS or Kubernetes integration, see those docs:

For the standard on-host installation, this integration comes with a YAML config file, apache-config.yml. This configuration is where you can place required login credentials and configure how data is collected. Which options you change depends on your setup and preferences. It comes with a sample config file apache-config.yml.sample that you can copy and edit.

Tips on configuration:

The configuration file has common settings applicable to this and other New Relic on-host integrations, like interval, timeout, inventory_source. To learn about these common settings, refer to On-host configuration format.

Specific settings related to Apache are defined using the env section of the configuration file. These settings control the connection to your Apache instance as well as other security settings and features. The list of valid settings is described in the next section of this document.

We also have example config files.

Did this doc help with your installation?

Apache configuration options

The Apache integration collects both metrics and inventory information. This table shows what each configuration option applies to.

Setting

Description

Default

Applies to

STATUS_URL

The URL set up to provide the metrics using the status module.

http://127.0.0.1/server-status?auto

Metrics, inventory

BINARY_PATH

Set location of the Apache binary file.

N/A

Inventory

CA_BUNDLE_FILE

Alternative Certificate Authority bundle file.

N/A

Metrics

CA_BUNDLE_DIR

Alternative Certificate Authority bundle directory.

N/A

Metrics

VALIDATE_CERTS

Set to false if the status URL is HTTPS with a self-signed certificate.

true

Metrics

REMOTE_MONITORING

Enable multi-tenancy monitoring.

true

Metrics, inventory

METRICS

Set to true to enable metrics-only collection.

false

INVENTORY

Set to true to enable inventory-only collection.

false

The values for these settings can be defined in several ways:

  • Adding the value directly in the config file (the most common way).
  • Replacing the values from environment variables using the {{}} notation. This requires infrastructure agent version 1.14.0 or higher. For more information, see Infrastructure configuration or see the environment variable example.
  • Using secrets management. Use this to protect sensitive information, such as passwords that would be exposed in plain text in the configuration file. For more information, see Secrets management.

Labels

You can further decorate your metrics using labels. Labels allow you to add attributes (key/value pairs) to your metrics, which you can then use to query, filter, or group your metrics.

Our default sample config file includes examples of labels but, because they're not mandatory, you can remove, modify, or add new ones of your choice.

labels:
env: production
role: load_balancer

Example configurations

Here are some example YAML configurations:

Find and use data

Data from this integration can be found by going to: one.newrelic.com > Infrastructure > Third-party services > Apache.

Apache data is attached to the ApacheSample event type. You can query this data for troubleshooting purposes or to create custom charts and dashboards.

For more on how to find and use your data, see Understand integration data.

Metric data

The Apache integration collects the following metric data attributes. Each metric name is prefixed with a category indicator and a period, such as net. or server..

Name

Description

net.bytesPerSecond

Rate of the number of bytes served, in bytes per second.

net.requestsPerSecond

Rate of the number of client requests, in requests per second.

server.busyWorkers

Current number of busy workers.

server.idleWorkers

Current number of idle workers.

server.scoreboard.closingWorkers

Current number of workers closing TCP connection after serving the response.

server.scoreboard.dnsLookupWorkers

Current number of workers performing a DNS lookup.

server.scoreboard.finishingWorkers

Current number of workers gracefully finishing.

server.scoreboard.idleCleanupWorkers

Current number of idle workers ready for cleanup.

server.scoreboard.keepAliveWorkers

Current number of workers maintaining a keep-alive connection.

server.scoreboard.loggingWorkers

Current number of workers that are logging.

server.scoreboard.readingWorkers

Current number of workers reading requests (headers or body).

server.scoreboard.startingWorkers

Current number of workers that are starting up.

server.scoreboard.totalWorkers

Total number of workers available. Workers that are not needed to process requests may not be started.

server.scoreboard.writingWorkers

Current number of workers that are writing.

Inventory data

Inventory data captures the version numbers from running Apache and from all loaded Apache modules, and adds those version numbers under the config/apache namespace. For more about inventory data, see Understand data.

System metadata

Besides the standard attributes collected by the infrastructure agent, the integration collects inventory data associated with the ApacheSample event type:

Name

Description

software.version

The version of the Apache server. Example: Apache/2.4.7 (Ubuntu).

Troubleshooting

Check the source code

This integration is open source software. That means you can browse its source code and send improvements, or create your own fork and build it.

Copyright © 2024 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.