Skip to main content

GitHub license GitHub tag (latest SemVer) PyPI - Version PyPI - Downloads

kea-exporter

Prometheus Exporter for the ISC Kea DHCP Server.

From v0.4.0 on Kea >=1.3.0 is required, as the configuration, specifically subnet information, will be read from the control socket.

Installation

Package versions via repology.org

The latest stable version can always be installed from PyPi:

$ pip install kea-exporter

and upgraded with:

$ pip install --upgrade kea-exporter

Docker

A docker image is available and can be configured with environment variables see usage section

$ docker pull ghcr.io/mweinelt/kea-exporter

Features

  • DHCP4 & DHCP6 Metrics (tested against Kea 3.2.0)

  • Configuration and statistics via control socket or http api

Currently not working:

  • Automatic config reload (through inotify)

Known Limitations

The following features are not supported yet, help is welcome.

  • Shared Networks

  • Custom Subnet Identifiers

Usage

Pass one or multiple Unix Domain Socket path or HTTP Control-Agent URLs to the kea-exporter executable. All other options are optional.

Usage: python -m kea_exporter [OPTIONS] TARGETS...

Options:
  -a, --address TEXT      Address that the exporter binds to.
  -p, --port INTEGER      Port that the exporter binds to.
  -i, --interval INTEGER  Minimal interval between two queries to Kea in
                          seconds.
  --client-cert PATH      Path to client certificate used to in HTTP requests
  --client-key PATH       Path to client key used in HTTP requests
  --version               Show the version and exit.
  --help                  Show this message and exit.

You can also configure the exporter using environment variables:

export ADDRESS="0.0.0.0"
export PORT="9547"
export INTERVAL="7.5"
export TARGETS="http://router.example.com:8000"
export CLIENT_CERT="/etc/kea-exporter/client.crt"
export CLIENT_KEY="/etc/kea-exporter/client.key"

Configure Control Socket

The exporter uses Kea’s control socket to request both configuration and statistics. Consult the documentation on how to set up the control socket:

HTTPS

If you need to validate a self-signed certificate on a Kea instance, you can set REQUESTS_CA_BUNDLE environment variable to a bundle CA path.

Permissions

Kea Exporter needs to be able to read and write on the socket, hence it’s permissions might need to be modified accordingly.

Grafana-Dashboard

A dashboard for this exporter is available at https://grafana.com/grafana/dashboards/12688.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kea_exporter-0.7.1.tar.gz (9.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kea_exporter-0.7.1-py3-none-any.whl (10.3 kB view details)

Uploaded Python 3

File details

Details for the file kea_exporter-0.7.1.tar.gz.

File metadata

  • Download URL: kea_exporter-0.7.1.tar.gz
  • Upload date:
  • Size: 9.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: pdm/2.28.0 CPython/3.12.3 Linux/6.17.0-1018-azure

File hashes

Hashes for kea_exporter-0.7.1.tar.gz
Algorithm Hash digest
SHA256 6799fbeafcd92e744eb46288a92005fa0be3ac4d3ecc95de7335c2c4520711cc
MD5 9f24e02ce09a8b5c6465f38980d8b3f4
BLAKE2b-256 02ae0801dac90edf246ab5fb597e85ee1d6c905a7c4d07021d6b06103dfa220e

See more details on using hashes here.

File details

Details for the file kea_exporter-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: kea_exporter-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 10.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: pdm/2.28.0 CPython/3.12.3 Linux/6.17.0-1018-azure

File hashes

Hashes for kea_exporter-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 aa2b02a805aea5c61a608450752d99887f06c72d1146f723fb9ba7a1a1e82216
MD5 197ddd6cecf1b820797952c7ab981779
BLAKE2b-256 7a03a13995357f4e33c77fcadebdae43f3509ed17db5af89ef6ef6ca794e87ae

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.7.1 This release

2 files

0.7.0

2 files

0.6.2

2 files

0.6.1

2 files

0.6.0

2 files

0.5.1

2 files

0.5.0

2 files

0.4.4

2 files

0.4.2

2 files

0.4.1

2 files

0.4.0

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page