Zip manual install of the infrastructure agent for Windows

Our custom installation process for the infrastructure agent for Windows allows you to tailor all aspects of the installation, and place files and folders wherever you want on your filesystem.

This method gives you full control of the installation: you are responsible for placing the files in the correct folders, providing the correct configuration values, and ensuring the agent has all the right permissions.

Before installation, check the compatibility and requirements.

Install the agent

To install the agent:

  1. Download the packaged agent file.
  2. Unpack the file.
  3. Make sure the file unpacks with the following structure:
    Infra-windows-files.png
  4. Install the service script.

Optionally, you can:

As of version 1.4.0, the infrastructure agent package includes the additional newrelic-infra-ctl binary, which is used to help troubleshoot a running agent. Although this binary is not required to execute the agent, we recommend to add it in your path. See our docs for more information.

Install the service script

To proceed with the installation, you need to create the service. Check the file provided in the zip file for reference:

C:\Program Files\New Relic\newrelic-infra\installer.ps1

Configuration file

The Infrastructure agent depends on a configuration file, usually named newrelic-infra.yml, placed in the same folder with the agent, to configure the agent's behavior. You can create a new config file based on config file template. For more information, see how to configure the agent.

Changing the config file's location

By default, the configuration file is located in C:\Program Files\New Relic\newrelic-infra\newrelic-infra.yml.

To change the location of the configuration file:

  1. Execute the command regedit.exe.
  2. Browse to the folder Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\newrelic-infra\ImagePath.
  3. Retrieve the ImagePath key. If the agent binary is on the default path, look for the key at C:\Program Files\New Relic\newrelic-infra\newrelic-infra.exe.
  4. Use the -config flag to add the new location of the configuration file to the key:

    C:\Program Files\New Relic\newrelic-infra\newrelic-infra.exe -config c:\config.yaml

Configure the plugin directory

The Infrastructure agent allows you to install integrations that monitor and report data from popular services such as Kubernetes, AWS, MySQL, Redis, Kafka, etc. Each integration has its own configuration file, named by default integration-name-config.yml, placed in the predefined location C:\Program Files\New Relic\newrelic-infra\integrations.d. On initialization, the agent loads the config file.

To overwrite the predefined location of the integration configuration file, use one of the following methods:

  • Set the location in the NRIA_PLUGIN_DIR environment variable.
  • Set the custom path in the newrelic-infra.yml configuration file using the plugin_dir field.
  • Pass it as a command line argument using -plugin_dir when you run the newrelic-infra binary.

Configure the agent directory

The agent requires its own defined directory to run the installed integrations, caching data (inventory), etc. The default location is C:\Program Files\New Relic\newrelic-infra\.

The agent directory has the following structure and content:

Additionally, the agent uses a different folder, app_data_dir, to store data. By default it points to C:\ProgramData\New Relic\newrelic-infra\.

To overwrite the predefined location of the agent directory, use one of the following methods:

  • Set the location in the NRIA_AGENT_DIR environment variable.
  • Set the custom path in the newrelic-infra.yml configuration file using the agent_dir field.
  • Pass it as a command line argument using -agent_dir when you run the newrelic-infra binary.

Configure the log file

By default the agent stores the log files in C:\Program Files\New Relic\newrelic-infra\newrelic-infra.log.

To overwrite the predefined location of the log file, use one of the following methods:

  • Set the location in the NRIA_LOG_FILE environment variable.
  • Set the custom path in the newrelic-infra.yml configuration file using the log_file field.
  • Pass it as a command line argument using -log_file when you run the newrelic-infra binary.

What's next?

You may also want to:

For more help

If you need more help, check out these support and learning resources: