Introduction
The Azure Enhanced Monitoring Extension for SAP provides configuration information and performance data of the underlying Azure infrastructure and makes it available to the SAP application. It contains built-in self-diagnostics which enables identification of the health and completeness of the infrastructure data required by SAP services and support.
Having set up the Azure Enhanced Monitoring Extension for SAP, the Windows service AzureEnhancedMonitoring is installed inside the VM and collects all Azure-related data. Afterwards, this data is consumed by SAP Host Agent for further use in the SAP system transaction ST06.
Setup Azure Enhanced Monitoring(AEM) for SAP
- Check the status in ST06 before enabling AEM

- Open RemoteDesktop Session and login as admin user
- Open the PowerShell and Check the Power Shell version
$PSVersionTable.PSVersion
Major Minor Build Revision
—– —– —– ——–
5 1 17763 1007
Azure PowerShell works with PowerShell 5.1 or higher on Windows. To run Azure PowerShell in PowerShell 5.1 on Windows:
- Update to Windows PowerShell 5.1 if needed. If you’re on Windows 10, you already have PowerShell 5.1 installed.
- Install .NET Framework 4.7.2 or later.
- Install the Azure Module for PowerShell
Install-Module -Name Az -AllowClobber -Scope AllUsers
- Run the following PowerShell cmdlet
$env = Get-AzEnvironment -Name AzureCloud
Connect-AzAccount -Environment $env


Set-AzContext -SubscriptionName <subscription name>

Set-AzVMAEMExtension -ResourceGroupName <resource group name> -VMName <virtual machine name>

Above screen shows status as OK for the AEM deployment.
- Test the AEM Deployment
Test-AzVMAEMExtension -ResourceGroupName <resource group name> -VMName <virtual machine name>

- Readiness check for the AEM deployment
Perform the check by performing following step.
- Open the command prompt in the VM and change to directory to the installation folder of the Azure Extension for SAP. C:\Packages\Plugins\Microsoft.AzureCAT.AzureEnhancedMonitoring.AzureCATExtensionHandler\<version>\drop
- At the command prompt, run azperflib.exe without any parameters

Health status and Diagnostics status are in OK state. Empty Counters are 0.
- Confirm the status in Tr Code ST06

This completes the setup of Azure Enhanced Monitoring for SAP on Windows Operating System.
Azure Enhanced Monitoring Extension (New Version)
Microsoft has released a New version of AEM for SAP and its suitable for specific scenarios as mentioned below, otherwise its perfectly fine to use the version and steps mentioned above.
- You want to install the extension with Terraform, Azure Resource Manager Templates or with other means than Azure CLI or Azure PowerShell.
- Microsoft or SAP support asks you to install the new extension
- You want to use Azure Ultra Disk or Standard Managed Disks
Prechecks :
- Make sure to use SAP Host Agent 7.21 PL 47 or higher.
- Make sure to uninstall the current version of the VM Extension for SAP. You can do this from Azure portal by selecting the ‘Extentions’ in the Settings section for the VM. It is not supported to install both versions of the VM Extension for SAP on the same virtual machine.
Steps :
Following are the PowerShell commands to run to setup the AEM for SAP.
$env = Get-AzEnvironment -Name <name of the environment>
Connect-AzAccount -Environment $env Set-AzContext -SubscriptionName <subscription name>
Set-AzVMAEMExtension -ResourceGroupName <resource group name> -VMName <virtual machine name> -InstallNewExtension

Testing :
Test the AEM deployment by executing the PowerShell script.
Test-AzVMAEMExtension -ResourceGroupName <resource group name> -VMName <virtual machine name>

Readiness Check :
- Open a web browser and navigate to http://127.0.0.1:11812/azure4sap/metrics
- The browser should display or download an XML file that contains the monitoring data of your virtual machine.
- Check the value of the Provider Health Description element, value must be OK.
