# Install APM Insight .NET and .NET Core Agent For seamless onboarding, you can use the [APM Insight AutoProfiler](https://www.manageengine.com/products/applications_manager/help/apm-insight-autoprofiler-overview.html) to automatically discover and instrument .NET applications running on your server. To add a new .NET Agent monitor in Applications Manager, go to the **APM tab** → **Add New Monitor** → **.NET**. Based on the version of the build you are using, follow the steps given below to add a .NET Agent monitor: - [Guided installation - Build version 172100 and above](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-install.html#172100andabove) - [Manual installation - Build versions below 172100](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-install.html#below172100) > **Note:** > > - Make sure to uninstall any third-party profilers before installing the APM Insight .NET agent. > - It is recommended to run a checksum validation to verify the integrity of the downloaded agent. [Learn more](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-checksum-validation.html) > - Monitoring the application in a SharePoint/Multi-Domain Assembly Mode Environment requires specific workaround changes due to security concerns. This is especially true in scenarios where the same code runs in different domains. [Learn more](https://pitstop.manageengine.com/portal/en/kb/articles/troubleshooting-steps-to-identify-and-resolve-the-crashing-issue-while-monitoring-the-applications-in-sharepoint-multiple-domain-assembly-environments#Understanding). > - For non-desktop Windows server types, the GUI tools of the .NET Agent are inaccessible due to platform constraints. In such cases, users can access the features through the configuration files located in *C:\ProgramData\DotNetAgent*: > - **appfilter.conf**, **windows_appfilter.conf** and **standalone_appfilter.xml** - Utilize these files to include/exclude selective applications from monitoring. Refer to this [KB](https://pitstop.manageengine.com/portal/en/kb/articles/how-can-i-configure-application-filtering-for-net-agent-on-non-desktop-windows-servers) for more information. > - **custom_instrumentation.json** - Use this file for [manual custom instrumentation](https://www.manageengine.com/products/applications_manager/help/apminsight-dotnet-agent-custom-instrumentation-manual-configuration.html). ![Applications Manager APM Insight Install .NET and .NET Core agent: Adding the agent](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-add-monitor-1.png) ## Add a new .NET Agent monitor - Guided Installation (Build version 172100 & above) 1. Choose between 'Host' and 'Container' based on the **deployment type** of your .NET application and click Next. ![Applications Manager APM Insight Install .NET and .NET Core agent: Selecting deployment type](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-add-monitor-3.png) 2. Review and select the required options in the **configuration** tab based on your application's environment. The Advanced Settings dropdown displays the details of your Applications Manager build such as the protocol, host, port, and APM Insight license key. > **Note:** Ensure that the Applications Manager URL is reachable from the application server. If not, use the **EDIT** option to provide the accessible IP address or hostname for the agent to connect and communicate with the Applications Manager. ![Applications Manager APM Insight Install .NET and .NET Core agent: Configuring the agent](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-add-monitor-2.png) Click on Next. 3. Go to the server where the application is installed, open Windows PowerShell with administrator privileges, and execute the command displayed in the **Monitor Addition** view to complete the agent installation. > **Note:** This command internally downloads the guided-installation PowerShell script and .NET Agent from Applications Manager to complete the agent installation. ![Applications Manager APM Insight Install .NET and .NET Core agent: Monitor addition using command execution](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-add-monitor-4.png) > **Note:** Use the **Switch to manual steps** option in the Applications Manager UI if any environmental issues cause command execution failure, to follow the [Manual Installation](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-install.html#below172100) steps. 4. Once the agent installation is successful, please perform some transactions to start monitoring your .NET application. > **Note:** > > - By default, the IIS RESET command will be executed by the agent unless it is unchecked in the APM GUI while adding the monitor. In that case, ensure IIS RESET is performed manually during your application's downtime. > - The monitor will be added in Applications Manager only when some transactions are performed in your .NET application after IIS RESET. ## Add a new .NET Agent monitor - Manual Installation (Build versions below 172100) The .NET agent can be installed in build versions below 172100 using either of the following methods: - [Direct installation](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-install.html#direct) - [Installation via command line](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-install.html#cmd) - [Bulk installation](https://www.manageengine.com/products/applications_manager/help/apm-insight-dotnet-agent-bulk-installation.html) ## Direct installation 1. Download the latest [APM Insight .NET agent](https://www.manageengine.com/products/applications_manager/apm-insight-agent-installation.html#dotnetAgent) (**apminsight-dotnetagent.msi**) file. 2. Execute the **.msi** file. This opens a "Select installation folder" window. 3. Click on **Browse** and select the folder path to install the .NET Agent. Click **Next**. ![Applications Manager APM Insight Install .NET and .NET Core agent: Direct installation of .NET agent](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-install-1.png) 4. In the next window, under the **Startup Options**, check the **Start the Agent after installation** check-box if you wish to start the agent. Click **Next** to start the installation of the agent. ![Applications Manager APM Insight Install .NET and .NET Core agent: Configuring IIS restart after installation](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-install-3.png) > **Note:** This will restart IIS to start the agent. 5. The configuration window will appear before the installation is completed. Configure Applications Manager's **License Key**, **Host**, and **Port**, along with optional proxy authentication settings if the environment is behind a proxy. ![Applications Manager APM Insight Install .NET and .NET Core agent: Agent configuration window](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-install-2.png) **For version 7.0.2 and above** ![Applications Manager APM Insight Install .NET and .NET Core agent: Agent configuration window](https://www.manageengine.com/products/applications_manager/help/images/apm-insight-dotnet-agent-install-4.png) > **Note:** > > - To monitor an application in a SharePoint or Multi-Domain Assembly Mode environment, enable the **Support Multi-Domain Application** option. This may slightly increase CPU utilization due to single-domain conversion. > - Data Exporter will be installed while installing the agent. 6. Click the **Save** button to complete the installation. ## Installation via command line If you would like to monitor a Windows Core environment or similar environments, you may find it easiest to install the .NET agent via the command line. Follow the below steps to install via command line: 1. Download the latest [APM Insight .NET agent](https://www.manageengine.com/products/applications_manager/apm-insight-agent-installation.html#dotnetAgent) (**apminsight-dotnetagent.msi**) file. 2. Open the command prompt and navigate to the path where you have downloaded the *.msi* file. 3. Execute the following command to install the agent: **For version 7.0.2 and above** ```bash msiexec -i apminsight-dotnetagent.msi license.key= apm.host=://: apm_exporter_host= apm_exporter_status_port= apm_exporter_data_port= editconfig=false iisreset=true /log apm_install.log /quiet ``` Given configurations are optional: - *apm_exporter_host* By default, **DATA_EXPORTER_HOST=localhost** - *apm_exporter_status_port* By default, **DATA_EXPORTER_STATUS_PORT=20021** - *apm_exporter_data_port* By default, **DATA_EXPORTER_DATA_PORT=20022** **For versions below v6.7.1 to v6.9.2** ```bash msiexec -i apminsight-dotnetagent.msi license.key= apm.host=://: editconfig=false iisreset=true /log apm_install.log /quiet ``` **For version 6.5.1 to 6.7.0** ```bash msiexec -i apminsight-dotnetagent.msi license.key= apm.host= apm.port= apm.protocol.https=True editconfig=false iisreset=true /log apm_install.log /quiet ``` **Command-line arguments:** - *editconfig* - The agent will open the edit configuration window by default. Set this to *false* to install the agent without opening the edit configuration window. - *iisreset* - Agent will reset IIS by default. Set this to *false* to install without resetting IIS. > **Note:** The agent can monitor the applications only after running the *iisreset* command. 4. Once the installation is complete, perform some transactions to start monitoring. Now the APM Insight .NET agent is ready and all the ASP.NET applications (such as WCF) running on the server will be monitored. After some transactions are performed, the collected data should be available in the **APM** tab of Applications Manager's web client within a few minutes. All .NET web applications hosted on the IIS will be monitored. Perform some transactions to start monitoring. > **Note:** If the APM Insight agent is not installed in admin mode, install it using the below command from the command prompt, which defines the AppManager hostname in the APMInsight.Net agent configuration window and performs a few transactions within the application. The application's data will be displayed within the APMInsight instance in the Applications Manager. ```bash msiexec -i apminsight-dotnetagent.msi ```