Monitoring GlusterFS

You can monitor the health of your GlusterFS cluster on IBM® Cloud Private cluster monitoring dashboard.

Heketi exports Prometheus-compatible data as an endpoint at /metrics. To enable Prometheus metrics export on Heketi server, set the configuration parameter prometheus.enabled: true while you install the GlusterFS Helm chart.

In GlusterFS Helm chart Version 1.4.0, Heketi communication is encrypted by tls. Hence, Prometheus does not collect the metrics by default. After the GlusterFS chart is installed, you must complete following procedures to enable Prometheus to collect metrics from the Heketi endpoint. You can then view the metrics on the IBM Cloud Private Grafana dashboard.

  1. Install kubectl. For more information, see Installing the Kubernetes CLI (kubectl).

  2. Get the Heketi service IP address.

    kubectl -n kube-system -l glusterfs=heketi-service get service
    

    Following is a sample output.

    NAME                                         TYPE        CLUSTER-IP     EXTERNAL-IP   PORT(S)    AGE
    storage-glusterfs-glusterfs-heketi-service   ClusterIP   10.0.150.224   <none>        8080/TCP   18h
    

    In the sample output, 10.0.150.224 is the Heketi service IP address.

  3. Edit the monitoring-prometheus configmap.

    kubectl edit configmap -n kube-system monitoring-prometheus
    
  4. Add scrap configuration job for the Heketi endpoint by specifying the Heketi service IP address and port number.

    - job_name: heketi
    static_configs:
      - targets:
        - 10.0.150.224:8080
    metrics_path: /metrics
    scheme: https
    tls_config:
      insecure_skip_verify: true