Prometheus Libvirt Exporter

juju deploy prometheus-libvirt-exporter
Show information
You will need Juju 2.9 to be able to run this command. Learn how to upgrade to Juju 2.9.
Channel Version Base
latest/stable 5
16.04 18.04 20.04
latest/candidate 5
16.04 18.04 20.04


16.04 18.04 20.04


Prometheus libvirt exporter Read more

Relevant links

Discuss this charm

Share your thoughts on this charm with the community on discourse.

Join the discussion

While many Reactive Framework charms work on machines today, it’s recommended to create new charms with the Operator Framework. Learn more about the history of charms.

Juju prometheus libvirt exporter charm

This charm provides the Prometheus libvirt exporter


This directory needs to be create in the charm path prior to testing

mkdir -p report/lint


A typical deployment with nova and libvirt is as follows:

The metrics will be at http://nova-compute:9177

juju deploy nova-compute 
juju deploy prometheus-libvirt-exporter
juju add-relation nova-compute prometheus-libvirt-exporter

To avail of the metrics in grafana the following steps can be used

juju deploy grafana
juju deploy prometheus2
juju add-relation prometheus-libvirt-exporter:scrape prometheus2:target
juju add-relation prometheus-libvirt-exporter:dashboards grafana:dashboards

To setup reporting with nagios

juju deploy nrpe
juju add-relation nova-compute nrpe
juju add-relation prometheus-libvirt-exporter:nrpe-external-master nrpe:nrpe-external-master

Functional tests

Juju should be installed and bootstrapped on the system to run functional tests.

    export HTTPS_PROXY=http://<your_proxy
    export NO_PROXY=,localhost,<juju_controller_ips> 
    export MODEL_SETTINGS=<semicolon-separated list of "juju model-config" settings>
    make test

NOTE: If you are behind a proxy, be sure to export a MODEL_SETTINGS variable as described above. Note that you will need to use the juju-http-proxy, juju-https-proxy, juju-no-proxy and similar settings. Also you will need to export HTTPS_PROXY used in the test and export NO_PROXY that should include ips of controller subnet and model subnet.

Change or update dashboards

# The exporter is distributed with a standard dashboard
# To provide your own dashboards, create a zip file and attach it as a resource 
zip libvirt-simple.json libvirtadvanced.json
juju attach-resource prometheus-libvirt-exporter dashboards=./

Contact Information