2023-02-07 20:34:08 +00:00
{
"annotations" : {
"list" : [
{
"builtIn" : 1 ,
"datasource" : {
"type" : "grafana" ,
"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" : "https://docs.kubecost.com/install-and-configure/advanced-configuration/network-costs-configuration" ,
"editable" : true ,
"fiscalYearStartMonth" : 0 ,
"graphTooltip" : 0 ,
2023-09-05 12:51:54 +00:00
"id" : 24 ,
2023-02-07 20:34:08 +00:00
"links" : [ ] ,
"liveNow" : false ,
"panels" : [
{
"collapsed" : false ,
"gridPos" : {
"h" : 1 ,
"w" : 24 ,
"x" : 0 ,
"y" : 0
} ,
"id" : 12 ,
"panels" : [ ] ,
"title" : "Network Data Transfers (negative is egress data)" ,
"type" : "row"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"fieldConfig" : {
"defaults" : {
"color" : {
"mode" : "palette-classic"
} ,
"custom" : {
"axisCenteredZero" : false ,
"axisColorMode" : "text" ,
"axisLabel" : "" ,
"axisPlacement" : "auto" ,
"barAlignment" : 0 ,
2023-09-05 12:51:54 +00:00
"drawStyle" : "bars" ,
"fillOpacity" : 100 ,
2023-02-07 20:34:08 +00:00
"gradientMode" : "none" ,
"hideFrom" : {
"legend" : false ,
"tooltip" : false ,
"viz" : false
} ,
"lineInterpolation" : "linear" ,
"lineWidth" : 1 ,
"pointSize" : 5 ,
"scaleDistribution" : {
"type" : "linear"
} ,
"showPoints" : "auto" ,
"spanNulls" : false ,
"stacking" : {
"group" : "A" ,
"mode" : "none"
} ,
"thresholdsStyle" : {
"mode" : "off"
}
} ,
"mappings" : [ ] ,
"thresholds" : {
"mode" : "absolute" ,
"steps" : [
{
"color" : "green" ,
"value" : null
} ,
{
"color" : "red" ,
"value" : 80
}
]
} ,
2023-09-05 12:51:54 +00:00
"unit" : "bytes"
2023-02-07 20:34:08 +00:00
} ,
"overrides" : [ ]
} ,
"gridPos" : {
"h" : 14 ,
"w" : 11 ,
"x" : 0 ,
"y" : 1
} ,
"id" : 10 ,
"options" : {
"legend" : {
"calcs" : [ ] ,
"displayMode" : "list" ,
"placement" : "bottom" ,
"showLegend" : true
} ,
"tooltip" : {
"mode" : "single" ,
"sort" : "none"
}
} ,
"targets" : [
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "sum(increase(kubecost_pod_network_ingress_bytes_total\n {namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n ))\nby($aggregation) " ,
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "A"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "-sum(increase(kubecost_pod_network_egress_bytes_total\n {namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n ))\nby($aggregation) " ,
2023-02-07 20:34:08 +00:00
"hide" : false ,
2023-09-05 12:51:54 +00:00
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "B"
}
] ,
"title" : "All Data" ,
"type" : "timeseries"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"fieldConfig" : {
"defaults" : {
"color" : {
"mode" : "palette-classic"
} ,
"custom" : {
"axisCenteredZero" : false ,
"axisColorMode" : "text" ,
"axisLabel" : "" ,
"axisPlacement" : "auto" ,
"barAlignment" : 0 ,
2023-09-05 12:51:54 +00:00
"drawStyle" : "bars" ,
"fillOpacity" : 100 ,
2023-02-07 20:34:08 +00:00
"gradientMode" : "none" ,
"hideFrom" : {
"legend" : false ,
"tooltip" : false ,
"viz" : false
} ,
"lineInterpolation" : "linear" ,
"lineWidth" : 1 ,
"pointSize" : 5 ,
"scaleDistribution" : {
"type" : "linear"
} ,
"showPoints" : "auto" ,
"spanNulls" : false ,
"stacking" : {
"group" : "A" ,
"mode" : "none"
} ,
"thresholdsStyle" : {
"mode" : "off"
}
} ,
"mappings" : [ ] ,
"thresholds" : {
"mode" : "absolute" ,
"steps" : [
{
"color" : "green" ,
"value" : null
} ,
{
"color" : "red" ,
"value" : 80
}
]
} ,
2023-09-05 12:51:54 +00:00
"unit" : "bytes"
2023-02-07 20:34:08 +00:00
} ,
"overrides" : [ ]
} ,
"gridPos" : {
"h" : 14 ,
"w" : 13 ,
"x" : 11 ,
"y" : 1
} ,
"id" : 2 ,
"options" : {
"legend" : {
"calcs" : [ ] ,
"displayMode" : "list" ,
"placement" : "bottom" ,
"showLegend" : true
} ,
"tooltip" : {
"mode" : "single" ,
"sort" : "none"
}
} ,
"targets" : [
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]\n))\nby($aggregation) " ,
2023-02-07 20:34:08 +00:00
"hide" : false ,
2023-09-05 12:51:54 +00:00
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "A"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"true\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\"}\n [1h]))\nby($aggregation) " ,
2023-02-07 20:34:08 +00:00
"hide" : false ,
2023-09-05 12:51:54 +00:00
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "B"
}
] ,
"title" : "Internet Data" ,
"type" : "timeseries"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"description" : "Cross region and cross zone subnets must be defined via the configMap. \nSee: \n<https://docs.kubecost.com/install-and-configure/advanced-configuration/network-costs-configuration#overriding-traffic-classifications>" ,
"fieldConfig" : {
"defaults" : {
"color" : {
"mode" : "palette-classic"
} ,
"custom" : {
"axisCenteredZero" : false ,
"axisColorMode" : "text" ,
"axisLabel" : "" ,
"axisPlacement" : "auto" ,
"barAlignment" : 0 ,
2023-09-05 12:51:54 +00:00
"drawStyle" : "bars" ,
"fillOpacity" : 100 ,
2023-02-07 20:34:08 +00:00
"gradientMode" : "none" ,
"hideFrom" : {
"legend" : false ,
"tooltip" : false ,
"viz" : false
} ,
"lineInterpolation" : "linear" ,
"lineWidth" : 1 ,
"pointSize" : 5 ,
"scaleDistribution" : {
"type" : "linear"
} ,
"showPoints" : "auto" ,
"spanNulls" : false ,
"stacking" : {
"group" : "A" ,
"mode" : "none"
} ,
"thresholdsStyle" : {
"mode" : "off"
}
} ,
"decimals" : 2 ,
"mappings" : [ ] ,
"thresholds" : {
"mode" : "absolute" ,
"steps" : [
{
"color" : "green" ,
"value" : null
} ,
{
"color" : "red" ,
"value" : 80
}
]
} ,
2023-09-05 12:51:54 +00:00
"unit" : "bytes"
2023-02-07 20:34:08 +00:00
} ,
"overrides" : [ ]
} ,
"gridPos" : {
"h" : 14 ,
"w" : 11 ,
"x" : 0 ,
"y" : 15
} ,
"id" : 9 ,
"options" : {
"legend" : {
"calcs" : [ ] ,
"displayMode" : "list" ,
"placement" : "bottom" ,
"showLegend" : true
} ,
"tooltip" : {
"mode" : "single" ,
"sort" : "none"
}
} ,
"targets" : [
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"false\",namespace=~\"$namespace\",cluster_id=~\"$cluster\",pod_name=~\"$pod\", sameRegion=\"false\",sameZone=\"false\"}\n [1h]))\nby($aggregation)" ,
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "A"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\",cluster_id=~\"$cluster\",pod_name=~\"$pod\",sameRegion=\"false\", sameZone=\"false\"}\n [1h]))\nby($aggregation) " ,
2023-02-07 20:34:08 +00:00
"hide" : false ,
2023-09-05 12:51:54 +00:00
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "B"
}
] ,
"title" : "Cross Region Data" ,
"type" : "timeseries"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"description" : "Cross region and cross zone subnets must be defined via the configMap. \nSee: \n<https://docs.kubecost.com/install-and-configure/advanced-configuration/network-costs-configuration#overriding-traffic-classifications>" ,
"fieldConfig" : {
"defaults" : {
"color" : {
"mode" : "palette-classic"
} ,
"custom" : {
"axisCenteredZero" : false ,
"axisColorMode" : "text" ,
"axisLabel" : "" ,
"axisPlacement" : "auto" ,
"barAlignment" : 0 ,
2023-09-05 12:51:54 +00:00
"drawStyle" : "bars" ,
"fillOpacity" : 100 ,
2023-02-07 20:34:08 +00:00
"gradientMode" : "none" ,
"hideFrom" : {
"legend" : false ,
"tooltip" : false ,
"viz" : false
} ,
"lineInterpolation" : "linear" ,
"lineWidth" : 1 ,
"pointSize" : 5 ,
"scaleDistribution" : {
"type" : "linear"
} ,
"showPoints" : "auto" ,
"spanNulls" : false ,
"stacking" : {
"group" : "A" ,
"mode" : "none"
} ,
"thresholdsStyle" : {
"mode" : "off"
}
} ,
"decimals" : 2 ,
"mappings" : [ ] ,
"thresholds" : {
"mode" : "absolute" ,
"steps" : [
{
"color" : "green" ,
"value" : null
} ,
{
"color" : "red" ,
"value" : 80
}
]
} ,
2023-09-05 12:51:54 +00:00
"unit" : "bytes"
2023-02-07 20:34:08 +00:00
} ,
"overrides" : [ ]
} ,
"gridPos" : {
"h" : 14 ,
"w" : 13 ,
"x" : 11 ,
"y" : 15
} ,
"id" : 8 ,
"options" : {
"legend" : {
"calcs" : [ ] ,
"displayMode" : "list" ,
"placement" : "bottom" ,
"showLegend" : true
} ,
"tooltip" : {
"mode" : "single" ,
"sort" : "none"
}
} ,
"targets" : [
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "sum(increase(kubecost_pod_network_ingress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}\n [1h]))\nby($aggregation)" ,
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "A"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"editorMode" : "code" ,
2023-09-05 12:51:54 +00:00
"expr" : "- sum(increase(kubecost_pod_network_egress_bytes_total\n {internet=\"false\", namespace=~\"$namespace\", cluster_id=~\"$cluster\", pod_name=~\"$pod\", sameRegion=\"true\", sameZone=\"false\"}\n [1h]))\nby($aggregation)" ,
2023-02-07 20:34:08 +00:00
"hide" : false ,
2023-09-05 12:51:54 +00:00
"interval" : "1h" ,
2023-02-07 20:34:08 +00:00
"legendFormat" : "__auto" ,
"range" : true ,
"refId" : "B"
}
] ,
"title" : "Cross Zone Data" ,
"type" : "timeseries"
}
] ,
2023-09-05 12:51:54 +00:00
"refresh" : "" ,
"revision" : 1 ,
"schemaVersion" : 38 ,
2023-02-07 20:34:08 +00:00
"style" : "dark" ,
"tags" : [
"kubecost"
] ,
"templating" : {
"list" : [
{
"current" : {
2023-09-05 12:51:54 +00:00
"selected" : true ,
2023-02-07 20:34:08 +00:00
"text" : "Prometheus" ,
"value" : "Prometheus"
} ,
"hide" : 0 ,
"includeAll" : false ,
"multi" : false ,
"name" : "datasource" ,
"options" : [ ] ,
"query" : "prometheus" ,
"queryValue" : "" ,
"refresh" : 1 ,
"regex" : "" ,
"skipUrlSync" : false ,
"type" : "datasource"
} ,
{
"current" : {
"selected" : true ,
2023-09-05 12:51:54 +00:00
"text" : "pod" ,
"value" : "pod"
2023-02-07 20:34:08 +00:00
} ,
"hide" : 0 ,
"includeAll" : false ,
"multi" : false ,
"name" : "aggregation" ,
"options" : [
{
"selected" : false ,
"text" : "cluster_id" ,
"value" : "cluster_id"
} ,
{
2023-09-05 12:51:54 +00:00
"selected" : false ,
2023-02-07 20:34:08 +00:00
"text" : "namespace" ,
"value" : "namespace"
} ,
{
2023-09-05 12:51:54 +00:00
"selected" : true ,
"text" : "pod" ,
"value" : "pod"
2023-02-07 20:34:08 +00:00
}
] ,
2023-09-05 12:51:54 +00:00
"query" : "cluster_id, namespace, pod" ,
2023-02-07 20:34:08 +00:00
"queryValue" : "" ,
"skipUrlSync" : false ,
"type" : "custom"
} ,
{
"current" : {
"selected" : false ,
"text" : "All" ,
"value" : "$__all"
} ,
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"definition" : "label_values(cluster_id)" ,
"hide" : 0 ,
"includeAll" : true ,
"multi" : false ,
"name" : "cluster" ,
"options" : [ ] ,
"query" : {
"query" : "label_values(cluster_id)" ,
"refId" : "StandardVariableQuery"
} ,
"refresh" : 1 ,
"regex" : "" ,
"skipUrlSync" : false ,
"sort" : 5 ,
"type" : "query"
} ,
{
"current" : {
"selected" : false ,
2023-09-05 12:51:54 +00:00
"text" : "kubecost" ,
"value" : "kubecost"
2023-02-07 20:34:08 +00:00
} ,
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"definition" : "label_values(kube_namespace_labels{cluster_id=~\"$cluster\"}, namespace) " ,
"hide" : 0 ,
"includeAll" : true ,
"multi" : false ,
"name" : "namespace" ,
"options" : [ ] ,
"query" : {
"query" : "label_values(kube_namespace_labels{cluster_id=~\"$cluster\"}, namespace) " ,
"refId" : "StandardVariableQuery"
} ,
"refresh" : 2 ,
"regex" : "" ,
"skipUrlSync" : false ,
"sort" : 5 ,
"type" : "query"
} ,
{
"current" : {
"selected" : false ,
"text" : "All" ,
"value" : "$__all"
} ,
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"definition" : "label_values(kube_pod_labels{cluster_id=~\"$cluster\",namespace=~\"$namespace\"}, pod) " ,
"hide" : 0 ,
"includeAll" : true ,
"multi" : false ,
"name" : "pod" ,
"options" : [ ] ,
"query" : {
"query" : "label_values(kube_pod_labels{cluster_id=~\"$cluster\",namespace=~\"$namespace\"}, pod) " ,
"refId" : "StandardVariableQuery"
} ,
"refresh" : 2 ,
"regex" : "" ,
"skipUrlSync" : false ,
"sort" : 0 ,
"type" : "query"
} ,
{
"datasource" : {
"type" : "prometheus" ,
"uid" : "${datasource}"
} ,
"filters" : [ ] ,
"hide" : 0 ,
"name" : "filter" ,
"skipUrlSync" : false ,
"type" : "adhoc"
}
]
} ,
"time" : {
"from" : "now-7d" ,
"to" : "now"
} ,
"timepicker" : { } ,
"timezone" : "" ,
"title" : "Kubecost networkCosts Metrics" ,
"uid" : "kubecost-networkCosts-metrics" ,
2023-09-05 12:51:54 +00:00
"version" : 8 ,
2023-02-07 20:34:08 +00:00
"weekStart" : ""
}