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: articles/network-watcher/traffic-analytics-schema-update.md
+53-27Lines changed: 53 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,33 +1,52 @@
1
1
---
2
-
title: Azure Traffic Analytics schema update - March 2020 | Microsoft Docs
3
-
description: Sample queries with new fields in the Traffic Analytics schema.
2
+
title: Azure Traffic Analytics schema update - March 2020
3
+
description: Sample queries with new fields in the Traffic Analytics schema. Use these three examples to replace the deprecated fields with the new ones.
4
4
services: network-watcher
5
5
documentationcenter: na
6
-
author: vinigam
7
-
manager: agummadi
6
+
author: Harsha-CS
7
+
manager: vinigam
8
8
editor:
9
9
10
10
ms.service: network-watcher
11
-
ms.topic: article
11
+
ms.topic: how-to
12
+
ms.custom: kr2b-contr-experiment
12
13
ms.tgt_pltfrm: na
13
14
ms.workload: infrastructure-services
14
-
ms.date: 01/07/2021
15
-
ms.author: vinigam
15
+
ms.date: 06/13/2022
16
+
ms.author: harshacs
16
17
17
18
---
18
-
# Sample queries with new fields in the Traffic Analytics schema (August 2019 schema update)
19
+
# Sample queries with new fields in the Traffic Analytics schema (March 2020 schema update)
19
20
20
-
The [Traffic Analytics log schema](./traffic-analytics-schema.md) includes the following new fields:**SrcPublicIPs_s**, **DestPublicIPs_s**, **NSGRule_s**. The new fields provide information about source and destination IPs, and they simplify queries.
21
+
The [Traffic Analytics log schema](./traffic-analytics-schema.md) includes the following new fields:
21
22
22
-
In the next few months, the following older fields will be deprecated: **VMIP_s**, **Subscription_g**, **Region_s**, **NSGRules_s**, **Subnet_s**, **VM_s**, **NIC_s**, **PublicIPs_s**, **FlowCount_d**.
23
+
-`SrcPublicIPs_s`
24
+
-`DestPublicIPs_s`
25
+
-`NSGRule_s`
26
+
27
+
The new fields provide information about source and destination IPs, and they simplify queries.
28
+
29
+
The following older fields will be deprecated in future:
30
+
31
+
-`VMIP_s`
32
+
-`Subscription_g`
33
+
-`Region_s`
34
+
-`NSGRules_s`
35
+
-`Subnet_s`
36
+
-`VM_s`
37
+
-`NIC_s`
38
+
-`PublicIPs_s`
39
+
-`FlowCount_d`
23
40
24
41
The following three examples show how to replace the old fields with the new ones.
25
42
26
43
## Example 1: VMIP_s, Subscription_g, Region_s, Subnet_s, VM_s, NIC_s, and PublicIPs_s fields
27
44
28
-
We don't have to infer source and destination cases from the **FlowDirection_s** field for AzurePublic and ExternalPublic flows. It can also be inappropriate to use the **FlowDirection_s** field for a network virtual appliance.
45
+
The schema doesn't have to infer source and destination cases from the `FlowDirection_s` field for AzurePublic and ExternalPublic flows. It can also be inappropriate to use the `FlowDirection_s` field for a network virtual appliance.
46
+
47
+
Previous Kusto query:
29
48
30
-
```Old Kusto query
49
+
```kusto
31
50
AzureNetworkAnalytics_CL
32
51
| where SubType_s == "FlowLog" and FASchemaVersion_s == "1"
33
52
| extend isAzureOrExternalPublicFlows = FlowType_s in ("AzurePublic", "ExternalPublic")
@@ -47,8 +66,9 @@ SourcePublicIPsAggregated = iif(isAzureOrExternalPublicFlows and FlowDirection_s
47
66
DestPublicIPsAggregated = iif(isAzureOrExternalPublicFlows and FlowDirection_s == 'O', PublicIPs_s, "N/A")
48
67
```
49
68
69
+
New Kusto query:
50
70
51
-
```New Kusto query
71
+
```kusto
52
72
AzureNetworkAnalytics_CL
53
73
| where SubType_s == "FlowLog" and FASchemaVersion_s == "2"
`<Index value 0)>|<NSG_ RuleName>|<Flow Direction>|<Flow Status>|<FlowCount ProcessedByRule>`
94
+
```kusto
95
+
<Index value 0)>|<NSG_ RuleName>|<Flow Direction>|<Flow Status>|<FlowCount ProcessedByRule>
96
+
```
97
+
98
+
The schema no longer aggregates data across a network security group (NSG). In the updated schema, `NSGList_s` contains only one NSG. Also, `NSGRules` contains only one rule. The complicated formatting has been removed here and in other fields, as shown in the following example.
75
99
76
-
We no longer aggregate data across a network security group (NSG). In the updated schema, **NSGList_s** contains only one NSG. Also **NSGRules** contains only one rule. We removed the complicated formatting here and in other fields as shown in the example.
100
+
Previous Kusto query:
77
101
78
-
```Old Kusto query
102
+
```kusto
79
103
AzureNetworkAnalytics_CL
80
104
| where SubType_s == "FlowLog" and FASchemaVersion_s == "1"
Only one of the four fields will be nonzero. The other three fields will be zero. The fields populate to indicate the status and count in the NIC where the flow was captured.
133
+
Only one of the four fields is nonzero. The other three fields are zero. The fields populate to indicate the status and count in the NIC where the flow was captured.
108
134
109
135
To illustrate these conditions:
110
136
111
-
- If the flow was allowed, one of the "Allowed" prefixed fields will be populated.
112
-
- If the flow was denied, one of the "Denied" prefixed fields will be populated.
113
-
- If the flow was inbound, one of the "InFlows_d" suffixed fields will be populated.
114
-
- If the flow was outbound, one of the "OutFlows_d" suffixed fields will be populated.
137
+
- If the flow was allowed, one of the `Allowed` prefixed fields is populated.
138
+
- If the flow was denied, one of the `Denied` prefixed fields is populated.
139
+
- If the flow was inbound, one of the `InFlows_d` suffixed fields is populated.
140
+
- If the flow was outbound, one of the `OutFlows_d` suffixed fields is populated.
115
141
116
-
Depending on the conditions, we know which one of the four fields will be populated.
142
+
Depending on the conditions, it's clear which of the four fields is populated.
117
143
118
144
## Next steps
119
145
120
146
- To get answers to frequently asked questions, see [Traffic Analytics FAQ](traffic-analytics-faq.yml).
121
-
- To see details about functionality, see [Traffic Analytics documentation](traffic-analytics.md).
147
+
- To see details about functionality, see [Traffic Analytics documentation](traffic-analytics.md).
0 commit comments