Categorygithub.com/ofesseler/gluster_exporter
repositorypackage
0.2.7
Repository: https://github.com/ofesseler/gluster_exporter.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# README

Build Status CircleCI

gluster_exporter

Gluster exporter for Prometheus

Installation

go get github.com/ofesseler/gluster_exporter
./gluster_exporter

Usage of gluster_exporter

Help is displayed with -h.

OptionDefaultDescription
-help-Displays usage.
-gluster_executable_path/usr/sbin/glusterPath to gluster executable.
-listen-address:9189The address to listen on for HTTP requests.
-log.formatlogger:stderrSet the log target and format. Example: "logger:syslog?appname=bob&local=7" or "logger:stdout?json=true"
-log.levelinfoOnly log messages with the given severity or above. Valid levels: [debug, info, warn, error, fatal]
-metrics-path/metricsURL Endpoint for metrics
-profilefalseWhen profiling reports in gluster are enabled, set ' -profile true' to get more metrics
-version-Prints version information
-volumes_allComma separated volume names: vol1,vol2,vol3. Default is '_all' to scrape all metrics

Make

build: Go build
docker: build and run in docker container

build: runs go build for gluster_exporter

docker: runs docker build and copys new builded gluster_exporter

Relevant Gluster Metrics

Commands within the exporter are executed with --xml.

Command: gluster volume info

Nametypeimpl. state
OpErrnoGaugeimplemented
opRetGaugeimplemented
StatusGaugeimplemented
BrickCountGaugeimplemented
Volumes.CountGaugeimplemented
Volume.StatusGaugeimplemented

Command: gluster peer status

Nametypeimpl. state
peerStatus.peer.stateGaugepending
peerStatus.peer.connectedGaugeimplemented

Command: gluster volume list

with gluster volume info this is obsolete

Nametypeimpl. state
volList.countGaugepending
volList.volumestringpending

Command: gluster volume profile gv_test info cumulative

Nametypeimpl. state
volProfile.profileOpGaugepending
volProfile.brickCountGaugepending
volProfile.cumulativeStatus.durationCountimplemented
volProfile.cumulativeStatus.totalReadCountimplemented
volProfile.cumulativeStatus.totalWriteCountimplemented
volProfile.cumulativeStats.fopStats.fop.NameWRITE, STATFS, FLUSH, OPENDIR, CREATE, LOOKUP, READDIR, FINODELK, ENTRYLK, FXATTROPpending
volProfile.cumulativeStats.fopStats.fop.hitscountimplemented
volProfile.cumulativeStats.fopStats.fop.avgLatencyGaugeimplemented
volProfile.cumulativeStats.fopStats.fop.minLatencyGaugeimplemented
volProfile.cumulativeStats.fopStats.fop.maxLatencyGaugeimplemented

Command gluster volume status all detail

NametypeLabelsimpl. state
volStatus.volumes.volume[].node[].sizeFreeGaugehostname, path, volumeimplemented
volStatus.volumes.volume[].node[].sizeTotalGaugehostname, path, volumeimplemented

Metrics in prometheus

NameDescritpion
upWas the last query of Gluster successful.
volumes_countHow many volumes were up at the last query.
volume_statusStatus code of requested volume.
node_size_free_bytesFree bytes reported for each node on each instance. Labels are to distinguish origins
node_size_total_bytesTotal bytes reported for each node on each instance. Labels are to distinguish origins
brick_countNumber of bricks at last query.
brick_durationTime running volume brick.
brick_data_readTotal amount of data read by brick.
brick_data_writtenTotal amount of data written by brick.
brick_fop_hitsTotal amount of file operation hits.
brick_fop_latency_avgAverage fileoperations latency over total uptime
brick_fop_latency_minMinimum fileoperations latency over total uptime
brick_fop_latency_maxMaximum fileoperations latency over total uptime
peers_connectedIs peer connected to gluster cluster.
heal_info_files_countFile count of files out of sync, when calling 'gluster v heal VOLNAME info
volume_writeableWrites and deletes file in Volume and checks if it is writeable
mount_successfulChecks if mountpoint exists, returns a bool value 0 or 1

Troubleshooting

If the following message appears while trying to get some information out of your gluster. Increase scrape interval in prometheus.yml to at least 30s.

Another transaction is in progress for gv_cluster. Please try again after sometime

Similar Projects

glusterfs exporter for prometheus written in rust.