{
"__inputs": [
{
"name": "DS_TEST-ENVIORMENT-K8S",
"label": "test-enviorment-k8s",
"description": "",
"type": "datasource",
"pluginId": "prometheus",
"pluginName": "Prometheus"
},
{
"name": "DS_ZABBIX_ TEST SERVER",
"label": "zabbix test server",
"description": "",
"type": "datasource",
"pluginId": "alexanderzobnin-zabbix-datasource",
"pluginName": "Zabbix"
}
],
"__requires": [
{
"type": "datasource",
"id": "alexanderzobnin-zabbix-datasource",
"name": "Zabbix",
"version": "1.0.0"
},
{
"type": "grafana",
"id": "grafana",
"name": "Grafana",
"version": "4.4.3"
},
{
"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": []
},
"editable": true,
"gnetId": null,
"graphTooltip": 0,
"hideControls": false,
"id": null,
"links": [],
"refresh": false,
"rows": [
{
"collapse": false,
"height": 168,
"panels": [
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": true,
"colors": [
"rgba(50, 172, 45, 0.97)",
"rgba(237, 129, 40, 0.89)",
"rgba(245, 54, 54, 0.9)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"format": "percent",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": true,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 14,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "(sum(container_memory_working_set_bytes{container_name=\"$PROJECT_NAME\"})/ sum(node_memory_MemTotal))*100",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "20,50",
"title": "内存使用集群占比",
"transparent": false,
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(50, 172, 45, 0.97)",
"rgba(237, 129, 40, 0.89)",
"rgba(245, 54, 54, 0.9)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"decimals": 2,
"format": "percent",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": true,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 1,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "sum (rate (container_cpu_usage_seconds_total{container_name=\"$PROJECT_NAME\"}[1m])) / sum (machine_cpu_cores{kubernetes_io_hostname=~\"^$Node$\"}) * 100",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "",
"metric": "container_cpu_user_seconds_total",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "65,90",
"title": "CPU使用集群占比",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"decimals": 0,
"format": "short",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 4,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 4,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "count(container_fs_io_current{container_name=\"$PROJECT_NAME\"})",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"interval": "",
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "",
"metric": "",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "",
"title": "容器数量",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": -925,
"panels": [
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"decimals": null,
"format": "bytes",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 3,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "sum(container_memory_usage_bytes{container_name=\"$PROJECT_NAME\"})",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "",
"metric": "container_memory_usage_bytes",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "",
"title": "内存使用总量",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"format": "decbytes",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 15,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "sum(node_memory_MemTotal)",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "",
"title": "集群总内存",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"decimals": 2,
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 16,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "cores",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "sum (rate (container_cpu_usage_seconds_total{id=\"/\",kubernetes_io_hostname=~\"^$Node$\"}[1m])) / sum (machine_cpu_cores{kubernetes_io_hostname=~\"^$Node$\"}) * 100",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "",
"title": "cpu使用量",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"decimals": 2,
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 17,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "cores",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{
"application": {
"filter": ""
},
"expr": "sum (machine_cpu_cores{kubernetes_io_hostname=~\"^$Node$\"})",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 40
}
],
"thresholds": "",
"title": "CPU总量",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_ZABBIX_ TEST SERVER}",
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 19,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{}
],
"thresholds": "",
"title": "Panel Title",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
},
{
"cacheTimeout": null,
"colorBackground": false,
"colorValue": false,
"colors": [
"rgba(245, 54, 54, 0.9)",
"rgba(237, 129, 40, 0.89)",
"rgba(50, 172, 45, 0.97)"
],
"datasource": "${DS_ZABBIX_ TEST SERVER}",
"format": "none",
"gauge": {
"maxValue": 100,
"minValue": 0,
"show": false,
"thresholdLabels": false,
"thresholdMarkers": true
},
"id": 20,
"interval": null,
"links": [],
"mappingType": 1,
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"maxDataPoints": 100,
"nullPointMode": "connected",
"nullText": null,
"postfix": "",
"postfixFontSize": "50%",
"prefix": "",
"prefixFontSize": "50%",
"rangeMaps": [
{
"from": "null",
"text": "N/A",
"to": "null"
}
],
"span": 2,
"sparkline": {
"fillColor": "rgba(31, 118, 189, 0.18)",
"full": false,
"lineColor": "rgb(31, 120, 193)",
"show": false
},
"tableColumn": "",
"targets": [
{}
],
"thresholds": "",
"title": "Panel Title",
"type": "singlestat",
"valueFontSize": "80%",
"valueMaps": [
{
"op": "=",
"text": "N/A",
"value": "null"
}
],
"valueName": "avg"
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 249,
"panels": [
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 5,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": true,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "container_memory_usage_bytes{container_name=\"$PROJECT_NAME\"}",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{ pod_name }}",
"metric": "container_memory_usage_bytes",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "当前内存使用量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": "0",
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 9,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "container_memory_working_set_bytes{container_name=\"$PROJECT_NAME\"}",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{ pod_name }}",
"metric": "container_memory_working_set_bytes",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "当前使用的内存",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": "0",
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 7,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "container_memory_cache{container_name=\"$PROJECT_NAME\"}",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{ pod_name }}",
"metric": "container_memory_cache",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "内存缓存使用量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": "0",
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": true,
"title": "内存使用详情",
"titleSize": "h6"
},
{
"collapse": false,
"height": 246,
"panels": [
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 6,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "container_memory_swap{container_name=\"$PROJECT_NAME\"}",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{ pod_name }}",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "交换分区使用量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "decbytes",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"alert": {
"conditions": [
{
"evaluator": {
"params": [
0,
0
],
"type": "within_range"
},
"operator": {
"type": "and"
},
"query": {
"params": [
"A",
"5m",
"now"
]
},
"reducer": {
"params": [],
"type": "avg"
},
"type": "query"
}
],
"executionErrorState": "alerting",
"frequency": "60s",
"handler": 1,
"message": "test内存。",
"name": "内存缺页数量 alert",
"noDataState": "no_data",
"notifications": []
},
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 8,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "container_memory_failcnt{container_name=\"$PROJECT_NAME\"}",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{ pod_name }}",
"metric": "container_memory_failcnt",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
}
],
"thresholds": [
{
"colorMode": "critical",
"fill": true,
"line": true,
"op": "gt",
"value": 0
},
{
"colorMode": "critical",
"fill": true,
"line": true,
"op": "lt",
"value": 0
}
],
"timeFrom": null,
"timeShift": null,
"title": "内存缺页数量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_ZABBIX_ TEST SERVER}",
"fill": 1,
"id": 21,
"legend": {
"alignAsTable": true,
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 4,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": "SWAP"
},
"expr": "",
"format": "time_series",
"functions": [],
"group": {
"filter": "TEST-K8S"
},
"host": {
"filter": "/.*/"
},
"intervalFactor": 2,
"item": {
"filter": "剩余交换空间"
},
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A"
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "交换分区剩余大小",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": true,
"title": "交换分区使用详情",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 13,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 6,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "rate(container_cpu_system_seconds_total{container_name=\"$PROJECT_NAME\"}[1m])",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{pod_name}}",
"metric": "",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
},
{
"expr": "sum(rate(container_cpu_system_seconds_total{container_name=\"$PROJECT_NAME\"}[1m]))",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "total",
"refId": "B",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "CPU内核使用",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 22,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 6,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "rate(container_cpu_user_seconds_total{container_name=\"$PROJECT_NAME\"}[1m])",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{pod_name}}",
"metric": "container_cpu_user_seconds_total",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
},
{
"expr": "sum(rate(container_cpu_user_seconds_total{container_name=\"$PROJECT_NAME\"}[1m]))",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "Total",
"refId": "B",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "CPU用户使用",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 23,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 6,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "rate(container_network_transmit_bytes_total{pod_name=~\"$PROJECT_NAME.*\"}[3m])",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{pod_name}}",
"metric": "container_network_transmit_bytes_total",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
},
{
"expr": "sum(rate(container_network_transmit_bytes_total{pod_name=~\"$PROJECT_NAME.*\"}[1m]))",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "Total",
"refId": "B",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "网络发送数据量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
},
{
"aliasColors": {
"activemq-deployment-2605359794-s2c21": "#890F02"
},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"fill": 1,
"id": 24,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"span": 6,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": ""
},
"expr": "rate(container_network_receive_bytes_total{pod_name=~\"$PROJECT_NAME.*\"}[3m])",
"format": "time_series",
"functions": [],
"group": {
"filter": ""
},
"host": {
"filter": ""
},
"intervalFactor": 2,
"item": {
"filter": ""
},
"legendFormat": "{{pod_name}}",
"metric": "container_network_receive_bytes_total",
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A",
"step": 4
},
{
"expr": "sum(rate(container_network_receive_bytes_total{pod_name=~\"$PROJECT_NAME.*\"}[1m]))",
"format": "time_series",
"intervalFactor": 2,
"legendFormat": "Total",
"refId": "B",
"step": 4
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "接收数据量",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "bytes",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
},
{
"collapse": false,
"height": 250,
"panels": [
{
"aliasColors": {},
"bars": false,
"dashLength": 10,
"dashes": false,
"datasource": "${DS_ZABBIX_ TEST SERVER}",
"fill": 1,
"id": 25,
"legend": {
"avg": false,
"current": false,
"max": false,
"min": false,
"show": true,
"total": false,
"values": false
},
"lines": true,
"linewidth": 1,
"links": [],
"minSpan": null,
"nullPointMode": "null",
"percentage": false,
"pointradius": 5,
"points": false,
"renderer": "flot",
"repeat": null,
"seriesOverrides": [],
"spaceLength": 10,
"span": 2,
"stack": false,
"steppedLine": false,
"targets": [
{
"application": {
"filter": "$Node"
},
"functions": [],
"group": {
"filter": "TEST-K8S"
},
"host": {
"filter": "192.168.7.203"
},
"item": {
"filter": "/ 的使用容量"
},
"mode": 0,
"options": {
"showDisabledItems": false
},
"refId": "A"
}
],
"thresholds": [],
"timeFrom": null,
"timeShift": null,
"title": "Panel Title",
"tooltip": {
"shared": true,
"sort": 0,
"value_type": "individual"
},
"transparent": false,
"type": "graph",
"xaxis": {
"buckets": null,
"mode": "time",
"name": null,
"show": true,
"values": []
},
"yaxes": [
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
},
{
"format": "short",
"label": null,
"logBase": 1,
"max": null,
"min": null,
"show": true
}
]
}
],
"repeat": null,
"repeatIteration": null,
"repeatRowId": null,
"showTitle": false,
"title": "Dashboard Row",
"titleSize": "h6"
}
],
"schemaVersion": 14,
"style": "dark",
"tags": [
"prometheus"
],
"templating": {
"list": [
{
"allValue": null,
"current": {
"tags": [],
"text": "jenkins",
"value": "jenkins"
},
"hide": 0,
"includeAll": false,
"label": "container_name",
"multi": false,
"name": "PROJECT_NAME",
"options": [
{
"selected": false,
"text": "activemq",
"value": "activemq"
},
{
"selected": false,
"text": "grafana",
"value": "grafana"
},
{
"selected": true,
"text": "jenkins",
"value": "jenkins"
},
{
"selected": false,
"text": "nexus",
"value": "nexus"
},
{
"selected": false,
"text": "nginx-zhenghaohuaphpapp",
"value": "nginx-zhenghaohuaphpapp"
},
{
"selected": false,
"text": "nginx-zhenghaohuaphpweb",
"value": "nginx-zhenghaohuaphpweb"
},
{
"selected": false,
"text": "showdoc",
"value": "showdoc"
},
{
"selected": false,
"text": "tomcat-afterloanall",
"value": "tomcat-afterloanall"
},
{
"selected": false,
"text": "tomcat-afterloangit",
"value": "tomcat-afterloangit"
},
{
"selected": false,
"text": "tomcat-api",
"value": "tomcat-api"
},
{
"selected": false,
"text": "tomcat-beanstechweb",
"value": "tomcat-beanstechweb"
},
{
"selected": false,
"text": "tomcat-cas-dev",
"value": "tomcat-cas-dev"
},
{
"selected": false,
"text": "tomcat-cas",
"value": "tomcat-cas"
},
{
"selected": false,
"text": "tomcat-cashcustomersvc",
"value": "tomcat-cashcustomersvc"
},
{
"selected": false,
"text": "tomcat-cashloanapr",
"value": "tomcat-cashloanapr"
},
{
"selected": false,
"text": "tomcat-cashruleengine",
"value": "tomcat-cashruleengine"
},
{
"selected": false,
"text": "tomcat-commonservices",
"value": "tomcat-commonservices"
},
{
"selected": false,
"text": "tomcat-credit",
"value": "tomcat-credit"
},
{
"selected": false,
"text": "tomcat-financial",
"value": "tomcat-financial"
},
{
"selected": false,
"text": "tomcat-loanactivity",
"value": "tomcat-loanactivity"
},
{
"selected": false,
"text": "tomcat-loanactivity-test",
"value": "tomcat-loanactivity-test"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-api-branch",
"value": "tomcat-loanaudit-web-api-branch"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-api",
"value": "tomcat-loanaudit-web-api"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-audit-branch",
"value": "tomcat-loanaudit-web-audit-branch"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-audit",
"value": "tomcat-loanaudit-web-audit"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-sale-branch",
"value": "tomcat-loanaudit-web-sale-branch"
},
{
"selected": false,
"text": "tomcat-loanaudit-web-sale",
"value": "tomcat-loanaudit-web-sale"
},
{
"selected": false,
"text": "tomcat-loanaudittask-branch",
"value": "tomcat-loanaudittask-branch"
},
{
"selected": false,
"text": "tomcat-loanaudittask",
"value": "tomcat-loanaudittask"
},
{
"selected": false,
"text": "tomcat-newsalary",
"value": "tomcat-newsalary"
},
{
"selected": false,
"text": "tomcat-operation-dev",
"value": "tomcat-operation-dev"
},
{
"selected": false,
"text": "tomcat-operation",
"value": "tomcat-operation"
},
{
"selected": false,
"text": "tomcat-paperless-ht",
"value": "tomcat-paperless-ht"
},
{
"selected": false,
"text": "tomcat-paperless-proxy",
"value": "tomcat-paperless-proxy"
},
{
"selected": false,
"text": "tomcat-paperless-server",
"value": "tomcat-paperless-server"
},
{
"selected": false,
"text": "tomcat-payment",
"value": "tomcat-payment"
},
{
"selected": false,
"text": "tomcat-reports-tester",
"value": "tomcat-reports-tester"
},
{
"selected": false,
"text": "tomcat-ruleengine",
"value": "tomcat-ruleengine"
},
{
"selected": false,
"text": "tomcat-salary-tester",
"value": "tomcat-salary-tester"
},
{
"selected": false,
"text": "tomcat-settle",
"value": "tomcat-settle"
},
{
"selected": false,
"text": "tomcat-submenu",
"value": "tomcat-submenu"
},
{
"selected": false,
"text": "tomcat-uat-cas",
"value": "tomcat-uat-cas"
},
{
"selected": false,
"text": "tomcat-uat-consumptionapproval",
"value": "tomcat-uat-consumptionapproval"
},
{
"selected": false,
"text": "tomcat-uat-consumptionsale",
"value": "tomcat-uat-consumptionsale"
},
{
"selected": false,
"text": "tomcat-uat-operation tomcat-xdapp",
"value": "tomcat-uat-operation tomcat-xdapp"
}
],
"query": "activemq ,grafana ,jenkins ,nexus ,nginx-zhenghaohuaphpapp ,nginx-zhenghaohuaphpweb ,showdoc ,tomcat-afterloanall ,tomcat-afterloangit ,tomcat-api ,tomcat-beanstechweb ,tomcat-cas-dev ,tomcat-cas ,tomcat-cashcustomersvc ,tomcat-cashloanapr ,tomcat-cashruleengine ,tomcat-commonservices ,tomcat-credit ,tomcat-financial ,tomcat-loanactivity ,tomcat-loanactivity-test ,tomcat-loanaudit-web-api-branch ,tomcat-loanaudit-web-api ,tomcat-loanaudit-web-audit-branch ,tomcat-loanaudit-web-audit ,tomcat-loanaudit-web-sale-branch ,tomcat-loanaudit-web-sale ,tomcat-loanaudittask-branch ,tomcat-loanaudittask ,tomcat-newsalary ,tomcat-operation-dev ,tomcat-operation ,tomcat-paperless-ht ,tomcat-paperless-proxy ,tomcat-paperless-server ,tomcat-payment ,tomcat-reports-tester ,tomcat-ruleengine ,tomcat-salary-tester ,tomcat-settle ,tomcat-submenu ,tomcat-uat-cas ,tomcat-uat-consumptionapproval ,tomcat-uat-consumptionsale ,tomcat-uat-operation tomcat-xdapp",
"type": "custom"
},
{
"allValue": ".*",
"current": {},
"datasource": "${DS_TEST-ENVIORMENT-K8S}",
"hide": 2,
"includeAll": true,
"label": null,
"multi": false,
"name": "Node",
"options": [],
"query": "label_values(kubernetes_io_hostname)",
"refresh": 1,
"regex": "",
"sort": 0,
"tagValuesQuery": "",
"tags": [],
"tagsQuery": "",
"type": "query",
"useTags": false
}
]
},
"time": {
"from": "now-30m",
"to": "now"
},
"timepicker": {
"refresh_intervals": [
"5s",
"10s",
"30s",
"1m",
"5m",
"15m",
"30m",
"1h",
"2h",
"1d"
],
"time_options": [
"5m",
"15m",
"1h",
"6h",
"12h",
"24h",
"2d",
"7d",
"30d"
]
},
"timezone": "",
"title": "测试环境K8S集群监控",
"version": 14
}

