Compatibility and requirements for the .NET Core agent

New Relic for .NET Core includes built-in instrumentation for the most popular components of the Microsoft .NET Core ecosystem. The agent runs within the monitored process; there is no separate process or service associated with the agent. The .NET Core agent supports a variety of operating systems and app frameworks.

For how to install New Relic APM for .NET, see .NET agent install.

Requirements

Before you install the New Relic for .NET Core agent, make sure your system meets these requirements:

The .NET Core agent currently supports .NET Core version 2.0, 2.1, and 2.2.

The agent is not compatible with .NET Core versions 1.0 or 1.1. For .NET Core 2.1 or higher applications with tiered compilation enabled, the agent will disable tiered compilation.

The .NET Core agent only supports applications targeting .NET Core 2.0, 2.1, and 2.2. The target framework can be found in your .csproj file:

Supported:

<TargetFramework>netcoreapp2.0</TargetFramework>
<TargetFramework>netcoreapp2.1</TargetFramework>
<TargetFramework>netcoreapp2.2</TargetFramework>

Unsupported:

<TargetFramework>net452</TargetFramework>

If you are trying to monitor an ASP.NET Core application targeting the .NET Framework, you'll need to use the Framework agent.

Ensure you use one of these app/web servers:

  • Kestrel
  • Kestrel with IIS reverse proxy via AspNetCoreModule
  • Kestrel with IIS reverse proxy via AspNetCoreModuleV2
  • Kestrel with Nginx reverse proxy
  • Kestrel with Apache reverse proxy

The agent has been verified to work with the following operating systems:

Operating system Supported versions
Windows

Server 2008 R2 SP1

Server 2012

Server 2012 R2

Server 2016

Linux (x64 only)

All x64 Linux distributions supported by .NET Core Runtime are supported by the .NET Core agent. For a full list, refer to Microsoft's documentation for the version of the runtime you are using.

Microsoft Azure

For Azure-specific installation instructions, see:

The agent is available in both 32-bit (x86) and 64-bit versions on Windows as well as 64-bit on Linux.

Installing and running the .NET Core agent requires these permissions:

Component Necessary permissions
Install the agent The process or user that installs the agent must have sufficient permissions to set environment variables and write access to the directory where the agent is installed.
Run the agent The monitored process must have read/write access to the directory in which you installed the agent. The permissions grant is attached to the monitored process because the agent runs inside the monitored process.

As a standard security measure for data collection, your app server must support SHA-2 (256-bit). SHA-1 is not supported.

The agent requires your firewall to allow outgoing connections to specific networks and ports.

Instrumented features

If your app is hosted in ASP.NET Core, the agent automatically creates and instruments transactions. The list of instrumented features below are supported by the .NET Core agent, for which the agent collects additional detail. You can also extend your instrumentation with custom instrumentation and the agent API.

The .NET Core agent includes default instrumentation for these frameworks and features:

The .NET Core agent automatically instruments the performance of .NET application calls to these datastores:

Datastore Instance details Notes
Microsoft SQL Server fa-check Using System.Data.SqlClient version 4.3.1
PostgresSQL fa-check Using Npgsql version 3.2.4
MongoDB fa-check

Using driver version 2.3.x, 2.4.x, 2.5.x, or 2.6.x

Driver version 2.7.x: The .NET agent will support pre-existing API methods, but not new methods introduced in 2.7.x.

MySQL fa-check Using MySql.Data version 6.10.4

The .NET Core agent does not directly monitor datastore processes. Also, the .NET SQL parameter capture in a query trace does not list parameters for a parameterized query or a stored procedure.

Collecting instance details for supported datastores is enabled by default. To request instance-level information from datastores not currently listed, get support at support.newrelic.com.

The .NET Core agent automatically instruments these application frameworks:

  • ASP.NET Core MVC 2.0, 2.1, and 2.2 (includes Web API)

The .NET Core agent automatically instruments these external call libraries :

Libraries Supported methods
HttpClient

The agent instruments these HttpClient methods:

  • SendAsync
  • GetAsync
  • PostAsync
  • PutAsync
  • DeleteAsync
  • GetStringAsync
  • GetStreamAsync
  • GetByteArrayAsync

Unavailable features

The following features are not available for the .NET Core agent:

Connect the agent to other New Relic products

In addition to New Relic APM, the .NET Core agent integrates with other New Relic products to give you end-to-end visibility:

Product Integration
New Relic Browser

The New Relic Browser JavaScript agent will not be injected by the .NET Core agent for asp.net core applications. However, you can inject the Browser agent by using the .NET agent API or the Browser agent's copy/paste method.

After enabling Browser injection, you can view Browser data in the APM Overview page and quickly switch between the APM and Browser data for a particular app. For configuration options and manual instrumentation, see New Relic Browser and the .NET agent.

New Relic Infrastructure When you install the Infrastructure and APM agents on the same host, they automatically detect one another. You can then view a list of hosts in the APM UI, and filter your Infrastructure hosts by APM app in the Infrastructure UI. For more information, see New Relic APM data in Infrastructure.
New Relic Insights The .NET agent sends default events and attributes to Insights for NRQL queries. You can also record custom events for advanced analysis.

For more help

Recommendations for learning more: