Important
Agent Control and New Relic Control are now generally available for Kubernetes! Support for Linux hosts and Windows hosts is also in public preview program, pursuant to our pre-release policies.
Agent Control provides a seamless approach for configuration independenlty of the environment where it is deployed. Two methods for managing agent configurations are available:
Local configuration: A comprehensive
values.yamlfile used during the initial Helm installation.Remote configuration: A centralized, YAML-based configuration you create in New Relic Control that is remotely deployed to your entire fleet.
Remote configuration is the recommended method for day-to-day management. It ensures consistent agent behavior across your environment, simplifies change management, and enables you to scale without manually updating local YAML files on each host.
Tip
The values-newrelic.yaml file, which traditionally defined New Relic agent settings, now also includes configuration for Agent Control. The parameters you define in this file determine how both Agent Control and its managed agents operate. This file is referred to as the local configuration.
Understanding the two layers of configuration
Agent Control's configuration is structured in two layers:
Agent Control's core configuration: These are the top-level settings that control how Agent Control operates, such as its connection to New Relic, its identity, and fleet management details.
Managed agents' configurations: These are the individual
chart_valuesfor each subagent (for example., Infrastructure Agent, Fluent Bit) that Agent Control deploys and manages.
When a local and remote configuration are both present, Agent Control applies the following logic:
- Remote configuration takes precedence. Any settings defined in a remote configuration from New Relic Control will override the corresponding settings in the local
values.yamlfile. - To intentionally override remote settings with your local configuration, you can deploy an empty remote configuration via New Relic Control. This change will apply to all clusters in the selected fleet.
Kubernetes configuration
These instructions and examples apply to Agent Control running on a Kubernetes cluster.
Local values.yaml configuration for Kubernetes
The local configuration file for Kubernetes, used during installation, contains all the settings for Agent Control and its managed agents.
This example shows the two layers of configuration within a single file.
The sample demonstrates how to configure Agent Control along with two managed agents: the Kubernetes infrastructure agent and Fluent Bit for log forwarding. For example, if you don't want to send health metrics for your Fluent Bit log collector, simply set sendMetrics: false in the YAML file before running the install command.
Remote configuration for Kubernetes
Remote configuration ensures consistent agent behavior across your environment, simplifies change management, and enables you to scale observability without manually managing local YAML files.
To deploy configurations centrally across clusters, define this same YAML content in the Configurations section of Fleet Control. You can then apply the configuration to an entire fleet of clusters as part of a remote deployment. This is referred to as the remote configuration file.
Tip
When you define a configuration in the New Relic Control UI, the YAML structure is different. You only provide the YAML that corresponds to the content block for a single agent.
Sample configurations: Agent Control on Kubernetes
configurations: Agent Control on Kubernetes The following examples show how to configure Agent Control to manage different sets of agents. These configurations can be used either during initial installation or as part of a remote configuration in Fleet Control.
To explore all available configuration settings, refer to values-newrelic.yaml.
The following examples show how to configure Agent Control with a set of subagents using the local values.yaml file.
Agent Control with New Relic infrastructure and Fluent Bit
This example deploys Agent Control with infrastructure monitoring and Fluent Bit for log collection.
Agent Control with OpenTelemetry and custom collector settings
with OpenTelemetry and custom collector settings
This example deploys Agent Control with the New Relic distribution of OpenTelemetry (NRDOT) collector and disables the filelog receiver in the managed nr-k8s-otel-collector Helm chart.
Important
Security Best Practice: Do not store sensitive values like your license key directly in the configuration. We recommend using a Kubernetes secret. Agent Control can then securely pull these values from the secret at runtime.
Sample configurations: Remote Agent Configurations on Kubernetes
The following examples show how to configure individual agents remotely from the New Relic Control UI.
Remote configuration: New Relic infrastructure
This example shows how to remotely configure the New Relic infrastructure agent for Kubernetes using Fleet Control. It enables process metrics collection by setting enableProcessMetrics: true.
Remote configuration: Fluent Bit
This example configured Fluent Bit remotely via Fleet Control. It enables health metric reporting from the log collector by setting sendMetrics: true.
Remote configuration: Prometheus
This example configures the Prometheus agent remotely using Fleet Control. It enables low-data mode to reduce telemetry volume and disable default integrations.
Remote configuration: OpenTelemetry
This example configures the New Relic OpenTelemetry collector and enable lowDataMode as a valid option.
Important
Security Best Practice: Do not store sensitive values like your license key directly in the configuration. We recommend using a Kubernetes secret. Agent Control can then securely pull these values from the secret at runtime.
Proxy configuration for Kubernetes
Agent Control supports proxy configuration to route traffic through corporate proxies. Proxy settings can be set through environment variables or directly in the configuration file.
Proxy precedence
Agent Control will use proxy settings in the following order of precedence:
proxyconfiguration field in the Agent Control configurationHTTP_PROXYenvironment variableHTTPS_PROXYenvironment variable
Proxy configuration with self-signed certificates
For proxy setups using HTTPS authentication with self-signed certificates, you need to provide the CA certificate bundle and configure proxy authentication:
Proxy configuration for managed agents
Caution
Configuring a proxy in Agent Control does not automatically configure the same proxy settings for the agents it manages. Each agent has its own proxy configuration that must be set separately according to that agent's specific configuration format and requirements.
When using a proxy, you must also configure proxy settings for each managed agent individually. Refer to each agent's specific documentation for proxy configuration options.
Secrets management
Agent Control provides a robust mechanism for managing sensitive data, such as passwords and API keys, by retrieving them from dedicated secret providers. This ensures that sensitive information is not hard-coded directly into configuration files. The system currently supports the providers described in Value providers.
Private repository configuration
Agent Control supports configuring private Helm repositories to deploy both Agent Control itself and the managed agents. This enables environments where the New Relic Helm charts are not directly accessible.
Caution
When using private Helm repositories, the charts need to be compatible and the referenced images within the charts must be reachable. If not, the agents will not work as expected.
1. Enable private repositories for agents
For security reasons, only explicitly enabled repositories are allowed in remote configurations. To enable specific repositories, update the Agent Control configuration as follows:
The allowed repository configurations can then be used in your remote configurations within New Relic Control. Example:
chart_version: "1.2.3"chart_repository: url: "https://my-private-repository-1" name: "my-chart-name" # Optional: use only if the chart name doesn't match New Relic's chart nameAdditionally, you need to configure Agent Control's Helm installation to use your private repository if the agent-control-bootstrap chart itself is in a private repository. This is separate from the configuration for managed agents. Refer to the agent-control-bootstrap Helm chart values.yaml to configure the installationJob section as follows:
chartRepositoryUrl: The URL containing your repository location.chartName: The chart name if using a different chart name.repositorySecretReferenceNameandrepositoryCertificateSecretReferenceName: The secrets required for authenticating to your repository. See the authentication section below for details.
2. Set up authentication for private repositories
You need to set up additional resources to enable authentication for accessing your private repository as follows:
Linux configuration
These are the default paths for Agent Control configuration:
Localconfiguration file:/etc/newrelic-agent-control/config.yamlRemoteconfiguration file:/var/lib/newrelic-agent-control/config.yaml(if enabled via Fleet Control deployment)- Service definition:
/lib/systemd/system/newrelic-agent-control.service - Service environment file:
/etc/newrelic-agent-control/newrelic-agent-control.conf
By default, the agent might orchestrate the infrastructure agent and the OpenTelemetry collector:
# Configures the integration with Fleet Controlfleet_control: # EU region? Use: https://opamp.service.eu.newrelic.com/v1/opamp # JP region? Use: https://opamp.service.jp.newrelic.com/v1/opamp endpoint: https://opamp.service.newrelic.com/v1/opamp headers: api-key: YOUR_INGEST_KEY auth_config: # EU region? Use: https://system-identity-oauth.service.eu.newrelic.com/oauth2/token # JP region? Use: https://system-identity-oauth.service.jp.newrelic.com/oauth2/token token_url: "https://system-identity-oauth.service.newrelic.com/oauth2/token" client_id: "YOUR_CLIENT_ID provider: "local" private_key_path: "path/to/key"
# Configures the agents to be supervised by Agent Controlagents: # Agent name (RFC-1035 valid label) nr-infra-agent: # The supported agent type and agent type version agent_type: "newrelic/com.newrelic.infrastructure:0.1.0" nr-otel-collector: agent_type: "newrelic/com.newrelic.opentelemetry.collector:0.1.0"You can rename or remove either agent based on your observability requirements. Agent name must be a valid RFC-1035 label name.
You can also use environment variables to define the agent settings:
- Use the
NR_(single underscore) prefix to target the main Agent Control configuration. - Use
__(double underscores) to target the available settings in Agent Control. This is required to avoid collisions with configuration keys that contain underscores. - Environment variables only have predencende over the local configuration file. If remote configuration is enabled, then environment variables are not considered.
- For example, to define a dynamic configuration for the
fleet_control::endpointadd theNR_FLEET_CONTROL__ENDPOINT=https://opamp.service.newrelic.com/v1/opampin the service definition file.
Configure the agents
Agent Control can currently manage the following pre-defined on-host agent types:
- New Relic infrastructure agent:
newrelic/com.newrelic.infrastructure. All existing features in the infrastructure agent are supported, including orchestrating on-host integrations and our log forwarder integration based on FluentBit. - New Relic distribution for OpenTelemetry:
newrelic/com.newrelic.opentelemetry.collector
Each agent type offers a set of optional variables that can be customized to tailor its behavior. To customize the agent local configuration:
- Create a
values.ymlfile: This file will contain your desired configuration values. - Place the
values.ymlfile in the/etc/newrelic-agent-control/fleet/agents.d/YOUR-AGENT-NAME/values/directory. Here,YOUR-AGENT-NAMEis the actual name of your agent (for example,nr-infra-agent).
Here's a list of available variables for the latest agent type versions:
- New Relic infrastructure agent:
0.1.0 - New Relic distribution for OpenTelemetry:
0.1.0
Agent type | Variable | Type | Default |
|---|---|---|---|
|
| A YAML containing infrastructure agent configurations | (empty) |
|
| A YAML map (keys are file names) containing on-host integration configurations | (empty) |
|
| A YAML map (keys are file names) containing log forwarding configurations | (empty) |
|
| Port for the infrastructure agent local status server |
|
|
| OpenTelemetry collector configuration (in YAML format) | (empty) |
|
| Path and port for the OTel collector health check extension local http endpoint |
|
All managed agents |
| Time until next retry if collector fails to start (in seconds). |
|
Tip
You can configure the infrastructure agent settings and OpenTelemetry collector settings as needed following the supported configurations.
Sample configurations
Remote Configuration with Fleet Control
The following examples contain common use cases that are ready to copy and paste as valid configurations for Agent Control and managed agents.
Windows configuration
These are the default paths for Agent Control configuration on Windows:
Localconfiguration file:C:\Program Files\New Relic\newrelic-agent-control\local-data\agent-control\local_config.yamlRemoteconfiguration file:C:\ProgramData\New Relic\newrelic-agent-control\fleet-data\agent-control\remote_config.yaml(synced from Fleet Control)- Service executable:
C:\Program Files\New Relic\newrelic-agent-control\newrelic-agent-control.exe - Log directory:
C:\ProgramData\New Relic\newrelic-agent-control\logs\
By default, Agent Control on Windows can orchestrate the infrastructure agent and the OpenTelemetry collector:
# Configures the integration with Fleet Controlfleet_control: endpoint: https://opamp.service.newrelic.com/v1/opamp headers: api-key: YOUR_INGEST_KEY auth_config: token_url: "https://system-identity-oauth.service.newrelic.com/oauth2/token" client_id: "YOUR_CLIENT_ID" provider: "local" private_key_path: "path\\to\\key"
# Configures the agents to be supervised by Agent Controlagents: # Agent name (RFC-1035 valid label) nr-infra-agent: # The supported agent type and agent type version agent_type: "newrelic/com.newrelic.infrastructure:0.1.0" nr-otel-collector: agent_type: "newrelic/com.newrelic.opentelemetry.collector:0.1.0"Tip
For regional accounts, use the appropriate endpoint and token_url:
- EU region:
https://opamp.service.eu.newrelic.com/v1/opampandhttps://system-identity-oauth.service.eu.newrelic.com/oauth2/token - JP region:
https://opamp.service.jp.newrelic.com/v1/opampandhttps://system-identity-oauth.service.jp.newrelic.com/oauth2/token
You can rename or remove either agent based on your observability requirements. Agent name must be a valid RFC-1035 label name.
Windows-specific configuration notes
- File paths use backslashes (
\\) and Windows-style paths (for example,C:\\ProgramData\\...) - Agent binaries use
.exeextensions - The service runs as
LocalSystem— ensure configuration files have restricted write permissions - Templates and configurations from Linux environments may require path adjustments for Windows compatibility
Configure agents
Agent Control on Windows can currently manage the following agent types:
- New Relic infrastructure agent:
newrelic/com.newrelic.infrastructure. Supports on-host integrations and log forwarding via the built-in Fluent Bit. - New Relic distribution for OpenTelemetry:
newrelic/com.newrelic.opentelemetry.collector
To customize agent local configuration, place a values.yml file in the agent's values directory. The available variables are the same as for Linux hosts.
Sample configurations
Remote configuration with Fleet Control
Value providers
Value providers allow Agent Control resolve values from external sources when a configuration is rendered, so sensitive data such as license keys, tokens, or passwords doesn't need to be hard-coded in your configuration files.
Values are referenced with the ${NAMESPACE:NAME} placeholder syntax inside agent configurations. Agent Control resolves them every time a configuration is applied, including remote configuration updates, so rotated values are picked up without restarting Agent Control.
Important
If Agent Control fails to resolve a value, the configuration rendering fails and the agent isn't started. This prevents agents from running with incomplete or incorrect configurations.
After a successful resolution, Agent Control stores the rendered result in a Kubernetes secret or in a private configuration file for use by the corresponding agent.
Supported value providers
Provider | Placeholder namespace | Requires configuration |
|---|---|---|
Environment variables |
| No |
HashiCorp Vault |
| Yes |
Local files |
| No |
Kubernetes secrets |
| No |
Kubernetes ConfigMaps |
| No |
Configuring value providers
Only HashiCorp Vault requires explicit configuration. Define it under the value_providers key of the Agent Control configuration. The legacy key secrets_providers is still accepted as an alias.
value_providers: vault: sources: local-instance: url: http://localhost:8200/v1/ token: root engine: kv2 remote: url: http://my-remote-server:8200/v1/ token: root engine: kv1 client_timeout: 10s
fleet_control: ...
agents: ...Each entry under sources defines a named Vault source with the following settings:
YAML key | Required | Description |
|---|---|---|
| Yes | Full Vault URL, including the |
| Yes | Token used to authenticate against the endpoint. |
| Yes | Secrets engine version: |
| No | HTTP timeout for Vault requests. Defaults to |
Environment variables: nr-env
Reads a value from the host environment (available to Agent Control process).
config_agent: license_key: "${nr-env:NEW_RELIC_LICENSE_KEY}"HashiCorp Vault: nr-vault
Reads a key from a Vault KV secret. Requires the value_providers.vault configuration described above.
The placeholder uses this format:
"${nr-vault:SOURCE_NAME:MOUNT:PATH:KEY}"SOURCE_NAME: name of the Vault source defined invalue_providers.MOUNT: name of the secrets engine mount.PATH: path to the secret.KEY: key within the secret to retrieve.
For example:
config_agent: enable_process_metrics: true custom_attributes: username: "${nr-vault:local-instance:secret:my_secret:username}" organization: "${nr-vault:remote:my_mount:my_path:organization}"Here, ${nr-vault:local-instance:secret:my_secret:username} retrieves the value of the username key from the secret at secret/my_secret using the local-instance source, and ${nr-vault:remote:my_mount:my_path:organization} retrieves the organization key from the remote source.
Local files: nr-file
Reads the contents of a local file, trimming leading and trailing whitespace.
The placeholder takes the absolute path to the file:
config_agent: license_key: "${nr-file:/etc/newrelic/license.key}"Kubernetes secrets: nr-kubesec
Reads a key from a Kubernetes secret. Available on Kubernetes only, and requires no additional configuration as long as the Agent Control pod has permissions, through a service account and RBAC, to access the required secrets and namespaces.
The placeholder uses this format:
"${nr-kubesec:NAMESPACE:SECRET_NAME:KEY}"NAMESPACE: namespace where the secret is located.SECRET_NAME: name of the Kubernetes secret object.KEY: key within the secret to retrieve.
Kubernetes ConfigMaps: nr-kubecm
Reads a key from a Kubernetes ConfigMap. Available on Kubernetes only, and requires no additional configuration as long as the Agent Control pod has permissions to access the required ConfigMaps and namespaces.
The placeholder uses this format:
"${nr-kubecm:NAMESPACE:CONFIGMAP_NAME:KEY}"NAMESPACE: namespace where the ConfigMap is located.CONFIGMAP_NAME: name of the Kubernetes ConfigMap object.KEY: key within the ConfigMap to retrieve.