K8s仪表盘的更多相关文章

  1. 30分钟学会Docker里面开启k8s(Kubernetes)登录仪表盘(图文讲解)

    前言 我们之前搭建了第一个docker项目: windows环境30分钟从0开始快速搭建第一个docker项目(带数据库交互):https://www.cnblogs.com/xiongze520/p ...

  2. Kubernetes监控实践

    一.Kubernetes介绍 Kubernetes(K8s)是一个开源平台,能够有效简化应用管理.应用部署和应用扩展环节的手动操作流程,让用户更加灵活地部署管理云端应用. 作为可扩展的容错平台,K8s ...

  3. 【k8s第三步】Kubernetes-Dashboard仪表盘【已修正错误】

    ⒈下载描述文件 wget https://raw.githubusercontent.com/kubernetes/dashboard/v2.0.0-beta6/aio/deploy/recommen ...

  4. K8s 入门

    中文文档:https://www.kubernetes.org.cn/kubernetes%E8%AE%BE%E8%AE%A1%E6%9E%B6%E6%9E%84 小结大白话 Portainer 挺好 ...

  5. Rancher2.0构建kubernetes(K8S)集群

    一.环境准备 1.准备至少3台CentOS7版本的虚拟机 # IP地址 主机名称 192.168.1.160 rancher 192.168.1.161 master 192.168.1.162 no ...

  6. 基于k8s的promethus监控

    没有监控 就没有眼睛. 除了k8s的基本监控外(pod运行状况.占用内存.cpu).为了对微服务项目中的(1)各种参数线程池.QPS.RT.业务指标(2)系统负载.thread.mem.class.t ...

  7. 使用Kubeadm创建k8s集群之节点部署(三十一)

    前言 本篇部署教程将讲述k8s集群的节点(master和工作节点)部署,请先按照上一篇教程完成节点的准备.本篇教程中的操作全部使用脚本完成,并且对于某些情况(比如镜像拉取问题)还提供了多种解决方案.不 ...

  8. 云原生生态周报 Vol.10 | 数据库能否运行在 K8s 当中?

    业界要闻  IBM 以总价 340 亿美元完成里程碑意义的红帽收购:这是这家拥有 107 年历史的公司史上规模最大的一笔收购,该收购金额在整个科技行业的并购史上也能排到前三.在当天公布的声明中,IBM ...

  9. Prometheus 监控K8S集群资源监控

    Prometheus 监控K8S集群中Pod 目前cAdvisor集成到了kubelet组件内,可以在kubernetes集群中每个启动了kubelet的节点使用cAdvisor提供的metrics接 ...

