mirror of
https://github.com/Microsoft/sql-server-samples.git
synced 2025-12-08 14:58:54 +00:00
Merge pull request #1251 from microsoft/twright-dashboards
Adding more dashboards
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -0,0 +1,801 @@
|
||||
{
|
||||
"properties": {
|
||||
"lenses": {
|
||||
"0": {
|
||||
"order": 0,
|
||||
"parts": {
|
||||
"0": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"colSpan": 18,
|
||||
"rowSpan": 2
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<div style='line-height:50px;'>\n<span style='font-size:20px;font-weight:bold'>Azure Arc - Extended Security Updates (ESU) for Windows Server and SQL Server</span><br/>\n<span style='font-size:20px'>This dashboard tracks ESU for Windows Server & SQL Server 2012/2014</span>\n</div>\n",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"1": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 2,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 1
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<div style='line-height:50px;'>\n<span style='font-size:16px;font-weight:bold'>Windows 2012 - </span>\n<span style='font-size:16px'>End of Life - </span><span style='font-size:16px;font-weight:bold'>10th October 2023</span>\n</div>\n",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"2": {
|
||||
"position": {
|
||||
"x": 6,
|
||||
"y": 2,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 1
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<div style='line-height:50px;'>\n<span style='font-size:16px;font-weight:bold'>SQL Server 2012 - </span>\n<span style='font-size:16px'>End of Life - </span><span style='font-size:16px;font-weight:bold'>12th July 2022</span>\n</div>\n",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"3": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 2,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 1
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<div style='line-height:50px;'>\n<span style='font-size:16px;font-weight:bold'>SQL Server 2014 - </span>\n<span style='font-size:16px'>Planned End of Life - </span><span style='font-size:16px;font-weight:bold;color:Red'>9th July 2024</span>\n</div>\n",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"4": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 3,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Query - All Arc Registered Windows 2012 Servers broken down by ESU assigned/not assigned\nresources\n| where type =~ 'microsoft.hybridcompute/machines'\n| extend osSku = tostring(properties.osSku)\n//ESU Assignment (esu eligibility - OS is ESU capable, License Assignment State - OS does/does not have ESU assigned\n| extend ESU = tostring(properties.licenseProfile.esuProfile.licenseAssignmentState)\n| extend esuEligibility = tostring(properties.licenseProfile.esuProfile.esuEligibility)\n| extend esuCount = iff(ESU == \"NotAssigned\",0,1)\n//Change to \"Windows Server 2012\" for live version\n| where osSku contains \"Windows Server 2012\" \n| summarize ServerCount = count() by ESU",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Windows Server 2012 ESU License State",
|
||||
"subtitle": "All WIndows Server 2012 servers by ESU license state"
|
||||
}
|
||||
}
|
||||
},
|
||||
"5": {
|
||||
"position": {
|
||||
"x": 6,
|
||||
"y": 3,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Assigned ESU for SQL Query\n//This is a 3 part query - needs to include all VMs that have SQL Server installed as an instance (and to subselect for ESU eligible\n//SQL Server versions) and then all Machine extensions which contain the ESU assigned True/False flag\n//This query can then be used to determine ESU assignment by SQL Version, Edition, Tag (Application), Location etc\n//Main Table - All Arc Virtual Machines\nresources\n| where type == \"microsoft.hybridcompute/machines\"\n| extend mssqlDiscovered = properties.mssqlDiscovered\n//Performance - select only machines with SQL Server detected\n| where mssqlDiscovered == 'true'\n| extend coreCount = toint(properties.detectedProperties.coreCount)\n| extend machineId = tolower(tostring(id))\n| extend machineName = name\n| join kind=inner (\n //Sub Table - Select distinct SQL Server Version (and select on SQL Server 2012)\n resources\n | where type == 'microsoft.azurearcdata/sqlserverinstances'\n | extend version = tostring(properties.version)\n | extend edition = properties.edition\n | extend containerId = tolower(tostring (properties.containerResourceId))\n //add clause back in for live dashboard\n | where version contains \"2012\"\n | where edition in (\"Enterprise\", \"Standard\")\n | where isnotempty(containerId)\n | extend SQL_instance = name\n //Machine may contain multiple instances - this distinct selects the first (assuming all instances on same machine are same SQL Version)\n | distinct containerId)\non $left.machineId == $right.containerId\n| join kind=inner (\n //Sub Table - Identify if SQL ESUs assigned\n resources\n //Machine extensions resource type\n | where type == \"microsoft.hybridcompute/machines/extensions\"\n //Machine has SQL Server extension\n | where properties.type in (\"WindowsAgent.SqlServer\",\"LinuxAgent.SqlServer\")\n //extract Machine name from ID\n | extend machineIdHasSQLServerExtensionInstalled = tolower(iff(id contains \"/extensions/WindowsAgent.SqlServer\" or id contains \"/extensions/LinuxAgent.SqlServer\", substring(id, 0, indexof(id, \"/extensions/\")), \"\"))\n //enableExtendedSecurityUpdates has 3 values - Null (ESU not applicable), True (ESU applicable and enabled), False (ESU applicable and disabled)\n | extend ESU = iff(notnull(properties.settings.enableExtendedSecurityUpdates), iff(properties.settings.enableExtendedSecurityUpdates == true,\"enabled\",\"disabled\"), \"N/A\")\n | project machineIdHasSQLServerExtensionInstalled, Extension_State = properties.provisioningState, License_Type = properties.settings.LicenseType,ESU, Extension_Version = properties.instanceView.typeHandlerVersion\n)\non $left.machineId == $right.machineIdHasSQLServerExtensionInstalled\n//| distinct Machine_name, ESU\n//| summarize count(), sum(coreCount) by ESU\n| summarize count() by ESU",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2012 ESU License State",
|
||||
"subtitle": "All SQL Server 2012 servers by ESU license state"
|
||||
}
|
||||
}
|
||||
},
|
||||
"6": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 3,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Query - All Arc Registered Windows 2014 Servers (SQL Server 2014 will be End of Life shortly)\nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| extend version = tostring(properties['version'])\n//ESU Assignment (esu eligibility - OS is ESU capable, License Assignment State - OS does/does not have ESU assigned\n| extend ESU = tostring(properties.licenseProfile.esuProfile.licenseAssignmentState)\n| extend esuEligibility = tostring(properties.licenseProfile.esuProfile.esuEligibility)\n| extend esuCount = iff(ESU == \"NotAssigned\",0,1)\n// Change to SQL Server 2014 for live version\n| where ['version'] == \"SQL Server 2014\"\n// No ESUs as yet for SQL Server 2014, however pie chart used for consistency - Query will shift when ESUs are available for 2014\n| summarize Servers=count() by ESU",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2014 ESU License State",
|
||||
"subtitle": "All SQL Server 2014 servers by ESU license state"
|
||||
}
|
||||
}
|
||||
},
|
||||
"7": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 8,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Windows 2012 Servers with no ESU license by Application\n//Applicaton breakdown requires tagging of resources\nResources\n| where type == \"microsoft.hybridcompute/machines\"\n| extend application = tostring(tags.Application)\n| extend osSku = tostring(properties.osSku)\n| extend esuLicense= tostring(properties.licenseProfile.esuProfile.licenseAssignmentState)\n//Change to Windows Server 2012 for live version\n| where osSku contains \"Windows Server 2012\"\n//Select Servers with no license\n| where esuLicense == \"NotAssigned\"\n| summarize ServerCount = count() by application",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Windows Server 2012 ESU not assigned by appllication",
|
||||
"subtitle": "Windows Server 2012 servers with no ESU active by application"
|
||||
}
|
||||
}
|
||||
},
|
||||
"8": {
|
||||
"position": {
|
||||
"x": 6,
|
||||
"y": 8,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Assigned ESU for SQL Query\n//This is a 3 part query - needs to include all VMs that have SQL Server installed as an instance (and to subselect for ESU eligible\n//SQL Server versions) and then all Machine extensions which contain the ESU assigned True/False flag\n//This query can then be used to determine ESU assignment by SQL Version, Edition, Tag (Application), Location etc\n//Main Table - All Arc Virtual Machines\nresources\n| where type == \"microsoft.hybridcompute/machines\"\n| extend mssqlDiscovered = properties.mssqlDiscovered\n//Performance - select only machines with SQL Server detected\n| where mssqlDiscovered == 'true'\n| extend coreCount = toint(properties.detectedProperties.coreCount)\n| extend machineId = tolower(tostring(id))\n| extend Machine_name = name\n| join kind=inner (\n //Sub Table - Select distinct SQL Server Version (and select on SQL Server 2012)\n resources\n | where type == 'microsoft.azurearcdata/sqlserverinstances'\n | extend version = tostring(properties.version)\n | extend edition = properties.edition\n | extend application = tostring(tags.Application)\n | extend containerId = tolower(tostring (properties.containerResourceId))\n //add clause back in for live dashboard\n | where version contains \"2012\"\n | where edition in (\"Enterprise\", \"Standard\")\n | where isnotempty(containerId)\n | extend SQL_instance = name\n //Machine may contain multiple instances - this distinct selects the first (assuming all instances on same machine are same SQL Version)\n | distinct containerId, application)\non $left.machineId == $right.containerId\n| join kind=inner (\n //Sub Table - Identify if SQL ESUs assigned\n resources\n //Machine extensions resource type\n | where type == \"microsoft.hybridcompute/machines/extensions\"\n //Machine has SQL Server extension\n | where properties.type in (\"WindowsAgent.SqlServer\",\"LinuxAgent.SqlServer\")\n //extract Machine name from ID\n | extend machineIdHasSQLServerExtensionInstalled = tolower(iff(id contains \"/extensions/WindowsAgent.SqlServer\" or id contains \"/extensions/LinuxAgent.SqlServer\", substring(id, 0, indexof(id, \"/extensions/\")), \"\"))\n //enableExtendedSecurityUpdates has 3 values - Null (ESU not applicable), True (ESU applicable and enabled), False (ESU applicable and disabled)\n | extend ESU = iff(notnull(properties.settings.enableExtendedSecurityUpdates), iff(properties.settings.enableExtendedSecurityUpdates == true,\"enabled\",\"disabled\"), \"N/A\")\n | project machineIdHasSQLServerExtensionInstalled, Extension_State = properties.provisioningState, License_Type = properties.settings.LicenseType,ESU, Extension_Version = properties.instanceView.typeHandlerVersion\n)\non $left.machineId == $right.machineIdHasSQLServerExtensionInstalled\n//| distinct Machine_name, ESU\n//| summarize count(), sum(coreCount) by ESU\n| summarize count() by application",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2012 ESU not assigned by appllication",
|
||||
"subtitle": "SQL Server 2012 servers with no ESU active by application"
|
||||
}
|
||||
}
|
||||
},
|
||||
"9": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 8,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n// Change to SQL Server 2014\n| where tostring(properties['version']) == \"SQL Server 2014\"\n| extend application = tostring(tags.Application)\n//No ESU filter needed as no ESUs for 2014 yet\n| summarize Servers=count() by application",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2014 servers with no ESU active by application",
|
||||
"subtitle": "SQL Server 2014 servers with no ESU active by application"
|
||||
}
|
||||
}
|
||||
},
|
||||
"10": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 13,
|
||||
"colSpan": 12,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\r\n| where type == 'microsoft.hybridcompute/machines'\r\n//Change to Windows Server 2012\r\n| extend osSku = tostring(properties.osSku)\r\n| where osSku contains \"Windows Server 2012\"\r\n| extend esuLicense= tostring(properties.licenseProfile.esuProfile.licenseAssignmentState)\r\n| join kind=inner (\r\n resourcecontainers\r\n | where type == 'microsoft.resources/subscriptions'\r\n | project subscriptionId, subScriptionName = name)\r\n on subscriptionId\r\n| project subScriptionName , resourceGroup, esuLicense\r\n| summarize ServerCount = count() by subScriptionName, resourceGroup, esuLicense",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Windows 2012 ESU Assignment by Subscription, Resource Group",
|
||||
"subtitle": "Count of Windows Server 2012 servers assigned/not assigned"
|
||||
}
|
||||
}
|
||||
},
|
||||
"11": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 13,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Query - Chart of breakdown of Windows 2012 Servers into Datacenter and Standard\n//Filter on osTYpe = Windows \nresources\n| where type =~ 'microsoft.hybridcompute/machines'\n| where properties.osType == \"windows\"\n//**Change to Windows Server 2012\n| extend osSku = tostring(properties.osSku)\n| where osSku contains \"Windows Server 2012\"\n//Change back to original filter for go live - dummy filter below uses 2019/2022 to create 2 groups\n| extend edition = iff(properties.osSku contains \"Datacenter\", \"Datacenter\", \"Standard\")\n| summarize serverCount = count() by edition",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Windows Server 2012 Standard vs Datacenter",
|
||||
"subtitle": "Distribution of Windows Server 2012 Standard & Datacenter servers"
|
||||
}
|
||||
}
|
||||
},
|
||||
"12": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 18,
|
||||
"colSpan": 18,
|
||||
"rowSpan": 6
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Summary Query – reports a count of servers onboarded to Arc by Subscription, Resource Group, returning if ESU is activated or not\nresources\n| where type =~ 'microsoft.hybridcompute/machines'\n| extend esuEligibility = tostring(properties.licenseProfile.esuProfile.esuEligibility)\n//Select where Server is Eligible for ESUs\n| where esuEligibility == \"Eligible\"\n| extend ESUAttached = iff(properties.licenseProfile.esuProfile.licenseAssignmentState ==\"Assigned\", 1, 0)\n| join kind=inner (\n resourcecontainers\n | where type == 'microsoft.resources/subscriptions'\n | project subscriptionId, subscriptionName = name)\n on subscriptionId\n| summarize percentESUAssigned = toint(\n round((todouble(sum(ESUAttached)) / count() * 100), 2)) by subscriptionName",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Percentage Windows Server ESU Assigned by Subscription",
|
||||
"subtitle": "Percentage of WIndows Server ESUs of total ESU-eligible servers discovered"
|
||||
}
|
||||
}
|
||||
},
|
||||
"13": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 24,
|
||||
"colSpan": 12,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Assigned ESU for SQL Query\r\n//This is a 3 part query - needs to include all VMs that have SQL Server installed as an instance (and to subselect for ESU eligible\r\n//SQL Server versions) and then all Machine extensions which contain the ESU assigned True/False flag\r\n//This query can then be used to determine ESU assignment by SQL Version, Edition, Tag (Application), Location etc\r\n//Main Table - All Arc Virtual Machines\r\nresources\r\n| where type == \"microsoft.hybridcompute/machines\"\r\n| extend mssqlDiscovered = properties.mssqlDiscovered\r\n//Performance - select only machines with SQL Server detected\r\n| where mssqlDiscovered == 'true'\r\n| extend coreCount = toint(properties.detectedProperties.coreCount)\r\n| extend machineId = tolower(tostring(id))\r\n| extend machineName = name\r\n//Include below if Subscription Name needed\r\n| join kind=inner (\r\n resourcecontainers\r\n | where type == 'microsoft.resources/subscriptions'\r\n | project subscriptionId, subscriptionName = name)\r\n on subscriptionId\r\n| join kind=inner (\r\n //Sub Table - Select distinct SQL Server Version (and select on SQL Server 2012)\r\n resources\r\n | where type == 'microsoft.azurearcdata/sqlserverinstances'\r\n | extend version = tostring(properties.version)\r\n | extend edition = properties.edition\r\n | extend containerId = tolower(tostring (properties.containerResourceId))\r\n //add clause back in for live dashboard\r\n | where version contains \"2012\"\r\n | where edition in (\"Enterprise\", \"Standard\")\r\n | where isnotempty(containerId)\r\n | extend SQL_instance = name\r\n //Machine may contain multiple instances - this distinct selects the first (assuming all instances on same machine are same SQL Version)\r\n | distinct containerId)\r\non $left.machineId == $right.containerId\r\n| join kind=inner (\r\n //Sub Table - Identify if SQL ESUs assigned\r\n resources\r\n //Machine extensions resource type\r\n | where type == \"microsoft.hybridcompute/machines/extensions\"\r\n //Machine has SQL Server extension\r\n | where properties.type in (\"WindowsAgent.SqlServer\",\"LinuxAgent.SqlServer\")\r\n //extract Machine name from ID\r\n | extend machineIdHasSQLServerExtensionInstalled = tolower(iff(id contains \"/extensions/WindowsAgent.SqlServer\" or id contains \"/extensions/LinuxAgent.SqlServer\", substring(id, 0, indexof(id, \"/extensions/\")), \"\"))\r\n //enableExtendedSecurityUpdates has 3 values - Null (ESU not applicable), True (ESU applicable and enabled), False (ESU applicable and disabled)\r\n | extend ESU = iff(notnull(properties.settings.enableExtendedSecurityUpdates), iff(properties.settings.enableExtendedSecurityUpdates == true,\"enabled\",\"disabled\"), \"N/A\")\r\n | project machineIdHasSQLServerExtensionInstalled, Extension_State = properties.provisioningState, License_Type = properties.settings.LicenseType,ESU, Extension_Version = properties.instanceView.typeHandlerVersion\r\n)\r\non $left.machineId == $right.machineIdHasSQLServerExtensionInstalled\r\n//| distinct Machine_name, ESU\r\n//| summarize count(), sum(coreCount) by ESU\r\n| summarize ServerCount = count() by subscriptionName, resourceGroup, ESU",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2012 ESU Assignment by Subscription, Resource Group",
|
||||
"subtitle": "Count of SQL Server 2012 servers assigned/not assigned"
|
||||
}
|
||||
}
|
||||
},
|
||||
"14": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 24,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Query - Chart of breakdown of SQL 2012 Servers into Datacenter and Standard\n//Filter on version = SQL Server 2012 \nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| extend version = tostring(properties.version)\n| extend edition = tostring(properties.edition)\n// Change to SQL Server 2012\n| where ['version'] == \"SQL Server 2012\"\n| summarize serverCount = count() by edition",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2012 Editions",
|
||||
"subtitle": "Distribution of SQL Server 2012 Developer, Standard & Enterprise edition"
|
||||
}
|
||||
}
|
||||
},
|
||||
"15": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 29,
|
||||
"colSpan": 12,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\r\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\r\n// Change to SQL Server 2014\r\n//SQL Server Version & Edition\r\n| extend version = tostring(properties.version)\r\n| extend sqlEdition = tostring(properties.edition)\r\n| extend SQLinstance = name\r\n| where ['version'] == \"SQL Server 2014\"\r\n| join kind=inner (\r\n resourcecontainers\r\n | where type == 'microsoft.resources/subscriptions'\r\n | project subscriptionId, subScriptionName = name)\r\n on subscriptionId\r\n| project subScriptionName , resourceGroup\r\n| summarize instanceCount = count() by subScriptionName, resourceGroup",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2014 Distribution by Subscription, Resource Group",
|
||||
"subtitle": "Distribution of SQL Server 2014 across all Arc registered servers"
|
||||
}
|
||||
}
|
||||
},
|
||||
"16": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 29,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "//Query - Chart of breakdown of SQL 2012 Servers into Datacenter and Standard\n//Filter on version = SQL Server 2012 \nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| extend version = tostring(properties.version)\n| extend edition = tostring(properties.edition)\n// Change to SQL Server 2012\n| where ['version'] == \"SQL Server 2014\"\n| summarize serverCount = count() by edition",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server 2014 Editions",
|
||||
"subtitle": "Distribution of SQL Server 2014 Developer, Standard & Enterprise edition"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"metadata": {
|
||||
"model": {
|
||||
"timeRange": {
|
||||
"value": {
|
||||
"relative": {
|
||||
"duration": 24,
|
||||
"timeUnit": 1
|
||||
}
|
||||
},
|
||||
"type": "MsPortalFx.Composition.Configuration.ValueTypes.TimeRange"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"name": "Arc - ESU",
|
||||
"type": "Microsoft.Portal/dashboards",
|
||||
"location": "INSERT LOCATION",
|
||||
"tags": {
|
||||
"hidden-title": "Arc - ESU"
|
||||
},
|
||||
"apiVersion": "2015-08-01-preview"
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,872 @@
|
||||
{
|
||||
"properties": {
|
||||
"lenses": {
|
||||
"0": {
|
||||
"order": 0,
|
||||
"parts": {
|
||||
"0": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 0,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 2
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<div style='line-height:50px;'>\n<span style='font-size:20px;font-weight:bold'>Arc - SQL Server Inventory</span>\n<br/>\n<span style='font-size:20px'>This dashboard provides insights into the entire SQL Server estate enabled by Azure Arc.</span>\n</div>",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"1": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 2,
|
||||
"colSpan": 3,
|
||||
"rowSpan": 4
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "// Count of all resources\nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| summarize Servers=count()\n",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQuerySingleValueTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Instances",
|
||||
"subtitle": "Count of SQL Server Instances"
|
||||
}
|
||||
}
|
||||
},
|
||||
"2": {
|
||||
"position": {
|
||||
"x": 3,
|
||||
"y": 2,
|
||||
"colSpan": 3,
|
||||
"rowSpan": 4
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "// Count of all resources\nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances/databases\"\n| count ",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQuerySingleValueTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Databases",
|
||||
"subtitle": "Count of databases across all SQL Server instances"
|
||||
}
|
||||
}
|
||||
},
|
||||
"3": {
|
||||
"position": {
|
||||
"x": 6,
|
||||
"y": 2,
|
||||
"colSpan": 14,
|
||||
"rowSpan": 4
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "chartType",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\r\n| where type == \"microsoft.azurearcdata/sqlserverinstances/databases\"\r\n| summarize Dbs=count(),Offline=sum(toint(iif(tostring(properties[\"state\"])!=\"Online\",1,0)))\r\n,SizeMB=sum(toint(iif(tostring(properties[\"sizeMB\"])!=\"\",properties[\"sizeMB\"],0))) by Instances = tostring(split(tostring(id),\"/\")[8])\r\n| order by SizeMB desc \r\n| take 20",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryGridTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "DB Details per SQL Server Instance",
|
||||
"subtitle": "Number of DBs and size per SQL Server instance"
|
||||
}
|
||||
}
|
||||
},
|
||||
"4": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 6,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| extend version = tostring(properties['version'])\n| summarize Count=count() by ['version']\n| order by ['version'] asc ",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Versions",
|
||||
"subtitle": "Count of SQL Server instances by version"
|
||||
}
|
||||
}
|
||||
},
|
||||
"5": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 11,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 2",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "// If distinct count is small (e.g. < 1000)\n// run next query to get count of each value\nresources\n| where ['type'] == \"microsoft.azurearcdata/sqlserverinstances\"\n| summarize Count=count() by tostring(properties['edition'])\n| order by Count desc",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Instances per SQL Server Edition",
|
||||
"subtitle": "Count of SQL Server instances per edition"
|
||||
}
|
||||
}
|
||||
},
|
||||
"6": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 16,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 5
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 2",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "// If distinct count is small (e.g. < 1000)\n// run next query to get count of each value\nresources\n| where type == \"microsoft.azurearcdata/sqlserverinstances/databases\"\n|summarize Count=count() by tostring(properties['compatibilityLevel'])\n| order by Count desc",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Compatibility Level",
|
||||
"subtitle": "Count of databases by compatibilty level"
|
||||
}
|
||||
}
|
||||
},
|
||||
"7": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 21,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 6
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 2",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\n| summarize Count=count() by iff(tostring(properties['azureDefenderStatus'])==\"Unknown\", \"Not Protected\",tostring(properties['azureDefenderStatus']))\n| order by Count desc",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Defender for SQL Server",
|
||||
"subtitle": "Count of SQL Server servers by Defender protection status"
|
||||
}
|
||||
}
|
||||
},
|
||||
"8": {
|
||||
"position": {
|
||||
"x": 6,
|
||||
"y": 21,
|
||||
"colSpan": 6,
|
||||
"rowSpan": 6
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where ['type'] ==\"microsoft.azurearcdata/sqlserverinstances/databases\"\n| summarize Count=count() by Encrypte=iif(tostring(properties['databaseOptions'].isEncrypted)==\"false\",\"No\", \"Yes\")",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "Encrypted Databases",
|
||||
"subtitle": "Count of databases encrypted and not encrypted"
|
||||
}
|
||||
}
|
||||
},
|
||||
"9": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 21,
|
||||
"colSpan": 8,
|
||||
"rowSpan": 6
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": " resources\n | where type == 'microsoft.azurearcdata/sqlserverinstances'\n | extend version = tostring(properties.version)\n | extend edition = properties.edition\n | extend containerId = tolower(tostring (properties.containerResourceId))\n //add clause back in for live dashboard\n | extend serverClass = iff(edition in (\"Enterprise\", \"Standard\"), \"Ent/Std\", \"Express/Dev etc\") \n| summarize count() by serverClass",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 2,
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Edition Type",
|
||||
"subtitle": "Standard or Enterprise Edition vs other SQL Server Editions"
|
||||
}
|
||||
}
|
||||
},
|
||||
"10": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 27,
|
||||
"colSpan": 12,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\r\n| where type == \"microsoft.azurearcdata/sqlserverinstances\"\r\n| extend d=parse_json(properties) \r\n| extend Patch=d[\"patchLevel\"]\r\n| extend SQLVersion=d[\"version\"]\r\n| extend Edition=d[\"edition\"]\r\n| extend License=d[\"licenseType\"]\r\n| project name, Patch, SQLVersion, Edition, License\r\n| summarize count() by tostring(License), tostring(Edition)",
|
||||
"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": "SQL Server Edition Summary",
|
||||
"subtitle": "Count of SQL Server instances by **instsance** license type and edition"
|
||||
}
|
||||
}
|
||||
},
|
||||
"11": {
|
||||
"position": {
|
||||
"x": 12,
|
||||
"y": 27,
|
||||
"colSpan": 8,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\r\n| where type == \"microsoft.hybridcompute/machines/extensions\" \r\n| where properties.type in (\"WindowsAgent.SqlServer\",\"LinuxAgent.SqlServer\")\r\n| summarize count() by tostring(properties.settings.LicenseType)",
|
||||
"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": "Extension License Type",
|
||||
"subtitle": "Count of SQL Server servers by extension license type"
|
||||
}
|
||||
}
|
||||
},
|
||||
"12": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 34,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 1
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [],
|
||||
"type": "Extension/HubsExtension/PartType/MarkdownPart",
|
||||
"settings": {
|
||||
"content": {
|
||||
"content": "<span style='font-size:20px;font-weight:bold'>SQL Server Instances by Tag Values - </span>\n<span style='font-size:20px'>Shows SQL Server instance distribution by various tag values.</span>\n</div>\n",
|
||||
"title": "",
|
||||
"subtitle": "",
|
||||
"markdownSource": 1,
|
||||
"markdownUri": ""
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"13": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 35,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where ['type'] == \"microsoft.azurearcdata/sqlserverinstances\"\n//Tag values - edit here for custom tags\n| extend application = tostring(tags.Application)\n| summarize ServerCount = count() by application",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Instances by Application",
|
||||
"subtitle": "SQL Servers instances by \"Application\" tag values"
|
||||
}
|
||||
}
|
||||
},
|
||||
"14": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 42,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where ['type'] == \"microsoft.azurearcdata/sqlserverinstances\"\n//Tag values - edit here for custom tags\n| extend location = tostring(tags.Location)\n| summarize ServerCount = count() by location",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {
|
||||
"content": {}
|
||||
},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Instances by Location",
|
||||
"subtitle": "SQL Servers instasnces by \"Location\" tag values"
|
||||
}
|
||||
}
|
||||
},
|
||||
"15": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 49,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where ['type'] == \"microsoft.azurearcdata/sqlserverinstances\"\n//Tag values - edit here for custom tags\n| extend dataCenter = tostring(tags.DataCenter)\n| summarize ServerCount = count() by dataCenter",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {
|
||||
"content": {}
|
||||
},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Instasnces by Data Center",
|
||||
"subtitle": "SQL Servers insetasnces by \"Datacenter\" tag values."
|
||||
}
|
||||
}
|
||||
},
|
||||
"16": {
|
||||
"position": {
|
||||
"x": 0,
|
||||
"y": 56,
|
||||
"colSpan": 20,
|
||||
"rowSpan": 7
|
||||
},
|
||||
"metadata": {
|
||||
"inputs": [
|
||||
{
|
||||
"name": "partTitle",
|
||||
"value": "Query 1",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "chartType",
|
||||
"value": 1,
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "isShared",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryId",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "formatResults",
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "queryScope",
|
||||
"value": {
|
||||
"scope": 0,
|
||||
"values": []
|
||||
},
|
||||
"isOptional": true
|
||||
},
|
||||
{
|
||||
"name": "query",
|
||||
"value": "resources\n| where ['type'] == \"microsoft.azurearcdata/sqlserverinstances\"\n//Tag values - edit here for custom tags\n| extend businessUnit = tostring(tags.BusinessUnit)\n| summarize ServerCount = count() by businessUnit",
|
||||
"isOptional": true
|
||||
}
|
||||
],
|
||||
"type": "Extension/HubsExtension/PartType/ArgQueryChartTile",
|
||||
"settings": {
|
||||
"content": {}
|
||||
},
|
||||
"partHeader": {
|
||||
"title": "SQL Server Instances by Business Unit",
|
||||
"subtitle": "SQL Server instances by \"BusinessUnit\" tag values"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"metadata": {
|
||||
"model": {
|
||||
"timeRange": {
|
||||
"value": {
|
||||
"relative": {
|
||||
"duration": 24,
|
||||
"timeUnit": 1
|
||||
}
|
||||
},
|
||||
"type": "MsPortalFx.Composition.Configuration.ValueTypes.TimeRange"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"name": "Arc - SQL Server Inventory",
|
||||
"type": "Microsoft.Portal/dashboards",
|
||||
"location": "INSERT LOCATION",
|
||||
"tags": {
|
||||
"hidden-title": "Arc - SQL Server Inventory"
|
||||
},
|
||||
"apiVersion": "2015-08-01-preview"
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||

|
||||
|
||||
# How to Enable Azure Dashboard for ARC SQL
|
||||
This article will show you how to use the [SQL Server Instances.json](SQL%20Server%20Instances.json) file to create a custom dashboard in the [Azure portal](https://learn.microsoft.com/en-us/azure/azure-portal/azure-portal-dashboards).
|
||||
This article will show you how to use the dashboard .json files in this directory to create custom dashboards in the [Azure portal](https://learn.microsoft.com/en-us/azure/azure-portal/azure-portal-dashboards).
|
||||
|
||||

|
||||
|
||||
@@ -14,7 +14,17 @@ This article will show you how to use the [SQL Server Instances.json](SQL%20Serv
|
||||

|
||||
4. If you want to edit the dashboard, please refer to this [link](https://learn.microsoft.com/en-us/azure/azure-portal/azure-portal-dashboards#edit-a-dashboard).
|
||||
|
||||
<a name=disclaimers></a>
|
||||
# Dashboard Directory
|
||||
- **Arc - Deployment Progress:** A dashbaord showing the progress of deploying Azure Arc to enable your SQL Server, Windows Server, and Linux servers.
|
||||
- **Arc - ESU:** A dashboard showing the current licensing configuration for Extended Security Updates (ESU) for SQL Server and Windows Server.
|
||||
- **Arc - Estate Profile:** A dashboard showing summary and detailed view of SQL Server, Windows Server, and Linux servers enabled by Azure Arc.
|
||||
- **Arc - SQL Server Inventory:** A dashboard showing detailed stats about SQL Server instances and servers hosting SQL Server.
|
||||
- **SQL Server Instances:** A dashboard focused on SQL Server inventory details about SQL Server instances and databases.
|
||||
|
||||
# Acknowledgements
|
||||
Many thanks to the following contributors that provided content to this part of the SQL Server samples repository.
|
||||
- [Tps99](https://github.com/tps99)
|
||||
|
||||
<a name=disclaimers></a>
|
||||
## Disclaimers
|
||||
The code included in this sample is not intended to be a set of best practices on how to build scalable enterprise grade applications. This is beyond the scope of this quick start sample.
|
||||
The code included in these samples are not intended to be a set of best practices on how to build scalable enterprise grade applications. This is beyond the scope of this quick start sample.
|
||||
|
||||
Reference in New Issue
Block a user