Datadog

From Federal Burro of Information
Jump to navigationJump to search

Lessons Tip s and tricks.

Graphs snippets

CPU by container:

{
  "viz": "heatmap",
  "requests": [
    {
      "q": "avg:kubernetes.cpu.usage.total{kube_namespace:kube-system,env:prod-blue} by {container_name}",
      "type": null,
      "style": {
        "palette": "dog_classic",
        "type": "solid",
        "width": "normal"
      },
      "conditional_formats": []
    }
  ],
  "autoscale": true
}

coredns: memory usage / request / limit

{
  "viz": "timeseries",
  "requests": [
    {
      "q": "avg:kubernetes.memory.usage{kube_deployment:coredns,$kubernetescluster}",
      "type": "line",
      "style": {
        "palette": "dog_classic",
        "type": "solid",
        "width": "normal"
      },
      "conditional_formats": []
    },
    {
      "q": "avg:kubernetes.memory.requests{kube_deployment:coredns,$kubernetescluster}",
      "type": "line",
      "style": {
        "palette": "cool",
        "type": "dotted",
        "width": "normal"
      }
    },
    {
      "q": "avg:kubernetes.memory.limits{kube_deployment:coredns,$kubernetescluster}",
      "type": "line",
      "style": {
        "palette": "warm",
        "type": "dashed",
        "width": "normal"
      }
    }
  ],
  "autoscale": true
}