prometheus-pve-exporter icon indicating copy to clipboard operation
prometheus-pve-exporter copied to clipboard

Collect and Export Notes of LXC and VMs from Proxmox

Open federicociro opened this issue 4 months ago • 4 comments

I would like to request a feature that allows the prometheus-pve-exporter to collect and export the "Notes" field of LXC containers and VMs from Proxmox VE.

Use Case

In Proxmox VE, each LXC container and virtual machine has a "Notes" field that users can utilize for documenting specific information about the instance, such as the purpose, configuration details, or operational notes. Exporting this information to Prometheus would be beneficial for maintaining an overview of various VMs/containers and their intended use.

Feature Request

  • Extend the current exporter to fetch the "Notes" field of each VM and LXC container.
  • Export this information as part of the Prometheus metrics, potentially as a label or a separate metric.
  • This feature would help in monitoring and correlating notes with other VM/container metrics in dashboards such as Grafana.

Example of Expected Output

For each LXC or VM, a metric like this could be exported:

pve_lxc_notes{id="101", name="container01"} "Backup container for database"
pve_vm_notes{id="200", name="vm02"} "Production web server"

This way, the notes could be exposed alongside other VM or LXC-related metrics.

Additional Notes

  • It would be helpful if this feature respects any privacy/security concerns around the notes field, with options to enable/disable the export of this information.
  • Support for fetching notes for both LXC containers and QEMU virtual machines is requested.

federicociro avatar Oct 06 '24 08:10 federicociro