随机推荐

  1. [linux] reboot和shutdown-r的区别

    google看看: 先搜英文的资料 http://askubuntu.com/questions/441969/what-is-the-difference-between-reboot-and-sh ...

  2. 【分层最短路】Magical Girl Haze

    https://nanti.jisuanke.com/t/31001 有K次机会可以让一条边的权值变为0,求最短路. 在存储单源最短路的数组上多开一维状态,d[i][k]表示走到序号i的点,且让k条边 ...

  3. 404 Note Found队——现场编程

    目录 组员职责分工 github 的提交日志截图 程序运行截图 程序运行环境 GUI界面 基础功能实现 运行视频 LCG算法 过滤(降权)算法 算法思路 红黑树 附加功能一 背景 实现 附加功能二(迭 ...

  4. lintcode-421-简化路径

    421-简化路径 给定一个文档(Unix-style)的完全路径,请进行路径简化. 样例 "/home/", => "/home" "/a/./ ...

  5. Java throw try catch

    public class Runtest { public static void main(String[] args) { // TODO Auto-generated method stub T ...

  6. python获取前几天的时间

    days的参数就是你想获取前多少天的数据,如果是昨天的话,则days=1 import datetime today=datetime.date.today() oneday=datetime.tim ...

  7. IDEA中Git的更新/提交/还原方法

    记录一下在IDEA上怎样将写的代码提交到GitHub远程库: 下面这个图是基本的提交代码的顺序: 1. 将代码Add到stage暂存区本地修改了代码后,需先将代码add到暂存区,最后才能真正提价到gi ...

  8. 解决svn "cannot set LC_CTYPE locale"的问题

    解决svn "cannot set LC_CTYPE locale"的问题 在ubuntu 8.10下安装的svn,在将Ubuntu的语言修改为英文之后,出现错误警告: $ svn ...

  9. vue-cli3使用cdn方式引入moment.js

    1. index.html引入: <script src="https://cdn.bootcss.com/moment.js/2.20.1/moment.min.js"&g ...

  10. 双主双写、只备份某些表且要在建表ID自增

    先展示下最终实现的配置 主1的配置(重要的,其他略) log-bin = mysql-bin #必须要有binlog auto_increment_offset = 1 #自增ID的初始值 auto_ ...