---
title: Troubleshoot a running infrastructure agent
source: https://docs.newrelic.com/docs/infrastructure/infrastructure-troubleshooting/troubleshoot-infrastructure/troubleshoot-running-infrastructure-agent
---

You can troubleshoot our infrastructure agent using our `newrelic-infra-ctl` utility. This binary is also included in the installation package, in the same directory as the `newrelic-infra` default binary.

Upon receiving the `newrelic-infra-ctl` command, the agent:

-   Enables [verbose logs](https://docs.newrelic.com/docs/infrastructure/new-relic-infrastructure/troubleshooting/generate-logs-troubleshooting-infrastructure) for a period of five minutes, then reverts the log level to its previous setting.
-   Logs all the agent config options.
-   Logs all the integrations config options.
-   Executes a health check for every loaded integration. (A health check is an immediate execution of the integration with extra logs and output validation.)

## Linux `newrelic-infra-ctl` [#binary-ctl-linux]

In Linux systems, the troubleshooting binary is `/usr/bin/newrelic-infra-ctl`, available in both the [package manager](https://docs.newrelic.com/docs/infrastructure/new-relic-infrastructure/installation/install-infrastructure-linux) or the [tarball assisted](https://docs.newrelic.com/docs/infrastructure/install-configure-infrastructure/linux-installation/assisted-install-infrastructure-linux) install methods.

> #### ⚠️ IMPORTANT
>
> When running on Linux, `newrelic-infra-ctl` must be executed by either the [root user or the same user](https://docs.newrelic.com/docs/infrastructure/install-configure-infrastructure/linux-installation/linux-agent-running-modes) running the `newrelic-infra` process.

The `newrelic-infra-ctl` binary can automatically detect the agent process running in the host. It can also detect whether the agent is running inside a container.

To change the default settings of `newrelic-infra-ctl`:

| To change...                                                                                                                                                                  | Execute                                            |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------- |
| [`pid`](https://docs.newrelic.com/docs/infrastructure/install-configure-infrastructure/linux-installation/manual-install-infrastructure-linux#change-pid)                     | `newrelic-infra-ctl -pid 14580`                    |
| `cid` (when using a containerized version of the agent)                                                                                                                       | `newrelic-infra-ctl -cid 8fddbcbb101c`             |
| [`docker-api-version`](https://docs.newrelic.com/docs/infrastructure/install-configure-infrastructure/configuration/infrastructure-configuration-settings#docker-api-version) | `newrelic-infra-ctl -docker-api-version 1.24`      |
| `container-runtime` (`docker` (default) or `containerd`)                                                                                                                      | `newrelic-infra-ctl -container-runtime containerd` |
| `containerd-namespace` (Namespace where the agent container is running)                                                                                                       | `newrelic-infra-ctl -containerd-namespace default` |

## Windows `newrelic-infra-ctl` [#binary-ctl-windows]

In Windows, using the MSI installer, the troubleshooting binary is `C:\Program Files\New Relic\newrelic-infra\newrelic-infra-ctl.exe`.

> #### ⚠️ IMPORTANT
>
> In Windows, the agent process is always automatically detected. It does not depend on the `pid` or the `cid`.
