-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathAzure-Arc-Windows-Linux-Dashboard.json
337 lines (337 loc) · 13.9 KB
/
Azure-Arc-Windows-Linux-Dashboard.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
{
"properties": {
"lenses": [
{
"order": 0,
"parts": [
{
"position": {
"x": 0,
"y": 0,
"colSpan": 11,
"rowSpan": 5
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "Azure-Arc-Overview",
"isOptional": true
},
{
"name": "chartType",
"isOptional": true
},
{
"name": "formatResults",
"value": true,
"isOptional": true
},
{
"name": "queryScope",
"value": {
"scope": 0,
"values": []
},
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"isOptional": true
},
{
"name": "query",
"value": " resources\r\n| where type == \"microsoft.hybridcompute/machines\"\r\n| extend agentversion = properties.agentVersion\r\n| extend state = properties.status\r\n| extend status = case(\r\n state =~ 'Connected', 'Connected',\r\n state =~ 'Disconnected', 'Offline',\r\n state =~ 'Error', 'Error',\r\n state =~ 'Expired', 'Expired',\r\n '')\r\n| project name, agentversion, status, location, resourceGroup, subscriptionId\r\n| order by name",
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
"settings": {},
"partHeader": {
"title": "Azure Arc Overview",
"subtitle": "Overview of the Arc agents installed and current status."
}
}
},
{
"position": {
"x": 11,
"y": 0,
"colSpan": 8,
"rowSpan": 5
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "Windows ESU Assignment Status",
"isOptional": true
},
{
"name": "query",
"value": "resources\r\n| where type=~ 'microsoft.hybridcompute/machines'\r\n| extend esuEligibility = properties.licenseProfile.esuProfile.esuEligibility\r\n| where esuEligibility== 'Eligible'\r\n| extend licenseAssignmentState = properties.licenseProfile.esuProfile.licenseAssignmentState\r\n| extend serverType = properties.licenseProfile.esuProfile.serverType\r\n| extend osSku = properties.osSku\r\n| extend CoreCount = toint (properties.detectedProperties.logicalCoreCount)\r\n| project name, CoreCount, osSku, serverType, licenseAssignmentState",
"isOptional": true
},
{
"name": "chartType",
"isOptional": true
},
{
"name": "formatResults",
"isOptional": true
},
{
"name": "queryScope",
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
"settings": {},
"partHeader": {
"title": "Windows ESU Assignment Status",
"subtitle": "Overview of current Windows server and their ESU assignment status."
}
}
},
{
"position": {
"x": 0,
"y": 5,
"colSpan": 8,
"rowSpan": 6
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "Count Operating Systems Arc",
"isOptional": true
},
{
"name": "query",
"value": " resources\r\n| where type == \"microsoft.hybridcompute/machines\"\r\n| extend osSku = properties.osSku\r\n| project name, osSku\r\n| summarize count() by tostring(osSku)",
"isOptional": true
},
{
"name": "chartType",
"value": 2,
"isOptional": true
},
{
"name": "formatResults",
"isOptional": true
},
{
"name": "queryScope",
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
"settings": {},
"partHeader": {
"title": "Operating System Count",
"subtitle": "A count of the operating systems with an Arc agent installed."
}
}
},
{
"position": {
"x": 8,
"y": 5,
"colSpan": 6,
"rowSpan": 6
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "SQL Server Version Count",
"isOptional": true
},
{
"name": "query",
"value": "// Run query to see results.\r\nresources\r\n| where type == 'microsoft.azurearcdata/sqlserverinstances'\r\n| extend status = properties.status\r\n| extend sqlversion = properties.version\r\n| project name, sqlversion\r\n| summarize count() by tostring(sqlversion)",
"isOptional": true
},
{
"name": "chartType",
"value": 2,
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"value": "",
"isOptional": true
},
{
"name": "formatResults",
"isOptional": true
},
{
"name": "queryScope",
"value": {
"scope": 0,
"values": []
},
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
"settings": {},
"partHeader": {
"title": "SQL Server Version Count",
"subtitle": "A count of the SQL version versions detected on servers with an Arc agent installed."
}
}
},
{
"position": {
"x": 14,
"y": 5,
"colSpan": 8,
"rowSpan": 6
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "Arc-Agent-Version",
"isOptional": true
},
{
"name": "query",
"value": " resources\r\n| where type == \"microsoft.hybridcompute/machines\"\r\n| summarize count() by tostring(properties.agentVersion)",
"isOptional": true
},
{
"name": "chartType",
"value": 1,
"isOptional": true
},
{
"name": "formatResults",
"isOptional": true
},
{
"name": "queryScope",
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
"settings": {},
"partHeader": {
"title": "Azure Arc Agent Version Count",
"subtitle": "A view and count of the Arc agent versions currently installed."
}
}
},
{
"position": {
"x": 0,
"y": 11,
"colSpan": 22,
"rowSpan": 6
},
"metadata": {
"inputs": [
{
"name": "partTitle",
"value": "Query 1",
"isOptional": true
},
{
"name": "query",
"value": "// Run query to see results.\r\nresources\r\n| where type =~ 'microsoft.hybridcompute/machines' and kind !contains \"AVS\"\r\n| extend machineId = tolower(tostring(id))\r\n| extend hostId = tolower(id)\r\n| join kind=leftouter (\r\n connectedVMwarevSphereResources\r\n | where type =~ 'microsoft.connectedvmwarevsphere/virtualmachineinstances'\r\n | extend guestId = tolower(id)\r\n | extend indexOfHostId = indexof(guestId, tolower(\"/providers/Microsoft.ConnectedVMwarevSphere/VirtualMachineInstances/default\"))\r\n | extend hostId = substring(guestId, 0, indexOfHostId)\r\n | extend guestProperties = properties\r\n | extend guestExtendedLocation = extendedLocation\r\n | extend vCenterId = properties.infrastructureProfile.vCenterId\r\n | project hostId, guestId, guestProperties, guestExtendedLocation, vCenterId\r\n) on $left.hostId == $right.hostId\r\n| extend datacenter = iif(isnull(tags.Datacenter), '', tags.Datacenter)\r\n| extend state = properties.status\r\n| extend status = case(\r\n state =~ 'Connected', 'Connected',\r\n state =~ 'Disconnected', 'Offline',\r\n state =~ 'Error', 'Error',\r\n state =~ 'Expired', 'Expired',\r\n '')\r\n| extend osSku = properties.osSku\r\n| extend os = properties.osName\r\n| extend osName = case(\r\n os =~ 'windows', 'Windows',\r\n os =~ 'linux', 'Linux',\r\n '')\r\n| extend extensionsEnabled = tostring(properties.agentConfiguration.extensionsEnabled)\r\n| extend operatingSystem = iif(isnotnull(osSku), osSku, osName)\r\n| join kind=leftouter (\r\n resources\r\n | where type =~ \"microsoft.hybridcompute/machines/extensions\"\r\n | extend machineId = tolower(tostring(trim_end(@\"\\/\\w+\\/(\\w|\\.)+\", id)))\r\n | extend provisioned = tolower(tostring(properties.provisioningState)) == \"succeeded\"\r\n | summarize\r\n MDEcnt = countif(properties.type in (\"MDE.Linux\", \"MDE.Windows\") and provisioned),\r\n AMAcnt = countif(properties.type in (\"AzureMonitorWindowsAgent\", \"AzureMonitorLinuxAgent\") and provisioned),\r\n WACcnt = countif(properties.type in (\"AdminCenter\") and provisioned),\r\n UMcnt = countif(properties.type in (\"WindowsOsUpdateExtension\",\"LinuxOsUpdateExtension\", \"WindowsPatchExtension\") and provisioned) by machineId\r\n) on machineId\r\n| extend defenderStatus = iff ((MDEcnt>0), 'Enabled', 'Not enabled')\r\n| extend monitoringAgent = iff ((AMAcnt>0), 'Installed','Not installed')\r\n| extend wacStatus = iff ((WACcnt>0), 'Enabled', 'Not enabled')\r\n| extend updateManagement = iff ((UMcnt>0), 'Enabled', 'Not enabled')\r\n| extend hostName = tostring(properties.displayName)\r\n| extend hostEnvironment = vCenterId\r\n| extend name = iif(properties.cloudMetadata.provider == 'AWS' and name != hostName, strcat(name, \"(\", hostName, \")\"), name)\r\n| project name, status, resourceGroup, operatingSystem, extensionsEnabled, defenderStatus, monitoringAgent, wacStatus, updateManagement\r\n",
"isOptional": true
},
{
"name": "chartType",
"isOptional": true
},
{
"name": "isShared",
"isOptional": true
},
{
"name": "queryId",
"value": "",
"isOptional": true
},
{
"name": "formatResults",
"isOptional": true
},
{
"name": "queryScope",
"value": {
"scope": 0,
"values": []
},
"isOptional": true
}
],
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
"settings": {},
"partHeader": {
"title": "Azure Arc Extension Status",
"subtitle": "Overview if extensions are allowed to be deployed to Azure Arc agents and if they are enabled/installed."
}
}
}
]
}
],
"metadata": {
"model": {
"timeRange": {
"value": {
"relative": {
"duration": 24,
"timeUnit": 1
}
},
"type": "MsPortalFx.Composition.Configuration.ValueTypes.TimeRange"
}
}
}
},
"name": "Azure Arc - Windows/Linux",
"type": "Microsoft.Portal/dashboards",
"location": "INSERT LOCATION",
"tags": {
"hidden-title": "Azure Arc - Windows/Linux"
},
"apiVersion": "2022-12-01-preview"
}