The singleton APM agent has already been instantiated and can no longer be configured

Elastic version: 8.5.3
APM agent version 1.22 and 1.20
Runtime: .NET Framework 4.7.4050.0
CPU architecture: X64

I'm trying to install Elastic APM profiler on Windows IIS 10 application pool (Framework).
I did it for 100 application pool till now, and no issues until today.

After setting the same configuration, one of the application pool hang, and stop (after few minutes or after recycle)

I can see in the APM agent logs 2 files
w3wp_13404_-1326190937.agent.log
w3wp_13404_-1326193125.agent.log
They are almost the same - You can see it use the same w3wp pid
I see in the windows event log the application pool crush
I found in the files the error in the APM log:

The singleton APM agent has already been instantiated and can no longer be configured

I looked in the troubleshooting page about it, (Link but I using the profiler, how to avoid this? do you think it related ?

all other application pool on the same server are working.

Anyone?
Need help to solve the problem.

Hi @Dov ,

could you show us the full log file with the The singleton APM agent has already ... message?

How did you configure the agent? Only by setting the environment variables for the app pool? Or do you also have a direct reference to any of our agent NuGet packages?

Hi,

I only did the environment variables for the app pool.
And nothing else, I saw it againg in different application pool I installed, but the agent failed and not the application pool (It happened with Microsoft dynamics).

I will send a full log later this week.

Thank you

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.