containers / prometheus-podman-exporter

Prometheus exporter for podman environments exposing containers, pods, images, volumes and networks information.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Exporter does not list all rootless containers running under different users

cmarasescu opened this issue · comments

I have a RHEL8 servers with podman and I have several rootless containers running under different users (this is a security requirement in my env).

The podman-exporter is currently running in a container under root account and it can only list metrics related to the cotnainers running under root.

Is there a way to scape the metrics from all rootless containers running under different users?

Hi @cmarasescu
At the moment its not possible to get the metrics from all rootless containers thats are running under different users via one exporter instance. The only way at the moment is to run multiple instances of exporter for each user.

I will investigate more to see if we can have this feature as well.

A friendly reminder that this issue had no activity for 30 days.

A friendly reminder that this issue had no activity for 30 days.

A friendly reminder that this issue had no activity for 30 days.

Hello @navidys ,

Thanks for your reply.
For the moment, I've used an workaround:

  • I've deployed the podman-system-service to run under each user that is running podman containers - this way we can use the podman API under each user to get info about the containers running under each user
  • I've created my own prometheus exporter that is calling each podman-system-service to get details about the pods running on my system.

Note: Here I've noticed a limitation in the podman API, I cannot get CPU / RAM info for the rootless containers as long as my system is not running yet cgroup v2

Hi @cmarasescu

Good to hear that.

Regards