Overview
Agent Control provides a seamless and centralized way to manage the entire lifecycle of your agents, including updates. Instead of manually updating agents on each host or cluster, you define your desired state in Fleet Control, and Agent Control automatically handles the rest.
Agent Control can upgrade itself as part of your Fleet Control deployments, so it stays current without a separate upgrade campaign. You update the agents it manages by changing their version in your fleet configuration.
Key benefits of the update process with New Relic Control
- Centralized control: Manage all agent versions for your entire fleet from a single location.
- Automated: Once you define a new version, the deployment and reconciliation process is handled automatically.
- Protected installs: On hosts, Agent Control checks a new version before it replaces the running one. On Kubernetes, a rolling update keeps the old pods running until the new ones are healthy. See If an Agent Control upgrade fails.
Importante
Agent Control doesn't roll back an upgrade automatically once the new version is running. To learn what is and isn't protected, see If an Agent Control upgrade fails.
Updating your managed Agents
You can update any agent managed by Agent Control by simply changing its version in the remote configuration within Fleet Control. This declarative approach ensures consistency and reliability across your entire fleet.
- Edit the Configuration: Navigate to the configuration for your fleet in Fleet Control.
- Update the Version: Locate the agent you want to update (for example,
infrastructure) and change thechart_versionvalue to the new version number. - Deploy the Changes: Save and deploy the updated configuration.
Agent Control will automatically detect the change and perform a non-disruptive rolling update, ensuring that your new agents are running and healthy before replacing the old ones.
Example: Upgrading the New Relic infrastructure agent
This example shows how to upgrade the infrastructure agent to a new version.
# Remote configuration for a single agentchart_version: "5.0.109" # Change this valuechart_values: newrelic-infrastructure: enableProcessMetrics: trueHow Agent Control upgrades with Fleet Control
When you push a deployment in Fleet Control, Fleet Control checks whether a newer version of Agent Control is available for the managed entities in that fleet. If one is, the upgrade is included in your deployment.
- The Agent Control team releases a new version to the release channel.
- You push a deployment in Fleet Control. The Agent Control upgrade is included with it.
- Agent Control upgrades itself, and your managed agents receive only the configuration changes you requested.
Agent Control upgrades as part of a deployment and not between deployments. For the deployment side of this process, see Automatic Agent Control upgrades in the Fleet Control documentation.
Importante
If you installed Agent Control during the limited or public preview, before general availability, your version might not support upgrades through Fleet Control. In that case, upgrade Agent Control manually to the latest version once, for example by running the guided install again. After that, Fleet Control can include future upgrades in your deployments.
On a host, an upgrade restarts Agent Control. It stops the agents it manages first and starts them again after the new version is running, so expect a short gap in data from those agents. On Kubernetes, Flux replaces the Agent Control pods with a rolling update, and your managed agents keep running.
Release channels
A release channel is a track of Agent Control releases that you subscribe to. Each channel has its own policy for when a new version arrives, based on factors such as how long a release has been available and how proven it is.
Fleet Control offers one channel, Rapid. It carries the latest production-ready Agent Control release. A new version arrives with your next deployment in Fleet Control, which is also how upgrades work for Agent Control on Kubernetes. You can't select a different channel or choose the version Fleet Control upgrades to.
Upgrading Agent Control
Upgrade Agent Control through Fleet Control on every platform. The upgrade is part of your deployment, as described in How Agent Control upgrades with Fleet Control.
Kubernetes
The following instructions apply to Agent Control running on a Kubernetes cluster.
Fleet Control includes the Agent Control upgrade in your deployment, as described in How Agent Control upgrades with Fleet Control. When a newer version is available, the deployment page shows a notice that Agent Control will be updated. You don't need to change the Agent Control version in its configuration. This keeps the Agent Control running on your cluster up to date with the latest features, fixes, and security patches.
The upgrade triggers a rolling update of the Agent Control pods on your cluster. Kubernetes' built-in health checks ensure the new version is healthy before the old one is terminated for a non-disruptive upgrade.
Linux and Windows hosts
On Linux and Windows hosts, Fleet Control also includes the Agent Control upgrade in your deployment. You don't need to change the Agent Control version in your fleet configuration.
Cuidado
Fleet Control is the way to upgrade Agent Control on a host. Upgrading it with your package manager (apt-get, zypper, or yum) or by re-running the installation script isn't recommended.
Managed agents (Infrastructure Agent, NRDOT) are upgraded the same way as on Kubernetes. Update the desired agent version in your fleet configuration and deploy the changes.
If an Agent Control upgrade fails
How Agent Control manages a failed upgrade depends on the platform:
- Linux and Windows hosts: Before Agent Control replaces itself, it runs the new version once to confirm that it can start, load its configuration, and connect to Fleet Control. If that check fails, or the download or signature check fails, the current version keeps running and the deployment shows as FAILED. Deploying a different desired version starts a new attempt right away. If the cause is permanent, such as a package that fails signature verification, the upgrade keeps failing and the deployment stays FAILED until you fix the cause or deploy a different version. The check runs before the swap, so it can't catch a version that passes it and then breaks later.
- Kubernetes: The rolling update keeps the old Agent Control pods running until the new pods are ready.
Once a new version is running, Agent Control doesn't roll back to the previous version on its own. To recover from a bad version, move forward to a corrected version, which Fleet Control includes in your next deployment. To see what failed, check the deployment details in Fleet Control. See also Automatic Agent Control upgrades.
Start, stop, and restart Agent Control
Agent Control starts automatically after you run the installation script.
Linux
For Linux, ensure you use the correct command for your init system. Select start, stop, restart, or status as appropriate.
Here's an example for systemd:
$sudo systemctl <start|stop|restart|status> newrelic-agent-controlWindows
Run these commands in PowerShell with Administrator privileges:
Start-Service -Name newrelic-agent-controlStop-Service -Name newrelic-agent-controlRestart-Service -Name newrelic-agent-controlGet-Service -Name newrelic-agent-control