Este contenido no está disponible en el idioma seleccionado.
9.8. Querying a Pacemaker Cluster with SNMP (Red Hat Enterprise Linux 7.5 and later)
As of Red Hat Enterprise Linux 7.5, you can use the
pcs_snmp_agent daemon to query a Pacemaker cluster for data by means of SNMP. The pcs_snmp_agent daemon is an SNMP agent that connects to the master agent (snmpd) by means of agentx protocol. The pcs_snmp_agent agent does not work as a standalone agent as it only provides data to the master agent.
The following procedure sets up a basic configuration for a system to use SNMP with a Pacemaker cluster. You run this procedure on each node of the cluster from which you will be using SNMP to fetch data for the cluster.
- Install the
pcs-snmppackage on each node of the cluster. This will also install thenet-snmppackage which provides thesnmpdaemon.yum install pcs-snmp
# yum install pcs-snmpCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Add the following line to the
/etc/snmp/snmpd.confconfiguration file to set up thesnmpddaemon asmaster agentx.master agentx
master agentxCopy to Clipboard Copied! Toggle word wrap Toggle overflow - Add the following line to the
/etc/snmp/snmpd.confconfiguration file to enablepcs_snmp_agentin the same SNMP configuration.view systemview included .1.3.6.1.4.1.32723.100
view systemview included .1.3.6.1.4.1.32723.100Copy to Clipboard Copied! Toggle word wrap Toggle overflow - Start the
pcs_snmp_agentservice.systemctl start pcs_snmp_agent.service systemctl enable pcs_snmp_agent.service
# systemctl start pcs_snmp_agent.service # systemctl enable pcs_snmp_agent.serviceCopy to Clipboard Copied! Toggle word wrap Toggle overflow - To check the configuration, display the status of the cluster with the
pcs statusand then try to fetch the data from SNMP to check whether it corresponds to the output. Note that when you use SNMP to fetch data, only primitive resources are provided.The following example shows the output of apcs statuscommand on a running cluster with one failed action.Copy to Clipboard Copied! Toggle word wrap Toggle overflow Copy to Clipboard Copied! Toggle word wrap Toggle overflow