• /
  • Log in
  • Free account

SNMP monitoring integration (legacy)


Have you tried our new network performance monitoring?

Collect both SNMP and Network Flows to answer the question Is it the network? faster.

Our SNMP integration monitors any application that exposes metrics with SNMP.

Read on to install the integration, and to configure a YAML file to start collecting metrics. This doc also contains sample YAML files to help you get started.

Compatibility and requirements

Our integration is compatible with SNMP version 2 or 3.

Before installing the integration, make sure that you meet the following requirements:

Install and activate

To install the SNMP integration, follow the instructions for your environment:

Additional notes:


Configure the integration

There are several ways to configure the integration, depending on how it was installed:

An integration's YAML-format configuration is where you can place required login credentials and configure how data is collected. Which options you change depend on your setup and preference.

The configuration file has common settings applicable to all integrations, such as interval, timeout, inventory_source. To read all about these common settings, refer to our Configuration Format document.


If you are still using our legacy configuration/definition files, please refer to this document for help.

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

SNMP Instance Settings

The SNMP integration collects both metrics and inventory information. The type of metrics collected is determined by the information added to the metrics collection file:





Hostname or IP where SNMP is running.



Port on which SNMP is listening.



Request timeout in seconds.



Number of retries in case of timeout.



Doubles timeout value in each retry attempt.



Use SNMP version 3.



The SNMP community string. Only for SNMP v2.



Security identifier for v3 user. Only for SNMP v3.



Security level. Only for SNMP v3.
Valid options are:

  • noAuthnoPriv
  • authNoPriv
  • authPriv



Authentication protocol. Only for SNMP v3.
Valid options are:

  • MD5
  • SHA



Password used to generate the key for authentication. Only for SNMP v3.



Encryption protocol. Only for SNMP v3.
Valid options are:

  • AES
  • DES



Password used to generate the key used to encrypt messages. Only for SNMP v3.



Comma-separated list of full file paths to metric collection definition files.


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

  • Adding the value directly in the config file. This is the most common way.
  • Replacing the values from environment variables using the {{}} notation. This requires infrastructure agent v1.14.0+. Read more here or see the example below.
  • Using secrets management. Use this to protect sensitive information, such as passwords that would be exposed in plain text on the configuration file. For more information, see Secrets management.

Metric collection files

The metrics collection definition files are structured YAML files which tell the integration what metrics to collect. For an example configuration, see the metrics collection file example.

Sample metrics collection file: /etc/newrelic-infra/integrations.d/snmp-metrics.yml.sample


You can write different collection files to ease organization and maintenance. See configuration file below for an example.


A collection file collects and organizes metrics. Each file contains a single collect: block which contains one or more devices. For each device, the following keys are defined:

  • device: The name of the SNMP device from which metrics are being collected. This field is required.
  • metrics_sets: A list of metric sets that organize metrics to collect from this device. See Metric Sets.
  • inventory: A list of Object Identifiers (OIDs) to collect from this device and report as inventory. See Inventory.

Metric Sets

Metrics Set represents a logical grouping of SNMP Object Identifiers (OIDs) to get from the SNMP device and report to New Relic. For each metric set, the following keys are defined:

  • name: The metric set name.

  • event_type: The event type name for a collection from this metric set.

    For tips on naming event types, see Naming tips.

  • type: The metric set type. Use scalar to describe a metric set of SNMP scalar OIDs or table to describe a metric set that corresponds to the metrics from an SNMP table.

  • root_oid: If type is a table, enter the root OID of the table. The integration performs an SNMP walk from this OID to get the table metrics.

  • index: If type is a table, enter one or more table column index OIDs that define the table's row uniquely. For each index OID, the following keys are defined:

    • oid: The OID name to collect, for example, . This field is required.
    • name: The name under which the metric will appear in New Relic. If unspecified, it will default to the OID name.
  • metrics: List of SNMP OIDs to be collected as part of this metric set. Enter a list of scalar OIDs or table column OIDs as appropriate for the type.

    • oid: The OID name to collect, for example,​. This field is required.
    • metric_name: The name under which the metric will appear in New Relic. If unspecified, it will default to the OID name.
    • metric_type: The New Relic metric type to collect this attribute as. Options are gauge, delta, pdelta, rate, prate or attribute. If unspecified, the integration attempts to infer the metric type .


Inventory is an array of SNMP Object Identifiers (OIDs) to be collected and reported as inventory items. For each OID, the following keys are defined:

  • oid: The OID name to collect, for example, This field is required.
  • category: The category name under which the inventory item will appear in New Relic. This field is required.
  • name: The name under which the inventory item will appear in New Relic. This field is required.

Example configurations

For more about the general structure of on-host integration configuration, see Configuration.

Tips for naming your data

Metrics are sent and stored in the form of samples. This is a list of key-value pairs that include metric data and metadata. Each sample is stored as an event in New Relic’s event database.

You are responsible for creating and naming the SNMP data reported to New Relic. For this reason, New Relic strongly recommends following these conventions when naming your event types. To ensure you have a consistent naming scheme:

  • Use camel case.
  • Use a name that clearly identifies what data it contains.

Example: MyorgApplicationSample

Recommendation: Use the same naming scheme for similar metrics across different applications.

Find and use data

Data from this service is not reported to an integration dashboard because the samples gathered are generally unique to the device being monitored. You will need to build your own dashboard.

SNMP metrics are attached to the user defined event type specified in the configuration file. 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 metrics generated by the integration include metadata associated with the collection they are collecting from. This metadata should be used in NRQL queries to filter and facet the data so that the query returns only the data for the desired metric set.

Each event contains the following metadata:




The device name for these metrics.


The SNMP host the metrics are being collected from.


The SNMP port the metrics are being collected from.


The metric set name for these metrics.

Inventory data

The SNMP integration captures the configuration parameters of the SNMP integration. The data is available on the Infrastructure Inventory page, under the config/snmp source. For more about inventory data, see Understand integration data.


Troubleshooting tips:

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.

Create issueEdit page
Copyright © 2022 New Relic Inc.