You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/send-data/collect-from-other-data-sources/azure-monitoring/collect-metrics-azure-monitor.md
+18-44Lines changed: 18 additions & 44 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,8 @@ sidebar_label: Collecting Metrics using ARM
5
5
description: Instructions for configuring a pipeline for shipping metrics available from Azure Monitor to Sumo Logic.
6
6
---
7
7
8
+
import useBaseUrl from '@docusaurus/useBaseUrl';
9
+
8
10
This section has instructions for configuring a pipeline for shipping metrics available from Azure Monitor to an Event Hub, on to an Azure Function, and finally to an HTTP source on a hosted collector in Sumo Logic. Azure Monitor collects metrics and well as logs. The pipeline described below is for metrics, not logs.
9
11
10
12
For information about Azure metrics, see [Overview of metrics in Microsoft Azure in Azure](https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/monitoring-overview-metrics) help.
@@ -17,7 +19,7 @@ Here’s how the solution fits together:
17
19
18
20
For more information about the solution strategy, see [Azure Monitoring](/docs/send-data/collect-from-other-data-sources/azure-monitoring).
@@ -35,50 +37,28 @@ In this step, you configure an HTTP source to receive logs from the Azure functi
35
37
In this step, you use a Sumo-provided Azure Resource Manager (ARM) template to create an Event Hub, an Azure function and two Storage Accounts. The Azure function is triggered by Event Hub. Two storage accounts are used to store log messages from the Azure function and failover data from Event Hub.
36
38
37
39
1. Download the [azuredeploy_metrics.json](https://raw.githubusercontent.com/SumoLogic/sumologic-azure-function/master/EventHubs/src/azuredeploy_metrics.json) ARM template.
38
-
1. Go to azure portal and search for **template deployment** in the search bar. Select **Template deployment (deploy using custom templates)** under **Marketplace**
1. Go to azure portal and search for **template deployment** in the search bar. Select **Template deployment (deploy using custom templates)** under **Marketplace**.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/azure-template-deploy.png')} alt="Azure template deploy" style={{border: '1px solid gray'}} width="800" />
41
+
1. On the **Custom deployment** blade, click **Build your own template in the editor**.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/custom-deployemnt.png')} alt="Custom deployment" style={{border: '1px solid gray'}} width="800" />
42
+
1. On the **Edit template** page, select **Load file** and upload the json file downloaded in the previous step. Click **Save**.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/azure-template-deploy2.png')} alt="Azure template deploy" style={{border: '1px solid gray'}} width="800" />
48
43
1. Now you are back on the **Custom deployment** blade.
49
-
50
44
1. Create a new Resource Group (recommended) or select an existing one.
51
45
1. Choose **Region**. The event hub namespace needs to be in the same region as the resource being monitored if the resource is regional.
52
46
1. For the **Sumo Endpoint URL** supply the URL for HTTP source you defined in [Step 1](#step-1-configure-an-http-source).
1. After clicking on **create** button, you will land to the **Deployment** page, you should see the **Your deployment is complete** message after deployment is finished:
1. After clicking on **create** button, you will land to the **Deployment** page, you should see the **Your deployment is complete** message after deployment is finished:<br/><img src={useBaseUrl('/img/send-data/azure-metrics/microsofttemplate_resource.png')} alt="Microsoft template resource" style={{border: '1px solid gray'}} width="800" />
61
49
1. Creating container for failover logs
62
-
63
50
1. Click on **Go to resource group** button in the **Deployment** page.
64
-
1. In the Resource Group window, search for `smfaillogs` in **Resources** Tab. Click on `smfaillogs<random-string>` storage account.
1. In the Resource Group window, search for `smfaillogs` in **Resources** Tab. Click on `smfaillogs<random-string>` storage account.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/storageaccount.png')} alt="Storage account" style={{border: '1px solid gray'}} width="800" />
52
+
1. Under **Data Storage**, click **Containers**, then **click + Container**, enter the **Name**`smfaillogs`. Click **Create**.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/containers.png')} alt="Containers" style={{border: '1px solid gray'}} width="800" />
71
53
72
54
### Step 3. Export metrics for a particular resource to Event Hub
73
55
74
56
Follow these steps to export metrics for a resource to Event Hub.
75
57
76
58
1. Go to the resource whose metrics you want to collect. In below example we are collecting `SQL database` metrics.
77
59
1. From the left pane, select **Diagnostic settings** under **Monitoring**.
1.**Diagnostic setting name**: Enter a name for the diagnostic setting.
83
63
1. In the left panel under **Metrics** section:
84
64
* Choose the metrics you want to collect or you can choose `AllMetrics` (if available) which enables collection for all the metrics. Do not select anything under `Logs` since logs and metrics needs to be exported in separate event hubs.
@@ -88,8 +68,7 @@ Follow these steps to export metrics for a resource to Event Hub.
88
68
* Select `SMNamespace<UniqueSuffix>` as the Event hub namespace.
89
69
* Select **insights-metrics-pt1m** as the event hub name.
90
70
* Select an event hub policy name. You can use the default policy **RootManageSharedAccessKey**.
1. Save the **Diagnostic settings**.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/diagnosticsetting.png')} alt="Diagnostic setting" style={{border: '1px solid gray'}} width="800" />
93
72
94
73
### Troubleshooting metrics collection
95
74
@@ -99,9 +78,9 @@ If metrics are not flowing into Sumo Logic, follow the steps below to investigat
99
78
100
79
First, make sure that the resources you created above were successfully created.
101
80
102
-
1.Go to **Resource groups**, and select the resource group you created or selected in [Step 2. Configure Azure resources using ARM Template](#step-2-configure-azure-resources-using-arm-template). You should see the seven resources you created: an App Service plan, an App Service, an Event Hubs Namespace, Application Insights, Log Analytics workspace and two Storage accounts.
81
+
Go to **Resource groups**, and select the resource group you created or selected in [Step 2. Configure Azure resources using ARM Template](#step-2-configure-azure-resources-using-arm-template). You should see the seven resources you created: an App Service plan, an App Service, an Event Hubs Namespace, Application Insights, Log Analytics workspace and two Storage accounts.
@@ -111,30 +90,25 @@ To verify that events are appearing in your event hub:
111
90
1. Scroll down and view the `Messages` chart
112
91
1. Check that the **Incoming Messages** count is greater than zero and the **Outgoing Messages** count is greater than zero. If there are no Incoming Messages then check the **Diagnostic Settings** are configured correctly or not. If there are no Outgoing Messages then [verify the trigger configuration in Function App](#verify-the-event-hub-trigger-configuration). If both are present then [verify the sumo logic HTTP source URL](#verify-sumo-logic-http-source-url).
1. Go to **Resource groups**, and select the resource group you created or selected in [Step 2. Configure Azure resources using ARM Template](#step-2-configure-azure-resources-using-arm-template). Search for `SMFuncApp`. You should find the `SMFuncApp<random-string>` Function App. Click it.
119
98
1. Under the **Functions** tab, click **EventHubs_Metrics**.
120
99
1. Under the **Developer** section, click **Integration**. Click on `Azure Event Hubs` under the **Triggers** section and verify the event hub configuration, this should be same as the one where you are exporting the logs.
1. Go to **Resource groups**, and select the resource group you created or selected in [Step 2. Configure Azure resources using ARM Template](#step-2-configure-azure-resources-using-arm-template). Search for `SMFuncApp`. You should find the `SMFuncApp<random-string>` Function App. Click it.
127
-
1. Click on **Configuration** under **Settings** in the left panel. Click on `SumoLabsMetricEndpoint`. Check that the value of the **SumoLabsMetricEndpoint** field matches the HTTP source URL.
1. Click on **Configuration** under **Settings** in the left panel. Click on `SumoLabsMetricEndpoint`. Check that the value of the **SumoLabsMetricEndpoint** field matches the HTTP source URL.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/sumolabsmetricendpoint.png')} alt="Application settings" style={{border: '1px solid gray'}} width="800" />
131
107
132
108
#### Verify Failure logs in Application Insights
133
109
134
110
1. Go to **Resource groups**, and select the resource group you created or selected in [Step 2. Configure Azure resources using ARM Template](#step-2-configure-azure-resources-using-arm-template). Search for `SMAppInsights`. You should find the `SMAppInsights<random-string>` Application Insights. Click it.
135
-
1. In the left panel under **Investigate** click on **Failures**. Click on **Count** column on the rightmost panel, it will take you to the trace, select any trace and see the exception message.
1. In the left panel under **Investigate** click on **Failures**. Click on **Count** column on the rightmost panel, it will take you to the trace, select any trace and see the exception message.<br/><img src={useBaseUrl('/img/send-data/azure-metrics/smappinsightfailures.png')} alt="Application insights" style={{border: '1px solid gray'}} width="800" />
0 commit comments