KSMG provides information over SNMP separately for each node of the cluster. An external monitoring system (hereinafter also referred to as the monitoring system) is used for storing, aggregating and analyzing this information.
Configuring the external monitoring system to use SNMP
To configure the external monitoring system:
Use the credentials of the user account that you created when configuring the snmpd service on the KSMG cluster node.
Specify user credentials in the settings of the snmpd service on the cluster nodes (the 'trapsess' directive).
Configuring the snmptrapd service to receive SNMP traps
Some monitoring systems (for example, Zabbix, LibreNMS) use the snmptrapd service from the operating system as the agent for receiving SNMP traps. The snmptrapd service saves information about received events to a log file, which is then read by the monitoring system.
You must configure the snmptrapd service on the computer on which the monitoring service is installed.
To configure the snmptrapd service:
If the snmptrapd service is not installed, install the appropriate packages:
yum install net-snmp net-snmp-utils
apt install snmp snmptrapd
To install the basic MIB files:
yum install net-snmp-libs
apt install snmp-mibs-downloader
mibdirs +/usr/share/snmp/mibs/ksmg
mibs all
If you chose to create a new configuration file, make sure that only the superuser has access to it. If necessary, configure permissions:
chown root:root /etc/snmp/snmptrapd.conf
chmod 600 /etc/snmp/snmptrapd.conf
snmpTrapdAddr udp:162
For security purposes, we recommend creating a separate user account for receiving SNMP traps from each node of the KSMG cluster.
createUser <user name> <authentication algorithm> "<authentication password>" <encryption algorithm> "<encryption password>"
authUser log <user name> priv
Example of configuration file: snmpTrapdAddr udp:162 createUser TrapUser SHA "TrapAuthSecret" AES "TrapPrivSecret" authUser log TrapUser priv createUser TrapUser2 SHA "TrapAuthSecret2" AES "TrapPrivSecret2" authUser log TrapUser2 priv |
To start the snmptrapd service in debug mode:
snmptrapd -f -Lo
If everything is configured correctly, within 5 to 10 minutes you will receive an SNMP trap with an event about the KSN status in the application:
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (4504) 0:00:45.04
SNMPv2-MIB::snmpTrapOID.0 = OID: KSMG-EVENTS-MIB::ksnConnectionStatusEvent
KSMG-EVENTS-MIB::sourceNode = STRING: mailgw01.example.com
KSMG-EVENTS-MIB::status = STRING: KsnDisabled
To do so, follow the instructions in the documentation of your monitoring system.
The snmpd service is configured.
Page top