Chapter 13. Monitoring Red Hat Gluster Storage using Nagios

Red Hat Gluster Storage Console provides monitoring of Red Hat Gluster Storage trusted storage pool by building on the Nagios platform. You can view the physical and logical resource utilization and status (CPU, Memory, Disk, Network, Swap, Cluster, Volume, Brick) in Trends tab of Red Hat Gluster Storage Console. Nagios is installed and enabled in Red Hat Gluster Storage Console Server by default to monitor Red Hat Gluster Storage nodes. To monitor using Nagios, add hosts to Red Hat Gluster Storage Console and configure Nagios using auto-discovery. For more information about adding hosts, see Section 6.2.1, “Adding Hosts”. This chapter describes the procedures for deploying Nagios on Red Hat Gluster Storage Console node
For more information on Nagios, see Nagios Documentation.
For more information on Changing Nagios Password and Creating Nagios User, see the corresponding sections in Red Hat Gluster Storage Administration Guide.
The following diagram illustrates deployment of Nagios on Red Hat Gluster Storage Console Server.
Nagios deployed on Red Hat Gluster Storage Console Server

Figure 13.1. Nagios deployed on Red Hat Gluster Storage Console Server

13.1. Configuring Nagios

Auto-Discovery is a python script which automatically discovers all the nodes and volumes in the cluster. It also creates Nagios configuration to monitor them. By default, it runs once in 24 hours to synchronize the Nagios configuration from Red Hat Gluster Storage Trusted Storage Pool configuration.
For more information on Nagios Configuration files, see Section D.1, “Nagios Configuration Files”

Note

Before configuring Nagios using configure-gluster-nagios command, ensure that all the Red Hat Gluster Storage nodes are configured.
  1. Execute configure-gluster-nagios command manually only the first time with cluster name and host address on the Nagios server using the following command:
     # configure-gluster-nagios -c cluster-name -H HostName-or-IP-address
    For -c, provide a cluster name (a logical name for the cluster) and for -H, provide the host name or ip address of a node in the Red Hat Gluster Storage trusted storage pool.
  2. Perform the steps given below when configure-gluster-nagios command runs:
    1. Confirm the configuration when prompted.
    2. Enter the current Nagios server host name or IP address to be configured all the nodes.
    3. Confirm restarting Nagios server when prompted.
      # configure-gluster-nagios -c demo-cluster -H HostName-or-IP-address
      Cluster configurations changed
      Changes :
      Hostgroup demo-cluster - ADD
      Host demo-cluster - ADD
       Service - Volume Utilization - vol-1 -ADD
       Service - Volume Split-Brain - vol-1 -ADD
       Service - Volume Status - vol-1 -ADD
       Service - Volume Utilization - vol-2 -ADD
       Service - Volume Status - vol-2 -ADD
       Service - Cluster Utilization -ADD
       Service - Cluster - Quorum -ADD
       Service - Cluster Auto Config -ADD
      Host Host_Name - ADD
       Service - Brick Utilization - /bricks/vol-1-5 -ADD
       Service - Brick - /bricks/vol-1-5 -ADD
       Service - Brick Utilization - /bricks/vol-1-6 -ADD
       Service - Brick - /bricks/vol-1-6 -ADD
       Service - Brick Utilization - /bricks/vol-2-3 -ADD
       Service - Brick - /bricks/vol-2-3 -ADD
      Are you sure, you want to commit the changes? (Yes, No) [Yes]:
      Enter Nagios server address [Nagios_Server_Address]:
      Cluster configurations synced successfully from host ip-address
      Do you want to restart Nagios to start monitoring newly discovered entities? (Yes, No) [Yes]:
      Nagios re-started successfully
      All the hosts, volumes and bricks are added and displayed.
  3. Login to the Nagios server GUI using the following URL.
    https://NagiosServer-HostName-or-IPaddress/nagios

    Note

    • The default Nagios user name and password is nagiosadmin / nagiosadmin.
    • You can manually update/discover the services by executing the configure-gluster-nagios command or by running Cluster Auto Config service through Nagios Server GUI.
    • If the node with which auto-discovery was performed is down or removed from the cluster, run the configure-gluster-nagios command with a different node address to continue discovering or monitoring the nodes and services.
    • If new nodes or services are added, removed, or if snapshot restore was performed on Red Hat Gluster Storage node, run configure-gluster-nagios command.