• /
  • EnglishEspañol日本語한국어Português
  • Log inStart now

Reduce data ingested

If you've reviewed your data ingestion and want to send less data and reduce the data ingested, we have these solutions for you:

  • Set global.lowDataMode

  • Change the scrape interval

  • Filter namespaces

Let's explain each option.

Reduce data ingested by setting global.lowDataMode

If you're looking to cut costs, you can modify the global.lowDataMode parameter value. This will cut down on the number of metrics you send. The modification of this parameter will depend on the method you used to install Kubernetes:

The lowDataMode parameter affects these specific components of the nri-bundle chart:

Reduce data ingested by changing the scrape interval

The New Relic Kubernetes integration allows you to change the scrape interval when metrics are gathered from the cluster. This lets you choose the right balance between data resolution and usage. We suggest choosing a scrape interval between 15 and 30 seconds for the best experience.

Tip

The lowDataMode parameter already sets the scrape interval to 30 seconds.

The way you modify the scrape interval depends on the method you used to install Kubernetes:

  • Guided install (New Relic CLI, Helm, manifest): You can't modify this value following our guided install flow.

  • Helm: Set the scrape interval in the nri-bundle chart to the value you want.

  • Manifest: Set the scrape interval in the manifest configuration YAML file to the value you want. If you followed our installation instructions, the file was called newrelic-manifest.yaml.

If you're using Helm or manifest and want to change the scrape interval, just add the interval value under the newrelic-infrastructure section. Take a look at this example of the values-newrelic.yaml file to see how it looks for Helm:

global:
licenseKey: _YOUR_NEW_RELIC_LICENSE_KEY_
cluster: _K8S_CLUSTER_NAME_
# ... Other settings
# Configuration for newrelic-infrastructure
newrelic-infrastructure:
# ... Other settings
common:
config:
interval: 25s

Important

Note that if you're using the cluster explorer instead of the Kubernetes navigator, you're not allowed to set interval to values greater than 40s.

Reduce data ingested by filtering namespaces

You can label namespaces to filter which ones the Kubernetes integration scrapes. All namespaces scrape by default.

We use the namespaceSelector in the same way Kubernetes does. To include only namespaces matching a label, just change the namespaceSelector. Add the following to your values-newrelic.yaml file, under the newrelic-infrastructure section:

common:
config:
namespaceSelector:
matchLabels:
key1 : "value1"

Examples with namespaces

You can see a full list of settings that you can modify in the chart's README file.

How can I find out which namespaces are excluded?

The K8sNamespace sample shows all the namespaces within the cluster. The nrFiltered attribute determines whether we're going to scrape the data related to the namespace. This query shows you which namespaces are being monitored:

FROM K8sNamespaceSample SELECT displayName, nrFiltered WHERE clusterName = <clusterName> SINCE 2 MINUTES AGO

What data is being discarded from the excluded namespaces?

These samples won't be available for the excluded namespaces:

  • K8sContainerSample
  • K8sDaemonsetSample
  • K8sDeploymentSample
  • K8sEndpointSample
  • K8sHpaSample
  • K8sPodSample
  • K8sReplicasetSample
  • K8sServiceSample
  • K8sStatefulsetSample
  • K8sVolumeSample
Copyright © 2024 New Relic Inc.

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