Though the APM .NET agent will report activity to and from the Portal for ArcGIS Server, you'll not have instrumentation through the entire software stack without instrumenting Portal itself. That's where the Java agent and some configuration come in. Behind the ports of 7080 and 7443 lies another web server. Portal for ArcGIS Server is built on top of several other distinct technologies, one of them being an Apache Tomcat application server. Using New Relic's Java agent, we'll instrument the Tomcat Catalina servlet at the heart of Portal for ArcGIS Server.
1. Copy the agent to the machine, granting permissions to the folder as appropriate (permissions should be granted to the user that is starting the Portal for ArcGIS Server service).
2. Edit the YML file, updating the name, license key, and proxy information if needed.
3. Edit the Catalina.bat file here by default, C:\Program Files\ArcGIS\Portal\framework\runtime\tomcat\bin\catalina.bat
a. Locate the line “set TOMCAT_HEAP_SIZE=” (around line 85 for Portal 10.3 and 10.4)
b. Add the following line directly after the heap size parameter “set JAVA_OPTS= %JAVA_OPTS% -javaagent:"C:/Program Files/ArcGIS/Portal/framework/newrelic/newrelic.jar"” In this case I had placed the agent in the framework folder as the account running the service has access to this folder already.
4. Restart the Portal for ArcGIS Server service.
The .NET agent alone is great, but the two together complete the real picture.
Now we can see the entire Portal stack as one.
Check out my other how-to articles to this series showing you how to;