Grafana dashboard: SQL Server Monitoring with prometheus
Description: Monitoring SQL Servers using Telegraf and Prometheus


{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "6.5.2"
    },
    {
      "type": "panel",
      "id": "grafana-piechart-panel",
      "name": "Pie Chart",
      "version": "1.3.9"
    },
    {
      "type": "panel",
      "id": "graph",
      "name": "Graph",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "prometheus",
      "name": "Prometheus",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "singlestat",
      "name": "Singlestat",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "type": "dashboard"
      }
    ]
  },
  "description": "Monitoring SQL Servers using Telegraf and Prometheus",
  "editable": true,
  "gnetId": 11517,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1578386141459,
  "links": [],
  "panels": [
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "id": 99,
      "panels": [],
      "repeat": null,
      "title": "Databases properties",
      "type": "row"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": true,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgb(255, 0, 0)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 0,
        "y": 1
      },
      "id": 69,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_offline{sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 2,
          "measurement": "State OFFLINE",
          "policy": "default",
          "query": "SELECT mean(\"total\") FROM \"State OFFLINE\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "0,0,1",
      "title": "DATABASES HEALTH",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "HEALTHY",
          "value": "0"
        },
        {
          "op": "=",
          "text": "NOT HEALTHY",
          "value": "1"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "${DS_PROMETHEUS}",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 4,
        "y": 1
      },
      "id": 63,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_online{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State ONLINE",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State ONLINE\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "ONLINE",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 6,
        "y": 1
      },
      "id": 64,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_offline{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State OFFLINE",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State OFFLINE\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "OFFLINE",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 8,
        "y": 1
      },
      "id": 65,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_suspect{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State SUSPECT",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State SUSPECT\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "SUSPECT",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 10,
        "y": 1
      },
      "id": 66,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_recovering{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State RECOVERING",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State RECOVERING\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "RECOVERING",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 12,
        "y": 1
      },
      "id": 67,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_recoveryPending{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State RECOVERY_PENDING",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State RECOVERY_PENDING\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "PENDING",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 14,
        "y": 1
      },
      "id": 68,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_db_restoring{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "State RESTORING",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"State RESTORING\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "RESTORING",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(50, 172, 45, 0.97)",
        "rgb(255, 85, 0)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 0,
        "y": 4
      },
      "hideTimeOverride": false,
      "id": 74,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Data File(s) Size (KB)\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "Performance metrics",
          "policy": "default",
          "query": "SELECT \"Point In Time Recovery\" FROM \"Performance metrics\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance metrics' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "Point In Time Recovery"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance metrics"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Total Data File Size",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "NOK",
          "value": "1"
        },
        {
          "op": "=",
          "text": "OK",
          "value": "0"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 4,
        "y": 4
      },
      "id": 85,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Log File(s) Size (KB)\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "Recovery Model BULK_LOGGED",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"Recovery Model BULK_LOGGED\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Total Log Files Size",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "#299c46",
        "rgba(237, 129, 40, 0.89)",
        "#d44a3a"
      ],
      "datasource": "${DS_PROMETHEUS}",
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 3,
        "x": 8,
        "y": 4
      },
      "id": 121,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "connected",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false,
        "ymax": null,
        "ymin": null
      },
      "tableColumn": "",
      "targets": [
        {
          "expr": "sqlserver_memory_clerks_size_kb{clerk_type=\"Buffer Pool\",sql_instance=~\"^$instance\"}",
          "refId": "A"
        }
      ],
      "thresholds": "",
      "timeFrom": null,
      "timeShift": null,
      "title": "Memory Clerk Buffer Pool",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "avg"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 11,
        "y": 4
      },
      "id": 84,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Log File(s) Used Size (KB)\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "Recovery Model FULL",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"Recovery Model FULL\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Total Log Files Used Size",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(50, 172, 45, 0.97)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 15,
        "y": 4
      },
      "id": 86,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": false
      },
      "tableColumn": "",
      "targets": [
        {
          "alias": "",
          "dsType": "influxdb",
          "expr": "sqlserver_server_properties_cpu_count{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 2,
          "measurement": "Recovery Model SIMPLE",
          "policy": "default",
          "query": "SELECT \"total\" FROM \"Recovery Model SIMPLE\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database properties' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "total"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database properties"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "CPU Count",
      "type": "singlestat",
      "valueFontSize": "80%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 7
      },
      "id": 103,
      "panels": [],
      "repeat": null,
      "title": "Quick Stats",
      "type": "row"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 0,
        "y": 8
      },
      "height": "",
      "id": 28,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Total Server Memory (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Target Server Memory (KB) | Memory Manager",
          "metric": "Target_Server_Memory__KB____Memory_Manager",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Target Server Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Total Memory",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "format": "kbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 4,
        "y": 8
      },
      "height": "",
      "id": 38,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Used memory (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Total Server Memory (KB) | Memory Manager",
          "metric": "Total_Server_Memory__KB____Memory_Manager",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Total Server Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Used Memory",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 3,
        "x": 8,
        "y": 8
      },
      "height": "",
      "id": 4,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"User Connections\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "User Connections | General Statistics",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"User Connections | General Statistics\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "User Connections",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": true,
      "colors": [
        "rgba(245, 54, 54, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "#73BF69"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "percent",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 3,
        "x": 11,
        "y": 8
      },
      "height": "",
      "id": 45,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Buffer cache hit ratio\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Performance metrics",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"Buffer pool rate (bytes/sec)\") FROM \"Performance metrics\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance metrics' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "Buffer pool rate (bytes/sec)"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance metrics"
            }
          ]
        }
      ],
      "thresholds": "100,0",
      "title": "Buffer cache hit ratio",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 14,
        "y": 8
      },
      "height": "",
      "id": 30,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Memory Grants Pending\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 2,
          "measurement": "Memory Grants Pending | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Memory Grants Pending | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "1,5",
      "title": "Memory Grant Pending",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "Bps",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 18,
        "y": 8
      },
      "height": "",
      "id": 32,
      "interval": "10s",
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Checkpoint pages/sec\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Performance metrics",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"Connection memory per connection (bytes)\") FROM \"Performance metrics\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance metrics' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "Connection memory per connection (bytes)"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance metrics"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Checkpoint pages/sec",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "Bps",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 0,
        "y": 11
      },
      "height": "",
      "id": 33,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Free list stalls/sec\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "measurement": "Free list stalls/sec | Buffer Manager",
          "metric": "Free_list_stalls_sec___Buffer_Manager",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Free list stalls/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "2,10",
      "title": "Free List Stalls/sec",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 4,
        "y": 11
      },
      "height": "",
      "id": 46,
      "interval": "10s",
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Page lookups/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Performance metrics",
          "metric": "Performance_metrics_Total_target_memory_ratio",
          "policy": "default",
          "query": "SELECT mean(\"Total target memory ratio\") FROM \"Performance metrics\" WHERE \"type\" = 'Performance metrics' AND \"servername\" =~ /$Instance$/ AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "Total target memory ratio"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "type",
              "operator": "=",
              "value": "Performance metrics"
            },
            {
              "condition": "AND",
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Page lookups/sec",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 4,
        "x": 8,
        "y": 11
      },
      "height": "",
      "id": 78,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Free Space in tempdb (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "measurement": "Data File(s) Size (KB) | mssqlsystemresource | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Data File(s) Size (KB) | mssqlsystemresource | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "10,15",
      "title": "Free Space in tempdb",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "deckbytes",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 12,
        "y": 11
      },
      "height": "",
      "id": 80,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Version Store Size (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Percent Log Used | mssqlsystemresource | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Percent Log Used | mssqlsystemresource | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Version Store Size",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(245, 54, 54, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(32, 33, 58, 0.9)"
      ],
      "datasource": "$datasource",
      "decimals": 1,
      "editable": true,
      "error": false,
      "format": "s",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 2,
        "x": 14,
        "y": 11
      },
      "height": "",
      "id": 8,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Page life expectancy\",object=\"SQLServer:Buffer Manager\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Page life expectancy | Buffer Manager",
          "metric": "Page_life_expectancy___Buffer_Manager",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Page life expectancy | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "300,600",
      "title": "PLE",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "PRESSURE",
          "value": "0"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "Bps",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 3,
        "x": 16,
        "y": 11
      },
      "height": "",
      "id": 12,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Backup/Restore Throughput/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "measurement": "Backup/Restore Throughput/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Backup/Restore Throughput/sec | _Total | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 30,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Backup/Restore Throughput",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "cacheTimeout": null,
      "colorBackground": false,
      "colorValue": false,
      "colors": [
        "rgba(32, 33, 58, 0.9)",
        "rgba(237, 129, 40, 0.89)",
        "rgba(245, 54, 54, 0.9)"
      ],
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "format": "none",
      "gauge": {
        "maxValue": 100,
        "minValue": 0,
        "show": false,
        "thresholdLabels": false,
        "thresholdMarkers": true
      },
      "gridPos": {
        "h": 3,
        "w": 3,
        "x": 19,
        "y": 11
      },
      "height": "",
      "id": 29,
      "interval": null,
      "links": [],
      "mappingType": 1,
      "mappingTypes": [
        {
          "name": "value to text",
          "value": 1
        },
        {
          "name": "range to text",
          "value": 2
        }
      ],
      "maxDataPoints": 100,
      "nullPointMode": "null",
      "nullText": null,
      "options": {},
      "postfix": "",
      "postfixFontSize": "50%",
      "prefix": "",
      "prefixFontSize": "50%",
      "rangeMaps": [
        {
          "from": "null",
          "text": "N/A",
          "to": "null"
        }
      ],
      "sparkline": {
        "fillColor": "rgba(31, 118, 189, 0.18)",
        "full": false,
        "lineColor": "rgb(31, 120, 193)",
        "show": true
      },
      "tableColumn": "",
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Active Temp Tables\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 2,
          "measurement": "Performance metrics",
          "metric": "Performance_metrics_Page_File_Usage____",
          "policy": "default",
          "query": "SELECT mean(\"Page File Usage (%)\") FROM \"Performance metrics\" WHERE \"servername\" =~ /$Instance$/ AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "Page File Usage (%)"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 60,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            }
          ]
        }
      ],
      "thresholds": "",
      "title": "Active Temp Tables",
      "type": "singlestat",
      "valueFontSize": "50%",
      "valueMaps": [
        {
          "op": "=",
          "text": "N/A",
          "value": "null"
        }
      ],
      "valueName": "current"
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 14
      },
      "id": 107,
      "panels": [],
      "repeat": null,
      "title": "Database size trend",
      "type": "row"
    },
    {
      "aliasColors": {},
      "breakPoint": "50%",
      "cacheTimeout": null,
      "combine": {
        "label": "Others",
        "threshold": 0
      },
      "datasource": "$datasource",
      "fontSize": "80%",
      "format": "deckbytes",
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 15
      },
      "id": 25,
      "interval": null,
      "legend": {
        "show": true,
        "values": true
      },
      "legendType": "Right side",
      "links": [],
      "maxDataPoints": 3,
      "nullPointMode": "connected",
      "options": {},
      "pieType": "pie",
      "strokeWidth": 1,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Data File(s) Size (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "instant": false,
          "intervalFactor": 1,
          "legendFormat": "{{exported_instance}}",
          "measurement": "Rows size (bytes)",
          "metric": "",
          "policy": "default",
          "query": "SELECT * FROM \"Rows size (bytes)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database size' AND $timeFilter",
          "rawQuery": false,
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database size"
            }
          ]
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Database | Rows Size",
      "type": "grafana-piechart-panel",
      "valueName": "current"
    },
    {
      "aliasColors": {},
      "breakPoint": "50%",
      "cacheTimeout": null,
      "combine": {
        "label": "Others",
        "threshold": 0
      },
      "datasource": "$datasource",
      "fontSize": "80%",
      "format": "deckbytes",
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 15
      },
      "id": 26,
      "interval": null,
      "legend": {
        "show": true,
        "values": true
      },
      "legendType": "Right side",
      "links": [],
      "maxDataPoints": 3,
      "nullPointMode": "connected",
      "options": {},
      "pieType": "pie",
      "strokeWidth": 1,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Log File(s) Size (KB)\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{exported_instance}}",
          "measurement": "Log size (bytes)",
          "metric": "",
          "policy": "default",
          "query": "SELECT * FROM \"Log size (bytes)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database size' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database size"
            }
          ]
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Database | Log Size",
      "type": "grafana-piechart-panel",
      "valueName": "current"
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 22
      },
      "id": 104,
      "panels": [],
      "repeat": null,
      "title": "Performance counters",
      "type": "row"
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 0,
        "y": 23
      },
      "height": "",
      "hiddenSeries": false,
      "id": 1,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Batch Requests/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Batch Requests/sec",
          "metric": "",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        },
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Logins/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Logins/sec",
          "metric": "",
          "policy": "default",
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        },
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Logouts/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Logouts/sec",
          "policy": "default",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        },
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"SQL Compilations/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "SQL Compilations/sec",
          "metric": "",
          "policy": "default",
          "refId": "E",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        },
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"SQL Re-Compilations/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "SQL Re-Compilations/sec",
          "policy": "default",
          "refId": "F",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        },
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Processes blocked\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Processes blocked",
          "metric": "",
          "policy": "default",
          "refId": "G",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": []
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "SQL Server Stats",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "${DS_PROMETHEUS}",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 12,
        "y": 23
      },
      "hiddenSeries": false,
      "id": 3,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "Transactions/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Transactions/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Transactions/sec",
          "measurement": "Transactions/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Transactions/sec | _Total | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Write Transactions/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Write Transactions/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Write Transactions/sec",
          "measurement": "Write Transactions/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Write Transactions/sec | _Total | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Flushes/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Log Flushes/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Log Flushes/sec",
          "measurement": "Log Flushes/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Log Flushes/sec | _Total | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Flush Wait Time",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Log Flush Wait Time\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Log Flush Wait Time",
          "measurement": "Log Flush Wait Time | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Log Flush Wait Time | _Total | Databases\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Lock Timeouts/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Lock Timeouts/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Lock Timeouts/sec",
          "measurement": "Lock Timeouts/sec | _Total | Locks",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Lock Timeouts/sec | _Total | Locks\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "E",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Number of Deadlocks/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Number of Deadlocks/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Number of Deadlocks/sec",
          "measurement": "Number of Deadlocks/sec | _Total | Locks",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Number of Deadlocks/sec | _Total | Locks\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "F",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Lock Waits/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Lock Waits/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Lock Waits/sec",
          "measurement": "Lock Waits/sec | _Total | Locks",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Lock Waits/sec | _Total | Locks\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "G",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Latch Waits/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Latch Waits/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Latch Waits/sec",
          "measurement": "Latch Waits/sec | Latches",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Latch Waits/sec | Latches\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "H",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Databases Activity",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "${DS_PROMETHEUS}",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 0,
        "y": 31
      },
      "hiddenSeries": false,
      "id": 2,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "Full Scans/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Full Scans/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Full Scans/sec",
          "measurement": "Full Scans/sec | Access Methods",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Full Scans/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Index Searches/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Index Searches/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Index Searches/sec",
          "measurement": "Index Searches/sec | Access Methods",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Index Searches/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Page Splits/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Page Splits/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Page Splits/sec",
          "measurement": "Page Splits/sec | Access Methods",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Page Splits/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Page lookups/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Page lookups/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Page lookups/sec",
          "measurement": "Page lookups/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Page lookups/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Page reads/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Page reads/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Page reads/sec",
          "measurement": "Page reads/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Page reads/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "E",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Page writes/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Page writes/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Page writes/sec",
          "measurement": "Page writes/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Page writes/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "F",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Readahead pages/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Readahead pages/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Readahead pages/sec",
          "measurement": "Readahead pages/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Readahead pages/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "G",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Lazy writes/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Lazy writes/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Lazy writes/sec",
          "measurement": "Lazy writes/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Lazy writes/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "H",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Checkpoint pages/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Checkpoint pages/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Checkpoint pages/sec",
          "measurement": "Checkpoint pages/sec | Buffer Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Checkpoint pages/sec | Buffer Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "I",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Buffer Cache - Disk",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 12,
        "y": 31
      },
      "hiddenSeries": false,
      "id": 75,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": true,
      "steppedLine": false,
      "targets": [
        {
          "alias": "SQL Cache",
          "dsType": "influxdb",
          "expr": "sqlserver_memory_clerks_size_kb{clerk_type=\"Transactions Cache (Object Store)\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "SQL Cache",
          "measurement": "SQL Cache Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"SQL Cache Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Optimizer",
          "dsType": "influxdb",
          "expr": "sqlserver_memory_clerks_size_kb{clerk_type=\"SQL Optimizer\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "Optimizer",
          "measurement": "Optimizer Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Optimizer Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Pool",
          "dsType": "influxdb",
          "expr": "sqlserver_memory_clerks_size_kb{clerk_type=\"Log Pool\",sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "Log Pool",
          "measurement": "Log Pool Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Log Pool Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Lock",
          "dsType": "influxdb",
          "expr": "Lock_Memory__KB____Memory_Manager{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "Lock",
          "measurement": "Lock Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Lock Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Database Cache",
          "dsType": "influxdb",
          "expr": "Database_Cache_Memory__KB____Memory_Manager{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "Database Cache",
          "measurement": "Database Cache Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Database Cache Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "E",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Connection",
          "dsType": "influxdb",
          "expr": "Connection_Memory__KB____Memory_Manager{sql_instance=~\"^$instance\"}",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "Connection",
          "measurement": "Connection Memory (KB) | Memory Manager",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"value\" FROM \"Connection Memory (KB) | Memory Manager\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter",
          "refId": "F",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Memory Manager",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "deckbytes",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 24,
        "x": 0,
        "y": 39
      },
      "hiddenSeries": false,
      "id": 89,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "Log Flushes/sec",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Log Flushes/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "Log Flushes/sec",
          "measurement": "Log Flushes/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Full Scans/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 2,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Pool Cache Misses/sec",
          "dsType": "influxdb",
          "expr": "Log_Pool_Cache_Misses_sec____Total___Databases{sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "hide": true,
          "intervalFactor": 1,
          "legendFormat": "Log Pool Cache Misses/sec",
          "measurement": "Log Pool Cache Misses/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Full Scans/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "B",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 2,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Pool Disk Reads/sec",
          "dsType": "influxdb",
          "expr": "Log_Pool_Disk_Reads_sec____Total___Databases{sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "hide": true,
          "intervalFactor": 1,
          "legendFormat": "Log Pool Disk Reads/sec",
          "measurement": "Log Pool Disk Reads/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Full Scans/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "C",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 2,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        },
        {
          "alias": "Log Pool Requests/sec",
          "dsType": "influxdb",
          "expr": "Log_Pool_Requests_sec____Total___Databases{sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "hide": true,
          "intervalFactor": 1,
          "legendFormat": "Log Pool Requests/sec",
          "measurement": "Log Pool Requests/sec | _Total | Databases",
          "metric": "",
          "policy": "default",
          "query": "SELECT mean(\"value\") FROM \"Full Scans/sec | Access Methods\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Performance counters' AND $timeFilter GROUP BY time($interval) fill(null)",
          "refId": "D",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 2,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Log activities",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 47
      },
      "id": 106,
      "panels": [],
      "repeat": null,
      "title": "Memory break down",
      "type": "row"
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 5,
        "w": 12,
        "x": 0,
        "y": 48
      },
      "hiddenSeries": false,
      "id": 20,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "hideEmpty": true,
        "hideZero": true,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "avg",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": true,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "rate(sqlserver_performance_value{counter=\"Used memory (KB)\",database_name=\"master\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{exported_instance}}",
          "measurement": "Memory breakdown (%)",
          "metric": "",
          "policy": "default",
          "query": "SELECT * FROM \"Memory breakdown (%)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Memory clerk' AND $timeFilter",
          "refId": "E",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Memory clerk"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Used memory by Instance",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "percent",
          "logBase": 1,
          "max": 102,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 5,
        "w": 12,
        "x": 12,
        "y": 48
      },
      "hiddenSeries": false,
      "id": 22,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "avg",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "irate(sqlserver_memory_clerks_size_kb{clerk_type=~\"^SQL.*\",sql_instance=~\"^$instance\"}[$__range])",
          "intervalFactor": 1,
          "legendFormat": "{{clerk_type}}",
          "refId": "E",
          "step": 5
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Memory Clerks Size",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "deckbytes",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 53
      },
      "id": 108,
      "panels": [],
      "repeat": null,
      "title": "Database I/O",
      "type": "row"
    },
    {
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "${DS_PROMETHEUS}",
      "fill": 5,
      "fillGradient": 0,
      "gridPos": {
        "h": 7,
        "w": 24,
        "x": 0,
        "y": 54
      },
      "hiddenSeries": false,
      "id": 116,
      "interval": "",
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 2,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "irate(sqlserver_performance_value{counter=~\"^Disk.*IO.*\",exported_instance=\"internal\",sql_instance=~\"^$instance\"}[$__range])",
          "legendFormat": "{{counter}}",
          "refId": "A"
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "IO/sec",
      "tooltip": {
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "decimals": null,
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 61
      },
      "hiddenSeries": false,
      "id": 16,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_read_bytes{file_type=\"DATA\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Rows reads (bytes/sec)",
          "metric": "",
          "policy": "default",
          "query": "SELECT \"AdventureWorks2014\", \"Australian\", \"DOC.Azure\", \"ResumeCloud\", \"ngMon\", \"tempdb\" FROM \"Rows reads (bytes/sec)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database IO' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database IO"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "DATA | Read Throughput",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 61
      },
      "hiddenSeries": false,
      "id": 14,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "hideEmpty": true,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": null,
        "sortDesc": null,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [
        {
          "alias": "Total",
          "yaxis": 2
        }
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_read_bytes{file_type=\"LOG\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Log reads (bytes/sec)",
          "policy": "default",
          "query": "SELECT \"AdventureWorks2014\", \"Australian\", \"DOC.Azure\", \"ResumeCloud\", \"ngMon\", \"tempdb\" FROM \"Log reads (bytes/sec)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database IO' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database IO"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "LOG | Read Throughput",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 68
      },
      "hiddenSeries": false,
      "id": 17,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "hideEmpty": true,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [
        {
          "alias": "Total",
          "yaxis": 2
        }
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_write_bytes{file_type=\"DATA\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Rows writes (bytes/sec)",
          "policy": "default",
          "query": "SELECT \"AdventureWorks2014\", \"Australian\", \"DOC.Azure\", \"ResumeCloud\", \"ngMon\", \"tempdb\" FROM \"Rows writes (bytes/sec)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database IO' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database IO"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "DATA | Write Throughput",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 68
      },
      "hiddenSeries": false,
      "id": 119,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": false,
        "hideEmpty": true,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": null,
        "sortDesc": null,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [
        {
          "alias": "Total",
          "yaxis": 2
        }
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_write_bytes{file_type=\"LOG\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Log reads (bytes/sec)",
          "policy": "default",
          "query": "SELECT \"AdventureWorks2014\", \"Australian\", \"DOC.Azure\", \"ResumeCloud\", \"ngMon\", \"tempdb\" FROM \"Log reads (bytes/sec)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database IO' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database IO"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "LOG | Write Throughput",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 75
      },
      "id": 110,
      "panels": [],
      "repeat": null,
      "title": "Database Latency",
      "type": "row"
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 76
      },
      "hiddenSeries": false,
      "id": 51,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_read_latency_ms{file_type=\"DATA\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Rows read latency (ms)",
          "metric": "",
          "policy": "default",
          "query": "SELECT * FROM \"Rows read latency (ms)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database stats' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database stats"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "DATA | Read Latency (ms)",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "ms",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 76
      },
      "hiddenSeries": false,
      "id": 52,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_read_latency_ms{file_type=\"LOG\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Log read latency (ms)",
          "policy": "default",
          "query": "SELECT * FROM \"Log read latency (ms)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database stats' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database stats"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "LOG | Read Latency (ms)",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "decimals": null,
          "format": "ms",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 83
      },
      "hiddenSeries": false,
      "id": 117,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_write_latency_ms{file_type=\"DATA\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Rows read latency (ms)",
          "metric": "",
          "policy": "default",
          "query": "SELECT * FROM \"Rows read latency (ms)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database stats' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database stats"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "DATA | Write Latency (ms)",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "ms",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 83
      },
      "hiddenSeries": false,
      "id": 118,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "max",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "$col",
          "dsType": "influxdb",
          "expr": "irate(sqlserver_database_io_write_latency_ms{file_type=\"LOG\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [],
          "intervalFactor": 1,
          "legendFormat": "{{database_name}}",
          "measurement": "Log read latency (ms)",
          "policy": "default",
          "query": "SELECT * FROM \"Log read latency (ms)\" WHERE \"servername\" =~ /$Instance$/ AND \"type\" = 'Database stats' AND $timeFilter",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "*"
                ],
                "type": "field"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "servername",
              "operator": "=~",
              "value": "/$Instance$/"
            },
            {
              "condition": "AND",
              "key": "type",
              "operator": "=",
              "value": "Database stats"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "LOG | Write Latency (ms)",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 2,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "decimals": null,
          "format": "ms",
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "Bps",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 90
      },
      "id": 105,
      "panels": [],
      "repeat": null,
      "title": "Waits Statistics",
      "type": "row"
    },
    {
      "alerting": {},
      "aliasColors": {
        "WaitTime.TOTAL": "#BF1B00"
      },
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 91
      },
      "hiddenSeries": false,
      "id": 13,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "total",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [
        {
          "alias": "Total",
          "fill": 0,
          "lines": true,
          "linewidth": 2,
          "yaxis": 2
        }
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "irate(sqlserver_waitstats_wait_time_ms{sql_instance=~\"^$instance\"}[$__range])",
          "intervalFactor": 1,
          "legendFormat": "{{wait_category}} {{wait_type}}",
          "refId": "L",
          "step": 5
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Wait Time",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "ms",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "ms",
          "label": "Total",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {
        "WaitTime.TOTAL": "#BF1B00"
      },
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "editable": true,
      "error": false,
      "fill": 5,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 91
      },
      "hiddenSeries": false,
      "id": 98,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "rightSide": true,
        "show": true,
        "sort": "total",
        "sortDesc": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "png",
      "seriesOverrides": [
        {
          "alias": "Total",
          "fill": 0,
          "lines": true,
          "linewidth": 2,
          "yaxis": 2
        }
      ],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "expr": "irate(sqlserver_waitstats_waiting_tasks_count{sql_instance=~\"^$instance\"}[$__range])",
          "intervalFactor": 1,
          "legendFormat": "{{wait_category}} {{wait_type}}",
          "refId": "L",
          "step": 5
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Wait Tasks",
      "tooltip": {
        "msResolution": false,
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "label": "",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "none",
          "label": "Total",
          "logBase": 1,
          "max": null,
          "min": null,
          "show": false
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 98
      },
      "id": 114,
      "panels": [],
      "repeat": null,
      "title": "Availability Replica",
      "type": "row"
    },
    {
      "alerting": {},
      "aliasColors": {
        "Bytes Sent to Replica/sec | _Total | Availability Replica.mean": "#1F78C1"
      },
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "fill": 1,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 0,
        "y": 99
      },
      "hiddenSeries": false,
      "id": 88,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 2,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Bytes Sent to Replica/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "{{counter}}",
          "measurement": "Bytes Sent to Replica/sec | _Total | Availability Replica",
          "metric": "",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            },
            {
              "condition": "AND",
              "key": "servername",
              "operator": "=~",
              "value": "/^$Instance$/"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "OUT | Bytes sent to Replica/sec",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "fill": 1,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 12,
        "y": 99
      },
      "hiddenSeries": false,
      "id": 87,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 2,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Bytes Received from Replica/sec\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "{{counter}}",
          "measurement": "Bytes Received from Replica/sec | _Total | Availability Replica",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            },
            {
              "condition": "AND",
              "key": "servername",
              "operator": "=~",
              "value": "/^$Instance$/"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "IN | Bytes received from Replica/sec",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "Bps",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {
        "Transaction Delay | _Total | Database Replica.mean": "#BF1B00"
      },
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "fill": 1,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 0,
        "y": 107
      },
      "hiddenSeries": false,
      "id": 96,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 2,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "sqlserver_performance_value{counter=\"Transaction Delay\",database_name=\"master\",exported_instance=\"Total\",sql_instance=~\"^$instance\"}",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "{{servername}}",
          "measurement": "Transaction Delay | _Total | Database Replica",
          "metric": "",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            },
            {
              "condition": "AND",
              "key": "servername",
              "operator": "=~",
              "value": "/^$Instance$/"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Transaction Delay",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "none",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    },
    {
      "alerting": {},
      "aliasColors": {
        "Mirrored Write Transactions/sec | _Total | Database Replica.mean": "#5195CE"
      },
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": "$datasource",
      "decimals": 2,
      "editable": true,
      "error": false,
      "fill": 1,
      "fillGradient": 0,
      "grid": {},
      "gridPos": {
        "h": 8,
        "w": 12,
        "x": 12,
        "y": 107
      },
      "hiddenSeries": false,
      "id": 97,
      "legend": {
        "alignAsTable": true,
        "avg": true,
        "current": true,
        "hideEmpty": false,
        "hideZero": false,
        "max": true,
        "min": false,
        "show": true,
        "total": false,
        "values": true
      },
      "lines": true,
      "linewidth": 2,
      "links": [],
      "nullPointMode": "null",
      "options": {
        "dataLinks": []
      },
      "percentage": false,
      "pointradius": 5,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "dsType": "influxdb",
          "expr": "irate(sqlserver_performance_value{counter=\"Mirrored Write Transactions/sec\",sql_instance=~\"^$instance\"}[$__range])",
          "groupBy": [
            {
              "params": [
                "$interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "intervalFactor": 1,
          "legendFormat": "{{servername}}",
          "measurement": "Mirrored Write Transactions/sec | _Total | Database Replica",
          "metric": "",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "step": 5,
          "tags": [
            {
              "key": "type",
              "operator": "=",
              "value": "Performance counters"
            },
            {
              "condition": "AND",
              "key": "servername",
              "operator": "=~",
              "value": "/^$Instance$/"
            }
          ]
        }
      ],
      "thresholds": [],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "Mirrored Write Transactions/sec",
      "tooltip": {
        "msResolution": true,
        "shared": true,
        "sort": 0,
        "value_type": "cumulative"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "none",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": "0",
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    }
  ],
  "refresh": "1m",
  "schemaVersion": 21,
  "style": "dark",
  "tags": [
    "prometheus",
    "SQL Server"
  ],
  "templating": {
    "list": [
      {
        "current": {
          "text": "Prometheus",
          "value": "Prometheus"
        },
        "hide": 0,
        "includeAll": false,
        "label": "Datasource",
        "multi": false,
        "name": "datasource",
        "options": [],
        "query": "prometheus",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "type": "datasource"
      },
      {
        "allFormat": "glob",
        "allValue": null,
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(sql_instance)",
        "hide": 0,
        "includeAll": false,
        "label": "Instance",
        "multi": false,
        "multiFormat": "glob",
        "name": "instance",
        "options": [],
        "query": "label_values(sql_instance)",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": null,
        "tags": [],
        "tagsQuery": null,
        "type": "query",
        "useTags": false
      }
    ]
  },
  "time": {
    "from": "now-1h",
    "to": "now"
  },
  "timepicker": {
    "now": true,
    "refresh_intervals": [
      "5s",
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ],
    "time_options": [
      "5m",
      "15m",
      "1h",
      "6h",
      "12h",
      "24h",
      "2d",
      "7d",
      "30d"
    ]
  },
  "timezone": "browser",
  "title": "SQL Server Monitoring with prometheus",
  "uid": "CE9gQeYZz",
  "version": 53
}