Skip to content

Commit 1ad090b

Browse files
amee-sumosachin-sumologicjpipkin1
authored
Update Azure Storage with Azure metrics source compatibility (#5447)
* Update azure-storage.md * added momitors section for azure storage app * Update docs/integrations/microsoft-azure/azure-storage.md Co-authored-by: John Pipkin (Sumo Logic) <[email protected]> * Update docs/integrations/microsoft-azure/azure-storage.md Co-authored-by: John Pipkin (Sumo Logic) <[email protected]> * added momitors section for azure storage app --------- Co-authored-by: Sachin Magar <[email protected]> Co-authored-by: Sachin Magar <[email protected]> Co-authored-by: John Pipkin (Sumo Logic) <[email protected]>
1 parent 666ee3d commit 1ad090b

File tree

1 file changed

+30
-112
lines changed

1 file changed

+30
-112
lines changed

docs/integrations/microsoft-azure/azure-storage.md

Lines changed: 30 additions & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -59,121 +59,15 @@ Azure service sends monitoring data to Azure Monitor, which can then [stream dat
5959

6060
* Logs collection from [Azure Monitor](https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/monitoring-get-started) using our [Azure Event Hubs source](/docs/send-data/collect-from-other-data-sources/azure-monitoring/ms-azure-event-hubs-source/).
6161
* Activity Logs collection from [Azure Monitor](https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/monitoring-get-started) using our [Azure Event Hubs source](/docs/send-data/collect-from-other-data-sources/azure-monitoring/ms-azure-event-hubs-source/). It is recommended to create a separate source for activity logs. If you are already collecting these logs, you can skip this step.
62-
* Metrics collection using our [HTTP Logs and Metrics source](/docs/send-data/collect-from-other-data-sources/azure-monitoring/collect-metrics-azure-monitor/) via Azure Functions deployed using the ARM template.
62+
* Metrics collection using our [Azure Metrics Source](/docs/send-data/hosted-collectors/microsoft-source/azure-metrics-source).
6363

6464
You must explicitly enable diagnostic settings for each storage service (blob, queue, table, and file) and each storage account that you want to monitor. You can forward logs to the same event hub provided they satisfy the limitations and permissions as described [here](https://learn.microsoft.com/en-us/azure/azure-monitor/essentials/diagnostic-settings?tabs=portal#destination-limitations).
6565

6666
When you configure the event hubs source or HTTP source, plan your source category to ease the querying process. A hierarchical approach allows you to make use of wildcards. For example: `Azure/Storage/Logs`, `Azure/Storage/Metrics`.
6767

68-
### Configure field in field schema
69-
1. [**Classic UI**](/docs/get-started/sumo-logic-ui-classic). In the main Sumo Logic menu, select **Manage Data > Logs > Fields**. <br/>[**New UI**](/docs/get-started/sumo-logic-ui). In the top menu select **Configuration**, and then under **Logs** select **Fields**. You can also click the **Go To...** menu at the top of the screen and select **Fields**.
70-
1. Search for following fields:
71-
- `tenant_name`. This field is tagged at the collector level and users can get the tenant name using the instructions here https://learn.microsoft.com/en-us/azure/active-directory-b2c/tenant-management-read-tenant-name#get-your-tenant-name
72-
- `location`. The region to which the resource name belongs.
73-
- `subscription_id`. Id associated with a subscription where the resource is present.
74-
- `resource_group`. The resource group name where the Azure resource is present.
75-
- `provider_name`. Azure resource provider name (for example, Microsoft.Storage).
76-
- `resource_type`. Azure resource type (for example, storageaccounts).
77-
- `resource_name`. The name of the resource (for example, storage account name).
78-
- `service_type`. Type of the service that can be accessed from with an Azure resource (for example, blobservices).
79-
- `service_name`. Services that can be accessed from within an Azure resource (for example, Azure SQL databases in Azure SQL Server).
80-
81-
82-
3. Create the fields if it is not present. Refer to [create and manage fields](/docs/manage/fields/#manage-fields).
83-
84-
### Configure Field Extraction Rules
85-
86-
Create a Field Extraction Rule (FER) for Azure Storage by following the instructions [here](/docs/manage/field-extractions/create-field-extraction-rule/).
87-
88-
* **Azure Location Extraction FER**
89-
90-
```sql
91-
Rule Name: AzureLocationExtractionFER
92-
Applied at: Ingest Time
93-
Scope (Specific Data): tenant_name=*
94-
```
95-
96-
```sql title="Parse Expression"
97-
json "location", "properties.resourceLocation", "properties.region" as location, resourceLocation, service_region nodrop
98-
| replace(toLowerCase(resourceLocation), " ", "") as resourceLocation
99-
| if (!isBlank(resourceLocation), resourceLocation, location) as location
100-
| if (!isBlank(service_region), service_region, location) as location
101-
| if (isBlank(location), "global", location) as location
102-
| fields location
103-
```
104-
105-
* **Resource ID Extraction FER**
106-
107-
```sql
108-
Rule Name: AzureResourceIdExtractionFER
109-
Applied at: Ingest Time
110-
Scope (Specific Data): tenant_name=*
111-
```
112-
113-
```sql title="Parse Expression"
114-
json "resourceId", "ResourceId" as resourceId1, resourceId2 nodrop
115-
| if (isBlank(resourceId1), resourceId2, resourceId1) as resourceId
116-
| toUpperCase(resourceId) as resourceId
117-
| parse regex field=resourceId "/SUBSCRIPTIONS/(?<subscription_id>[^/]+)" nodrop
118-
| parse field=resourceId "/RESOURCEGROUPS/*/" as resource_group nodrop
119-
| parse regex field=resourceId "/PROVIDERS/(?<provider_name>[^/]+)" nodrop
120-
| parse regex field=resourceId "/PROVIDERS/[^/]+(?:/LOCATIONS/[^/]+)?/(?<resource_type>[^/]+)/(?<resource_name>.+)" nodrop
121-
| parse regex field=resource_name "(?<parent_resource_name>[^/]+)(?:/PROVIDERS/[^/]+)?/(?<service_type>[^/]+)/?(?<service_name>.+)" nodrop
122-
| if (isBlank(parent_resource_name), resource_name, parent_resource_name) as resource_name
123-
| fields subscription_id, location, provider_name, resource_group, resource_type, resource_name, service_type, service_name
124-
```
125-
### Configure metric rules
126-
127-
* **Azure Observability Metadata Extraction Service Level**
128-
129-
In case this rule is already exists then no need to create again.
130-
```sql
131-
Rule Name: AzureObservabilityMetadataExtractionServiceLevel
132-
```
133-
134-
```sql title="Metric match expression"
135-
resourceId=/SUBSCRIPTIONS/*/RESOURCEGROUPS/*/PROVIDERS/*/*/*/*/* tenant_name=*
136-
```
137-
| Fields extracted | Metric rule |
138-
|------------------|----------------|
139-
| subscription_id | $resourceId._1 |
140-
| resource_group | $resourceId._2 |
141-
| provider_name | $resourceId._3 |
142-
| resource_type | $resourceId._4 |
143-
| resource_name | $resourceId._5 |
144-
| service_type | $resourceId._6 |
145-
| service_name | $resourceId._7 |
146-
147-
* **Azure Observability Metadata Extraction Storage Account Level**
148-
```sql
149-
Rule Name: AzureObservabilityMetadataExtractionStorageAccountLevel
150-
```
151-
152-
```sql title="Metric match expression"
153-
resourceId=*/SUBSCRIPTIONS/*/RESOURCEGROUPS/*/PROVIDERS/*/*/* tenant_name=* accountresourceid=*
154-
```
155-
| Fields extracted | Metric rule |
156-
|------------------|----------------|
157-
| subscription_id | $resourceId._1 |
158-
| resource_group | $resourceId._2 |
159-
| provider_name | $resourceId._3 |
160-
| resource_type | $resourceId._4 |
161-
| resource_name | $resourceId._5 |
162-
16368
### Configure metrics collection
16469

165-
In this section, you will configure a pipeline for shipping metrics from Azure Monitor to an Event Hub, onto an Azure Function, and finally to an HTTP Source on a hosted collector in Sumo Logic.
166-
167-
1. Create a hosted collector and tag the `tenant_name` field
168-
<img src={useBaseUrl('img/integrations/microsoft-azure/Azure-Storage-Tag-Tenant-Name.png')} alt="Azure Storage Tag Tenant Name" style={{border: '1px solid gray'}} width="800" />
169-
2. [Configure an HTTP Source](/docs/send-data/collect-from-other-data-sources/azure-monitoring/collect-metrics-azure-monitor/#step-1-configure-an-http-source).
170-
1. [Configure and deploy the ARM Template](/docs/send-data/collect-from-other-data-sources/azure-monitoring/collect-metrics-azure-monitor/#step-2-configure-azure-resources-using-arm-template).
171-
1. [Export metrics to Event Hub](/docs/send-data/collect-from-other-data-sources/azure-monitoring/collect-metrics-azure-monitor/#step-3-export-metrics-for-a-particular-resource-to-event-hub). Perform the steps below for each storage service (blob, queue, table, and file) and each storage account that you want to monitor.
172-
* Choose `Stream to an event hub` as the destination.
173-
* Select `Transaction`.
174-
* Use the Event hub namespace created by the ARM template in Step 2 above. You can create a new Event hub or use the one created by the ARM template. You can use the default policy `RootManageSharedAccessKey` as the policy name.
175-
4. Tag the location field in the source with the right location value.
176-
<img src={useBaseUrl('img/integrations/microsoft-azure/Azure-Storage-Tag-Location.png')} alt="Azure Storage Tag Location" style={{border: '1px solid gray'}} width="500" />
70+
To set up the Azure Metrics source in Sumo Logic, refer to [Azure Metrics Source](/docs/send-data/hosted-collectors/microsoft-source/azure-metrics-source).
17771

17872
### Configure logs collection
17973

@@ -209,15 +103,27 @@ In **Defender Plans** settings page turn on the **Azure Storage** status under *
209103

210104
Now that you have set up data collection, install the Azure Storage Sumo Logic app to use the pre-configured [dashboards](#viewing-the-azure-storage-app-dashboards) that provide visibility into your environment for real-time analysis of overall usage.
211105

212-
import AppInstallNoDataSourceV2 from '../../reuse/apps/app-install-index-apps-v2.md';
106+
import AppInstallIndexV2 from '../../reuse/apps/app-install-index-option.md';
107+
108+
<AppInstallIndexV2/>
213109

214-
<AppInstallNoDataSourceV2/>
110+
As part of the app installation process, the following fields will be created by default:
111+
112+
- `tenant_name`. This field is tagged at the collector level. You can get the tenant name using the instructions [here](https://learn.microsoft.com/en-us/azure/active-directory-b2c/tenant-management-read-tenant-name#get-your-tenant-name).
113+
- `location`. The region the resource name belongs to.
114+
- `subscription_id`. ID associated with a subscription where the resource is present.
115+
- `resource_group`. The resource group name where the Azure resource is present.
116+
- `provider_name`. Azure resource provider name (for example, Microsoft.Network).
117+
- `resource_type`. Azure resource type (for example, storage accounts).
118+
- `resource_name`. The name of the resource (for example, storage account name).
119+
- `service_type`. Type of the service that can be accessed with an Azure resource.
120+
- `service_name`. Services that can be accessed with an Azure resource (for example, in Azure Container Instances the service is Subscriptions).
215121

216122
## Viewing the Azure Storage app dashboards
217123

218-
import ViewDashboards from '../../reuse/apps/view-dashboards.md';
124+
import ViewDashboardsIndex from '../../reuse/apps/view-dashboards-index.md';
219125

220-
<ViewDashboards/>
126+
<ViewDashboardsIndex/>
221127

222128
### Overview
223129

@@ -444,6 +350,18 @@ import AppUninstall from '../../reuse/apps/app-uninstall.md';
444350

445351
<AppUninstall/>
446352

353+
### Azure Storage alerts
354+
These alerts are metric based and will work for all Azure Storage.
355+
356+
| Alert Name | Alert Description and Conditions | Alert Condition | Recover Condition |
357+
|:------------------------------------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------|:--------------------|
358+
| `Azure Storage - Availability` | This alert is triggered when average Availability is less than 90%. Also, a warning type alert will be triggered when average Availability is less than 95%. | Percentage < = 90 | Percentage > 90 |
359+
| `Azure Storage - Success E2E Latency` | This alert is triggered when Success E2E Latency is greater than 1000 MilliSeconds. | MilliSeconds > = 1000 | MilliSeconds < 1000 |
360+
| `Azure Storage - Success Server Latency` | This alert is triggered when Success Server Latency greater than 1000. | MilliSeconds > = 1000 | MilliSeconds < 1000 |
361+
| `Azure Storage - Transactions` | This alert is triggered when Transactions count greater than 500. | Count > = 500 | Count < 500 |
362+
| `Azure Storage - Used Capacity(GB)` | This alert is triggered when Used Capacity(GB) greater than 100. | Byted(GB) > = 100 | Byted(GB) < 100 |
363+
364+
447365
## Troubleshooting
448366

449367
### HTTP Logs and Metrics Source used by Azure Functions

0 commit comments

Comments
 (0)