How to get CPU, memory metrics for Kubernetes Jobs, CronJobs, BatchJobs and KedaJobs

279 Views Asked by At

Is there a way to get CPU, memory metrics in Prometheus for Kubernetes Jobs, CronJobs, Batch Jobs and KedaJobs.

Currently I can get all this metrics from Prometheus about the time, status, etc. I have been trying to get the CPU metrics using cadvisor but I don't see any CPU and memory metrics for my jobs.

I have been trying by exposing a port and a service for cadvisor to get the metrics but still doesn't work.

There are going to be multiple jobs and I need the CPU and memory metrics from each so I cannot add the manually to the Prometheus config, is there a way to do this.

Any recommendation I can try, Thank you in advance

0

There are 0 best solutions below