Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "annotations": {
- "list": [
- {
- "builtIn": 1,
- "datasource": {
- "type": "datasource",
- "uid": "grafana"
- },
- "enable": true,
- "hide": true,
- "iconColor": "rgba(0, 211, 255, 1)",
- "name": "Annotations & Alerts",
- "target": {
- "limit": 100,
- "matchAny": false,
- "tags": [],
- "type": "dashboard"
- },
- "type": "dashboard"
- }
- ]
- },
- "description": "Client Overview",
- "editable": true,
- "fiscalYearStartMonth": 0,
- "graphTooltip": 0,
- "id": 15,
- "iteration": 1649713637911,
- "links": [
- {
- "asDropdown": false,
- "icon": "external link",
- "includeVars": true,
- "keepTime": false,
- "tags": [
- "TRMMAgentDashboard"
- ],
- "targetBlank": false,
- "title": "T-RMM Agent Dashboard",
- "tooltip": "",
- "type": "dashboards",
- "url": ""
- },
- {
- "asDropdown": false,
- "icon": "external link",
- "includeVars": true,
- "keepTime": false,
- "tags": [
- "TRMMClientMap"
- ],
- "targetBlank": false,
- "title": "T-RMM Client Map",
- "tooltip": "",
- "type": "dashboards",
- "url": ""
- }
- ],
- "liveNow": false,
- "panels": [
- {
- "collapsed": false,
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "gridPos": {
- "h": 1,
- "w": 24,
- "x": 0,
- "y": 0
- },
- "id": 47,
- "panels": [],
- "title": "T-RMM Client/Site Information",
- "type": "row"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "Total number of clients",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 0,
- "y": 1
- },
- "id": 31,
- "options": {
- "colorMode": "none",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT\n count(*)\nFROM clients_client\nORDER BY 1",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Total Clients",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "Available sites at selected clients",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 3,
- "y": 1
- },
- "id": 61,
- "options": {
- "colorMode": "none",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT\n count(*)\nFROM clients_site\nINNER JOIN clients_client ON clients_site.client_id = clients_client.id\nwhere \n client_id IN (SELECT id FROM clients_client WHERE name IN ($Client))\nORDER BY 1",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Client Sites",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "Available agents at selected clients/sites",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 6,
- "y": 1
- },
- "id": 60,
- "options": {
- "colorMode": "none",
- "graphMode": "none",
- "justifyMode": "center",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT\n count(*)\nFROM agents_agent\nwhere \n site_id IN (SELECT id FROM clients_site WHERE site_id IN (SELECT id FROM clients_site WHERE name IN ($Sites))) and\n site_id IN (SELECT id FROM clients_site WHERE client_id IN (SELECT id FROM clients_client WHERE name IN ($Client)))\nORDER BY 1",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Client/Site Agents",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "custom": {
- "align": "center",
- "displayMode": "color-background-solid",
- "inspect": false
- },
- "mappings": [
- {
- "options": {
- "Offline": {
- "color": "red",
- "index": 1,
- "text": "X"
- },
- "Online": {
- "color": "green",
- "index": 0,
- "text": "O"
- }
- },
- "type": "value"
- }
- ],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "transparent",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Site"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 150
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Hostname"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 175
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Last Response"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 200
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Last Reboot"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 200
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "agent_id"
- },
- "properties": [
- {
- "id": "custom.hidden",
- "value": true
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "RMM"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 55
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "Open RMM",
- "url": "https://${TacticalURL}/agents/${__data.fields.agent_id}"
- }
- ]
- },
- {
- "id": "custom.displayMode",
- "value": "image"
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Stats"
- },
- "properties": [
- {
- "id": "custom.displayMode",
- "value": "image"
- },
- {
- "id": "custom.width",
- "value": 55
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "Agent Dashboard",
- "url": "https://${GrafanaURL}/d/pLkA1-inz/t-rmm-agent-dashboard?orgId=1&var-Agent=${__data.fields.Hostname}&var-Sites=${__data.fields.Site}"
- }
- ]
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 8,
- "w": 15,
- "x": 9,
- "y": 1
- },
- "id": 59,
- "links": [],
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \n clients_site.name AS \"Site\",\n hostname AS \"Hostname\",\n agents_agent.agent_id,\n 'https://docs.tacticalrmm.com/images/favicon.ico' as \"RMM\",\n 'https://grafana.com/static/assets/img/fav32.png' as \"Stats\",\n (\n CASE\n WHEN last_seen > NOW() - interval '1 minute' THEN 'Online'\n ELSE 'Offline'\n END\n ) AS \"Status\",\n last_seen as \"Last Response\",\n to_timestamp(boot_time) AS \"Last Reboot\"\nFROM agents_agent\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Agent Status",
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "transparent",
- "value": null
- },
- {
- "color": "blue",
- "value": 1
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 0,
- "y": 5
- },
- "id": 24,
- "options": {
- "colorMode": "background",
- "graphMode": "none",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "/.*/",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT CONCAT(\n (SELECT\n count(*)\n FROM\n alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\n WHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'info'\n AND alerts_alert.resolved = false\n ),\n ' / ',\n (SELECT\n count(*)\n FROM\n alerts_alert\n WHERE\n alerts_alert.severity = 'info'\n AND alerts_alert.resolved = false\n )\n)",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Information Alerts",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "transparent",
- "value": null
- },
- {
- "color": "yellow",
- "value": 1.0002
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 3,
- "y": 5
- },
- "id": 20,
- "options": {
- "colorMode": "background",
- "graphMode": "none",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "/.*/",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT CONCAT(\n (SELECT\n count(*)\n FROM\n alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\n WHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'warning'\n AND alerts_alert.resolved = false\n ),\n ' / ',\n (SELECT\n count(*)\n FROM\n alerts_alert\n WHERE\n alerts_alert.severity = 'warning'\n AND alerts_alert.resolved = false\n )\n)",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Warning Alerts",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "transparent",
- "value": null
- },
- {
- "color": "red",
- "value": 1
- }
- ]
- }
- },
- "overrides": []
- },
- "gridPos": {
- "h": 4,
- "w": 3,
- "x": 6,
- "y": 5
- },
- "id": 23,
- "options": {
- "colorMode": "background",
- "graphMode": "none",
- "justifyMode": "auto",
- "orientation": "auto",
- "reduceOptions": {
- "calcs": [
- "lastNotNull"
- ],
- "fields": "/.*/",
- "values": false
- },
- "text": {
- "valueSize": 48
- },
- "textMode": "auto"
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT CONCAT(\n (SELECT\n count(*)\n FROM\n alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\n WHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'error'\n AND alerts_alert.resolved = false\n ),\n ' / ',\n (SELECT\n count(*)\n FROM\n alerts_alert\n WHERE\n alerts_alert.severity = 'error'\n AND alerts_alert.resolved = false\n )\n)",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Error Alerts",
- "type": "stat"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "custom": {
- "align": "auto",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Date"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 135
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "agent_id"
- },
- "properties": [
- {
- "id": "custom.hidden",
- "value": true
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "RMM"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 45
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "Open RMM",
- "url": "https://${TacticalURL}/agents/${__data.fields.agent_id}"
- }
- ]
- },
- {
- "id": "custom.displayMode",
- "value": "image"
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Message"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 421
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 8,
- "w": 8,
- "x": 0,
- "y": 9
- },
- "id": 57,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \n alerts_alert.alert_time as \"Date\",\n alerts_alert.message as \"Message\",\n agents_agent.agent_id,\n 'https://docs.tacticalrmm.com/images/favicon.ico' as \"RMM\"\nFROM alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'info' \n AND alerts_alert.resolved = false",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Information Messages",
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "custom": {
- "align": "auto",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- },
- "unit": "percent"
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Date"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 135
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "agent_id"
- },
- "properties": [
- {
- "id": "custom.hidden",
- "value": true
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "RMM"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 40
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "Open RMM",
- "url": "https://${TacticalURL}/agents/${__data.fields.agent_id}"
- }
- ]
- },
- {
- "id": "custom.displayMode",
- "value": "image"
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Message"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 421
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 8,
- "w": 8,
- "x": 8,
- "y": 9
- },
- "id": 18,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \n alerts_alert.alert_time as \"Date\",\n alerts_alert.message as \"Message\",\n agents_agent.agent_id,\n 'https://docs.tacticalrmm.com/images/favicon.ico' as \"RMM\"\nFROM alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'warning' \n AND alerts_alert.resolved = false",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Warning Messages",
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "fieldConfig": {
- "defaults": {
- "color": {
- "mode": "thresholds"
- },
- "custom": {
- "align": "auto",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- },
- {
- "color": "red",
- "value": 80
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Date"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 150
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "agent_id"
- },
- "properties": [
- {
- "id": "custom.hidden",
- "value": true
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "RMM"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 45
- },
- {
- "id": "links",
- "value": [
- {
- "targetBlank": true,
- "title": "Open RMM",
- "url": "https://${TacticalURL}/agents/${__data.fields.agent_id}"
- }
- ]
- },
- {
- "id": "custom.displayMode",
- "value": "image"
- }
- ]
- },
- {
- "matcher": {
- "id": "byName",
- "options": "Message"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 407
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 8,
- "w": 8,
- "x": 16,
- "y": 9
- },
- "id": 33,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \n alerts_alert.alert_time as \"Date\",\n alerts_alert.message as \"Message\",\n agents_agent.agent_id,\n 'https://docs.tacticalrmm.com/images/favicon.ico' as \"RMM\"\nFROM alerts_alert\n LEFT JOIN checks_check on alerts_alert.assigned_check_id = checks_check.id\n LEFT JOIN autotasks_automatedtask on alerts_alert.assigned_task_id = autotasks_automatedtask.id\n INNER JOIN agents_agent ON autotasks_automatedtask.agent_id = agents_agent.id\n OR checks_check.agent_id = agents_agent.id\n OR alerts_alert.agent_id = agents_agent.id\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\n AND alerts_alert.severity = 'error' \n AND alerts_alert.resolved = false",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Error Messages",
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "fixedColor": "semi-dark-green",
- "mode": "fixed"
- },
- "custom": {
- "align": "center",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Operating System"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 455
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 10,
- "w": 8,
- "x": 0,
- "y": 17
- },
- "id": 26,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \r\n count(*) as \"count\",\r\n SUBSTRING(agents_agent.operating_system,'(.*)(?:,|x86_64)') AS \"Operating System\"\r\nFROM agents_agent\r\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\r\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\r\nWHERE\r\n clients_client.name IN ($Client)\r\n AND clients_site.name IN ($Sites)\r\nGroup by \"Operating System\"\r\nOrder by \"count\" desc",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Installed Operating Systems",
- "transformations": [
- {
- "id": "organize",
- "options": {
- "excludeByName": {},
- "indexByName": {
- "Operating System": 0,
- "count": 1
- },
- "renameByName": {
- "count": "Count"
- }
- }
- }
- ],
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "fixedColor": "semi-dark-green",
- "mode": "fixed"
- },
- "custom": {
- "align": "center",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "CPU Name"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 455
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 10,
- "w": 8,
- "x": 8,
- "y": 17
- },
- "id": 54,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": "SELECT \n count(*) as \"count\",\n (CASE \n WHEN wmi_detail->'cpu' IS NOT NULL\n THEN SUBSTRING(agents_agent.wmi_detail->'cpu'->0->0->>'Name','(?:AMD|Intel\\(R\\)|Intel)(.*)(?:@|Processor|with)')\n ELSE SUBSTRING(agents_agent.wmi_detail->'cpus'->>0,'(?:AMD|Intel\\(R\\)|Intel)(.*)(?:@|Processor|with)')\n END) as \"CPU Name\"\nFROM agents_agent\n INNER JOIN clients_site ON agents_agent.site_id = clients_site.id\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)\n AND clients_site.name IN ($Sites)\nGroup by \"CPU Name\"\nOrder by \"count\" desc",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Type of CPUs",
- "transformations": [
- {
- "id": "organize",
- "options": {
- "excludeByName": {},
- "indexByName": {
- "CPU Name": 0,
- "count": 1
- },
- "renameByName": {
- "count": "Count"
- }
- }
- }
- ],
- "type": "table"
- },
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "description": "",
- "fieldConfig": {
- "defaults": {
- "color": {
- "fixedColor": "semi-dark-green",
- "mode": "fixed"
- },
- "custom": {
- "align": "center",
- "displayMode": "auto",
- "inspect": false
- },
- "mappings": [],
- "thresholds": {
- "mode": "absolute",
- "steps": [
- {
- "color": "green",
- "value": null
- }
- ]
- }
- },
- "overrides": [
- {
- "matcher": {
- "id": "byName",
- "options": "Size Memory"
- },
- "properties": [
- {
- "id": "custom.width",
- "value": 455
- }
- ]
- }
- ]
- },
- "gridPos": {
- "h": 10,
- "w": 8,
- "x": 16,
- "y": 17
- },
- "id": 55,
- "options": {
- "footer": {
- "fields": "",
- "reducer": [
- "sum"
- ],
- "show": false
- },
- "showHeader": true,
- "sortBy": []
- },
- "pluginVersion": "v1.0",
- "targets": [
- {
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "format": "table",
- "group": [],
- "metricColumn": "none",
- "rawQuery": true,
- "rawSql": " SELECT \r\n count(*) as \"count\",\r\n concat((total_ram),' GB') as \"Size Memory\"\r\n FROM agents_agent\r\nINNER JOIN clients_site on site_id = clients_site.id\r\nWHERE site_id IN (SELECT id FROM clients_site WHERE client_id IN (SELECT id FROM clients_client WHERE name IN ($Client)))\r\nAND site_id IN (SELECT id FROM clients_site WHERE site_id IN (SELECT id FROM clients_site WHERE name IN ($Sites)))\r\nGroup by \"Size Memory\"\r\nOrder by \"count\" desc",
- "refId": "A",
- "select": [
- [
- {
- "params": [
- "boot_time"
- ],
- "type": "column"
- }
- ]
- ],
- "table": "agents_agent",
- "timeColumn": "last_seen",
- "timeColumnType": "timestamp",
- "where": [
- {
- "name": "$__timeFilter",
- "params": [],
- "type": "macro"
- }
- ]
- }
- ],
- "title": "Installed System RAM",
- "transformations": [
- {
- "id": "organize",
- "options": {
- "excludeByName": {},
- "indexByName": {
- "Size Memory": 0,
- "count": 1
- },
- "renameByName": {
- "count": "Count"
- }
- }
- }
- ],
- "type": "table"
- }
- ],
- "refresh": "",
- "schemaVersion": 36,
- "style": "dark",
- "tags": [
- "TRMMClientOverview"
- ],
- "templating": {
- "list": [
- {
- "current": {
- "selected": false,
- "text": "All",
- "value": "$__all"
- },
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "definition": "SELECT name FROM clients_client",
- "hide": 0,
- "includeAll": true,
- "multi": false,
- "name": "Client",
- "options": [],
- "query": "SELECT name FROM clients_client",
- "refresh": 1,
- "regex": "",
- "skipUrlSync": false,
- "sort": 0,
- "tagValuesQuery": "",
- "tagsQuery": "",
- "type": "query",
- "useTags": false
- },
- {
- "current": {
- "selected": false,
- "text": "All",
- "value": "$__all"
- },
- "datasource": {
- "type": "postgres",
- "uid": "${Tactical}"
- },
- "definition": "SELECT\n clients_site.name\nFROM\n clients_site\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)",
- "hide": 0,
- "includeAll": true,
- "multi": false,
- "name": "Sites",
- "options": [],
- "query": "SELECT\n clients_site.name\nFROM\n clients_site\n INNER JOIN clients_client ON clients_site.client_id = clients_client.id\nWHERE\n clients_client.name IN ($Client)",
- "refresh": 1,
- "regex": "",
- "skipUrlSync": false,
- "sort": 0,
- "type": "query"
- },
- {
- "current": {
- "selected": false,
- "text": "TacticalRMM",
- "value": "TacticalRMM"
- },
- "hide": 2,
- "includeAll": false,
- "multi": false,
- "name": "Tactical",
- "options": [],
- "query": "postgres",
- "refresh": 1,
- "regex": "TacticalRMM",
- "skipUrlSync": false,
- "type": "datasource"
- },
- {
- "current": {
- "selected": false,
- "text": "rmm.example.com",
- "value": "rmm.example.com"
- },
- "hide": 0,
- "includeAll": false,
- "multi": false,
- "name": "TacticalURL",
- "options": [
- {
- "selected": true,
- "text": "rmm.example.com",
- "value": "rmm.example.com"
- }
- ],
- "query": "rmm.example.com",
- "skipUrlSync": false,
- "type": "custom"
- },
- {
- "current": {
- "selected": false,
- "text": "grafana.example.com",
- "value": "grafana.example.com"
- },
- "hide": 0,
- "includeAll": false,
- "multi": false,
- "name": "GrafanaURL",
- "options": [
- {
- "selected": true,
- "text": "grafana.example.com",
- "value": "grafana.example.com"
- }
- ],
- "query": "grafana.example.com",
- "skipUrlSync": false,
- "type": "custom"
- }
- ]
- },
- "time": {
- "from": "now-1h",
- "to": "now"
- },
- "timepicker": {
- "hidden": false,
- "refresh_intervals": [
- "5s",
- "10s",
- "30s",
- "1m",
- "5m",
- "15m",
- "30m",
- "1h",
- "2h",
- "1d"
- ]
- },
- "timezone": "browser",
- "title": "T-RMM Client Overview",
- "uid": "cagnefi7z",
- "version": 41,
- "weekStart": ""
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement