Skip to content

A storage metrics collector from IBM SVC equipments whose inject them into a InfluxDB v2.x database.

License

Notifications You must be signed in to change notification settings

R-Studio/svc2influxdb2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SVC 2 InfluxDB v2.x

A simple storage metrics collector (written in Python) from IBM SVC equipments whose inject them into a InfluxDB v2.x database. Works with all IBM kind of hardware running SVC (FlashSystem V9000, V840, ...)

This is a fork of the project "svc2influxdb" from @jbrt, but it is for InfluxDB v2.x. @jbrt, thanks for your work!

Requirements

This script use python 3 and modules like 'paramiko', 'requests' and 'influxdb-client'. You can install them by using this command line: $ pip install -r requirements.txt

Usage

$ svc2influxdb2.py your_config.file [--fixed]

The only required argument is the configuration file. The --fixed option can be used to force the script to use the same timestamp for the metrics collect from your equipments. It can be helpful to "synchronize" all the metrics collected during a same batch to facilitate the visualization (with Grafana for example). The capacity values shown in the measurements are in bytes (think to adjust your data type in Grafana if you use it).

Configuration

The configuration file use a .ini syntax.

Declare your InfluxDB database

[INFLUXDB]
    address = localhost
    organization = youruser
    token = yourpassword
    database = svc2influxdb

The INFLUXDB section let you describe the location of your database. The address field is required (can be a name or an IP address and the port).

Add IBM SVC informations

[YOUR_SVC_NAME]
    address = localhost
    username = your_user
    password = your_password

    tag_name1 = value1
    tag_name2 = value2

You can add any SVC sections you need. The script will be collect the metrics in a sequential mode. A SVC section use the name of your SVC equipment (a short name or a nickname why not). The fields address, username and password are required. It's the same informations you use for a SSH connection. You can also add tags if you need it. These tags are used to described some informations to enrich your time series. For example you can specify if this SVC is used in a production environment or it's location. Example:

    datacenter = Paris
    room = AB3

The key/value pair doesn't matter. The informations can be used in your InfluxQL requests.

InfluxDB results

The names of the measurements are the same labels shown while you using CLI commands like 'lsvdisk' or 'lsmdiskgrp' (prefixed by 'pool_' or 'volume_' ). Please refer to the IBM online help to get the exact signification of all of them. List of the measurements:

List of measurements

Example of data visualization with Grafana

Example of visualization with Grafana

TODO

Pull requests are welcome ! 😃

  1. Collect not only the storage metrics but also performance metrics

Miscellaneous

The only commands send to your IBM SVC by this software are :

  • lsmdiskgrp
  • lsmdiskgrp <MDISK_ID>
  • lsvdisk
  • lsvdisk <VDISK_ID>

License

This source code is under GNU GPL3 license.

About

A storage metrics collector from IBM SVC equipments whose inject them into a InfluxDB v2.x database.

Topics

Resources

License

Stars

Watchers

Forks

Languages