Giter Club home page Giter Club logo

prometheus-eaton-ups-exporter's Introduction

Eaton UPS Prometheus Exporter

Description

A Prometheus exporter for Eaton UPSs. Data is collected from the REST API of the web UI of Eaton UPSs and is made available for Prometheus to scrape.

The exporter can monitor multiple UPSs.

Information Exported

  • Input Voltage (V)
  • Input Frequency (Hz)
  • Output Voltage (V)
  • Output Frequency (Hz)
  • Output Current (A)
  • Output Apparent Power (VA)
  • Output Active Power (W)
  • Output Power Factor
  • Output Percent Load (%)
  • Battery Voltage (V)
  • Battery Capacity (%)
  • Battery Remaining Time (s)
  • Battery Health Status (given as the remaining lifetime in years [uncertain, contribute to #19])

Supported Devices:

  • Eaton 5P 1550iR (user guide)
  • Other models may also work if they use the same API

Usage:

UPSs to monitor and their credentials are defined in a config file. See config.json for an example.

./prometheus_eaton_ups_exporter.py [-h] [-w WEB.LISTEN_ADDRESS] -c CONFIG [-k] [-t] [-v] [--login-timeout {range 2 - 10}]


optional arguments:
  -h, --help            show this help message and exit
  -w WEB.LISTEN_ADDRESS, --web.listen-address WEB.LISTEN_ADDRESS
                        Interface and port to listen on, in the format of "ip_address:port".
                        If the IP is omitted, the exporter listens on all interfaces. (default: 0.0.0.0:9795)
  -c CONFIG, --config CONFIG
                        Configuration JSON file containing UPS addresses and login info (default: None)
  -k, --insecure        Allow the exporter to connect to UPSs with self-signed SSL certificates (default: False)
  -t, --threading       Whether to use multi-threading for scraping (faster) (default: False)
  -v, --verbose         Be more verbose (default: False)
  --login-timeout {range 2 - 10}
                        The login timeout for the UPSs in seconds (default: 3)

Defaults:

  • Default host-address is 0.0.0.0
  • Default port is 9795 (see also: Prometheus default port allocations)
  • Login timeout is set to 3 seconds
  • Other request timeouts are set to 2 seconds
  • Static values are described in prometheus_eaton_ups_exporter/scraper_globals.py

Requirements:

Installation:

git clone https://github.com/psyinfra/prometheus-eaton-ups-exporter.git
cd prometheus-eaton-ups-exporter
pip install -r requirements.txt

Testing:

Install requirements with

pip install -r test-requirements.txt

Runt tests with

pytest tests

Test-Requirements:

  • pytest
  • pytest-vcr

prometheus-eaton-ups-exporter's People

Contributors

aqw avatar tobiaskadelka avatar mathisloevenich avatar joeharrison714 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.