Net core agent doesn't work with IIS and AspNetCoreModule

Unzip net core agent to folder, setting up environment variables, restart iis and set write rule for IIS AppPool user to folder with agent, but agent doesn’t work.

1 Like

Hello @doctis,

Thanks for posting in the forum about the .NET Core agent!

First of all, I wanted to confirm that your Microsoft .NET Core version is 2.0 or higher.

Also, our Core agent does not support ASP.NET Core applications targeting the .NET Framework. You can verify your setup is supported by navigating to your application’s .csproj file.

If you see <TargetFramework>netcoreapp2.0</TargetFramework> then you should be good, but if you see <TargetFramework>net452</TargetFramework> or similar, then I’m afraid this is not supported.

It sounds like the server you are using is Kestrel with IIS reverse proxy via AspNetCoreModule which should work.

A few questions I have:

  • Is this a local or global install?

  • Would you mind letting me know the environment variables you have set, excluding the license key info?

  • Can you confirm you selected either the 32-bit or 64-bit version of the agent, depending on the bitness of your system?

  • Are any logs appearing in the logs folder of the installation directory?

  • Can you verify both read & write access to the installation folder are granted?

Thanks! I hope we’re able to help get this working.

1 Like

I’m experiencing the same problem as the OP. I’ve actually had a screenshare session with a NewRelic support rep, and they were as stumped as me as to why it’s not working.

  • We’re targetting netcoreapp2.0
  • Local install
  • 64-bit version of agent
  • No logs appearing in logs folder (or even Event Log)
  • Read/write access was fine when we checked
    ** Is there a specific user I should double check access for?

Environment variables are set exactly as outlined on the install directions page: Installation Docs. Net-core NewRelic agent was installed using the “Local Install using Options” instructions on that same page. May or may not be worth noting that my app is a web-api app, no front end except for dashboard interfaces of libraries we use (swagger, hangfire).

Hey @sclyde! I see that you also opened a private ticket about this and are working with our .NET SMEs right now! Please feel free to give us any updates in the community as you work through this! :blush:

1 Like

Hello all; I come bearing good news. I got on a 2nd call with NewRelic support this morning, and we tracked down the issue and resolved this problem (in my environments).

Essentially what was happening is the %CORECLR_NEWRELIC_HOME% that is referenced in %CORECLR_PROFILER_PATH% environment variable is not being transformed. We were able to identify this issue using a Process Monitor tool. We were able to resolve this by “hard coding” the path into the CORECLR_PROFILER_PATH environment variable so that it did not reference CORECLR_NEWRELIC_HOME.

They mentioned that they will be looking into the root issue, such that one variable could correctly reference the other. In the meantime, others experiencing this issue should be able to update their path, reset IIS, and be good to go!

Hope that helps.


That IS super helpful, @sclyde! Thank you! I am happy to hear that our Support Engineers were able to point you in the right direction. :blush:

Please update us if you learn more in the meantime!

We have

  • global configuration, because we are using IIS with AspNetCoreModule
  • x64
  • We doesn’t have any logs in a installation directory
  • We adding AppPool user with read/write rules
  • Env:

@sclyde, thanks! But it doesn’t help for me.

HI @doctis,

Can you tell us a little about the application you’re trying to monitor?

  • What is the value of the <TargetFramework> attribute of your application’s .csproj file?
  • What type of application is it (ASP.NET Web App, WebAPI, console/service application)?

Thank you,


Hi @dmorris, of course.

  • TargetFramework is netcoreapp2.0
  • AspNet Core MVC and AspNet Core API projects.

Hi there @doctis,

In order to look into this more thoroughly, I’ve created a support ticket. Once we’re able to resolve the issue, I’ll be happy to report our findings back here in case anyone else experiences the same issue.


1 Like

Hi @doctis and anyone else having trouble with the .NET Core agent — @dmorris has written an excellent post on troubleshooting the .NET Core installation.

It covers the installation issues we’ve seen so far.

Here’s the link — I hope this helps!

1 Like

Thanks! It was so helpful!

1 Like

I am getting below error

Hey @hammad.haqqani! I think I am missing something: could you share what error you are getting so we can help you troubleshoot the issue? Screenshots are always helpful, too!