Export Metrics to Prometheus¶
The console serves its metrics at /api/metrics in Prometheus format, so
Prometheus, Grafana Agent or anything else that reads that format can scrape
them into an existing monitoring stack. The metrics cover:
- hosts and VMs (CPU, memory, disk, network),
- datastores,
- alarms,
- tasks,
- notification deliveries.
A host's disk and network figures are the totals of that host's VMs.
Set it up¶
- Settings → Metrics Export → Generate token (Super Admins only).
- Copy the token now. It's stored only as a hash and isn't shown again.
-
The card shows a ready-made scrape job for your console's address. Add it to
prometheus.yml: -
Reload Prometheus and check the target is UP.
The scrape token can read metrics and nothing else. Super Admins can also scrape with their own sign-in or API key, but a dedicated token is the better choice: it can't do anything else if it leaks.
Replace or revoke the token¶
- Generate token again replaces the current one. Prometheus gets a
401until you give it the new token. - Revoke removes it. Prometheus gets a
401until you generate a new one.
The card shows who generated the current token and when. Generating and revoking are recorded in the audit log.
Certificates
If the console uses its own self-signed certificate, add the CA to
Prometheus with tls_config: { ca_file: … }. Avoid
insecure_skip_verify.