Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gandi/xenlight_exporter
Prometheus exporter for Xen using xenlight library
https://github.com/gandi/xenlight_exporter
prometheus-exporter xen
Last synced: about 2 months ago
JSON representation
Prometheus exporter for Xen using xenlight library
- Host: GitHub
- URL: https://github.com/gandi/xenlight_exporter
- Owner: Gandi
- License: apache-2.0
- Created: 2019-07-01T08:03:12.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-06-23T14:26:36.000Z (over 3 years ago)
- Last Synced: 2024-06-19T06:55:58.552Z (7 months ago)
- Topics: prometheus-exporter, xen
- Language: Go
- Size: 29.3 KB
- Stars: 5
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Xenlight Exporter
Prometheus exporter for [xen](https://xenproject.org/) using `libxl` go bindings.## Installation
You can build the latest version using Go v1.11+ via `go get`:
```
go get -u github.com/Gandi/xenlight_exporter
```You need `xen` headers as well as `yajl` headers to be able to compile xenlight go
bindings## Dockerfile
You can build the binary on an arbitrary machine using the dockerfile.
```
docker build -t xenlight-exporter .
```To build it for a xen version other than 4.14 you have to replace the dnf package in the dockerfile and update the `go.mod` file.
```
go get xenbits.xenproject.org/git-http/xen.git/tools/golang/[email protected]
```## Usage
```
usage: xenlight_exporter []Flags:
-h, --help Show context-sensitive help (also try --help-long and --help-man).
--collector.domain.show-vcpus-details
Enable the collection of per-vcpu time
--collector.domain Enable the domain collector (default: enabled).
--collector.physical Enable the physical collector (default: enabled).
--collector.version Enable the version collector (default: enabled).
--web.listen-address=":9603"
Address on which to expose metrics and web interface.
--web.telemetry-path="/metrics"
Path under which to expose metrics.
--log.level="info" Only log messages with the given severity or above. Valid levels: [debug, info, warn, error, fatal]
--log.format="logger:stderr"
Set the log target and format. Example: "logger:syslog?appname=bob&local=7" or "logger:stdout?json=true"
--version Show application version.
```## Notes about golang bindings of `libxl`
The Go bindings are expected to be imported (according to Xen makefiles) using
the following import path: `golang.xenproject.org/xenlight`. However the domain
`golang.xenproject.org` doesn't exists (thus not allowing the use of Go modules)
so I chose to import the bindings from their official repository.Would the situation evolve and the Xen project provide an universally usable import path,
I will reconsider this choice and switch to its official import path.