Version 4

    Prerequisites:

     

    To connect with your Azure account, the following parameters are required:

         subcriptionID,ApplicationID,TenantID, Secret Key, Application Name

         Note: Azure App to monitor, with its name and ID, should have role set as 'contributor or Reader' in the Azure access control.

        2. Application name for which metrics will be calculated.

        3. Time interval for which data has to be fetched (in hours).

        4. PowerShell version supported 5.1 or above.

     

    Script Argument:

    • Login credential to access Azure Portal. Azure details have to be passed in script arguments as per prerequisite #2.

                 Example:

                 <SubscriptionID>,<TenantID>,<ApplicationID>,secretKey=<Enter SecretKey>,<ApplicationName>,TimeRange=<Time in hrs>

    • The ApplicationID with which you are making a connection to the Azure portal (as mentioned in Credential/Prerequisites) must be registered in Azure Active Directory as a contributor role for the monitored application.

            Reference link: https://support.solarwinds.com/Success_Center/Server_Application_Monitor_(SAM)/Knowledgebase_Articles/Add_an_Azure_Active_Directory_app_for_cloud_monitoring_in_the_Orion_Platform

     

    Portions of this document were originally created by and are excerpted from the following sources:

    https://docs.microsoft.com/en-us/azure/app-service/web-sites-monitor  

    https://docs.microsoft.com/en-us/powershell/azure/authenticate-azureps?view=azurermps-6.7.0

    https://docs.microsoft.com/en-us/powershell/module/azurerm.insights/?view=azurermps-6.7.0&viewFallbackFrom=azurermps6.7.0#monitor

     

    MONITORED COMPONENTS

     

    • Average number of bytes sent

          This monitor provides the average number of bytes sent for the given app.

          Unit: MB (Mega Bytes)

    • Total number of 2xx requests

          This monitor provides the count of requests resulting in an HTTP status code >= 200 but < 300 for the given app.

          Unit: Count

    • Total number of 3xx requests

          This monitor provides the count of requests resulting in an HTTP status code >= 300 but < 400 for the given app.

          Unit: Count

    • Total number of 401 requests

          This monitor provides the count of requests resulting in HTTP 401 status code for the given app.

          Unit: Count

    • Total number of 403 requests

          This monitor provides the count of requests resulting in HTTP 403 status code for the given app.

          Unit: Count

    • Total number of 404 requests

          This monitor provides the count of requests resulting in HTTP 404 status code for the given app.

          Unit: Count

    • Total number of 406 requests

          This monitor provides the count of requests resulting in HTTP 406 status code for the given app.

          Unit: Count

    • Total number of 4xx requests

          This monitor provides the count of requests resulting in an HTTP status code >= 400 but < 500 for the given app.

          Unit: Count

    • Total number of 5xx requests

          This monitor provides the count of requests resulting in an HTTP status code >= 500 but < 600 for the given app.

          Unit: Count

    • Total number of requests served by the app

          This monitor provides the total number of requests regardless of their resulting HTTP status code for the given app.

          Unit: Count

    • Average number of bytes received

          This monitor provides the average number of bytes received for the given app.

          Unit: MB (Mega Bytes)

    • Average memory used

          This monitor provides the average amount of memory in MBs used by the given app.

          Unit: MB (Mega Bytes)

    • Average response time

          This monitor provides the average time taken for the app to serve requests in milliseconds (ms).

          Unit: MS (Milliseconds)

     

    TROUBLESHOOTING STEPS

    Detailed troubleshooting steps (common for template):

     

    Check that the PowerShell version is 5.1 or more and the Azure module is installed on the system where the template will run.

    Template uses PowerShell components; script should run with administrator privilege.

    Be sure to detail troubleshooting steps (specific for components).

     

    Components connect with Azure using service principal authentication for which application has to be created at the Azure portal. See below link:

         https://docs.microsoft.com/en-us/azure/azure-stack/azure-stack-create-service-principals

     

    Provide Azure IAM permission to the application, which was created in the last step. See below link:

         https://support.solarwinds.com/Success_Center/Server_Application_Monitor_(SAM)/Knowledgebase_Articles/Configure_Azure_IAM_permissions_for_cloud_monitoring_in_the_Orion_Platform

     

    Script fetch data based on time range given in last script arguments. By default, script fetch data for the past hour. While giving the time range, make sure the data is available for the metric at that time, otherwise the component will be unable to fetch the data.