google / cadvisor

Analyzes resource usage and performance characteristics of running containers.
Other
17.1k stars 2.32k forks source link

Why cadvisor collects so many metrics about overlay? #2747

Open Alexbyy opened 3 years ago

Alexbyy commented 3 years ago

version:v0.38.4-pre environment:k8s The args is as follows: image

On just one node, the total number of metrics reaches on 37000.I looked at these metrics carefully and found that half of them started with "containerfs"

My question is why cadvisor collects so many disk metrics about overlay?Is there any approach that can make cadvisor don't collect it? I hope the cadvisor only collects metrics which belongs to the container's disk.such as /dev/vda or /dev/vdb etc. Many Thanks! image

Creatone commented 3 years ago

You can add diskIO to disable-metrics to prevent gathering this metric.

I recommend being familiar with this doc: prometheus.md :v: