-
Type:
Bug
-
Resolution: Won't Fix
-
Priority:
Major - P3
-
None
-
Affects Version/s: 2.5.4
-
Component/s: Networking
-
Environment:Discovered in RHEL 6, but seems to be reproducible in other environments.
-
ALL
-
None
-
3
-
None
-
None
-
None
-
None
-
None
-
None
I found problems with running smpwalk when the mongod is an SNMP master in a replica set with 2 other mongod snamp-subagents. It only retrieves part of the MIB per call:
[root@ip-10-235-22-194 ~]# ps -elf | grep mongod
1 R root 25561 1 0 80 0 - 245094 - 14:46 ? 00:00:10 mongod --snmp-master --port 27017 --fork --dbpath /root/mongodb/data/rs-0/ --logpath /root/mongodb/logs/rs-0/mongod.log --smallfiles --nohttpinterface --replSet rs --oplogSize=50 --nojournal
1 S root 25611 1 0 80 0 - 282945 poll_s 14:46 ? 00:00:12 mongod --snmp-subagent --port 27018 --fork --dbpath /root/mongodb/data/rs-1/ --logpath /root/mongodb/logs/rs-1/mongod.log --smallfiles --nohttpinterface --replSet rs --oplogSize=50
1 S root 25659 1 0 80 0 - 236597 poll_s 14:47 ? 00:00:08 mongod --snmp-subagent --port 27019 --fork --dbpath /root/mongodb/data/rs-2/ --logpath /root/mongodb/logs/rs-2/mongod.log --smallfiles --nohttpinterface --replSet rs --oplogSize=50 --nojournal
0 S root 27178 1426 0 80 0 - 25811 pipe_w 15:39 pts/0 00:00:00 grep mongod
[root@ip-10-235-22-194 ~]# snmpwalk -m MONGO-MIB -v 2c -c mongodb localhost:1161 1.3.6.1.4.1.34601
MONGO-MIB::serverName."27017" = STRING: "ip-10-235-22-194:27017"
MONGO-MIB::sysUpTime."27017" = Timeticks: (308167) 0:51:21.67
MONGO-MIB::globalOpInsert."27017" = Counter32: 201
MONGO-MIB::globalOpQuery."27017" = Counter32: 501
MONGO-MIB::globalOpUpdate."27017" = Counter32: 110
MONGO-MIB::globalOpDelete."27017" = Counter32: 100
MONGO-MIB::globalOpGetMore."27017" = Counter32: 1427
MONGO-MIB::globalOpCommand."27017" = Counter32: 3435
MONGO-MIB::replOpInsert."27017" = Counter32: 0
MONGO-MIB::replOpQuery."27017" = Counter32: 0
MONGO-MIB::replOpUpdate."27017" = Counter32: 0
MONGO-MIB::replOpDelete."27017" = Counter32: 0
MONGO-MIB::replOpGetMore."27017" = Counter32: 0
MONGO-MIB::replOpCommand."27017" = Counter32: 0
MONGO-MIB::memoryResident."27017" = INTEGER: 52 MB
MONGO-MIB::memoryVirtual."27017" = INTEGER: 957 MB
...
MONGO-MIB::replSetName."27017" = STRING: "rs"
MONGO-MIB::replSetVersion."27017" = INTEGER: 4
MONGO-MIB::replIsMaster."27017" = INTEGER: 1
MONGO-MIB::replIsSecondary."27017" = INTEGER: 0
MONGO-MIB::replPrimary."27017" = STRING: "ip-10-235-22-194:27017"
MONGO-MIB::replMe."27017" = STRING: "ip-10-235-22-194:27017"
MONGO-MIB::replMe."27017" = No more variables left in this MIB View (It is past the end of the MIB tree)
[root@ip-10-235-22-194 ~]# snmpwalk -m MONGO-MIB -v 2c -c mongodb localhost:1161 1.3.6.1.4.1.34601
MONGO-MIB::serverName."27017" = STRING: "ip-10-235-22-194:27017"
MONGO-MIB::serverName."27018" = STRING: "ip-10-235-22-194:27018"
MONGO-MIB::serverName."27019" = STRING: "ip-10-235-22-194:27019"
MONGO-MIB::sysUpTime."27017" = Timeticks: (313212) 0:52:12.12
MONGO-MIB::sysUpTime."27018" = Timeticks: (309181) 0:51:31.81
MONGO-MIB::sysUpTime."27019" = Timeticks: (307827) 0:51:18.27
MONGO-MIB::globalOpInsert."27017" = Counter32: 201
MONGO-MIB::globalOpInsert."27018" = Counter32: 1
MONGO-MIB::globalOpInsert."27019" = Counter32: 1
...
MONGO-MIB::globalOpCommand."27019" = Counter32: 3199
MONGO-MIB::replOpInsert."27017" = Counter32: 0
MONGO-MIB::replOpInsert."27018" = Counter32: 200
Error in packet.
Reason: (genError) A general failure occured
Failed object: MONGO-MIB::replOpInsert."27018"
[root@ip-10-235-22-194 ~]# snmpwalk -m MONGO-MIB -v 2c -c mongodb localhost:1161 1.3.6.1.4.1.34601
MONGO-MIB::serverName."27017" = STRING: "ip-10-235-22-194:27017"
MONGO-MIB::serverName."27018" = STRING: "ip-10-235-22-194:27018"
MONGO-MIB::serverName."27019" = STRING: "ip-10-235-22-194:27019"
MONGO-MIB::sysUpTime."27017" = Timeticks: (315942) 0:52:39.42
MONGO-MIB::sysUpTime."27018" = Timeticks: (311911) 0:51:59.11
MONGO-MIB::sysUpTime."27019" = Timeticks: (310557) 0:51:45.57
MONGO-MIB::globalOpInsert."27017" = Counter32: 201
...
MONGO-MIB::flushLastMs."27017" = INTEGER: 0
MONGO-MIB::flushLastMs."27018" = INTEGER: 0
MONGO-MIB::flushLastMs."27019" = INTEGER: 0
MONGO-MIB::flushLastDateTime."27017" = STRING: "2013-12-27,20:38:11.0,+0:0"
MONGO-MIB::flushLastDateTime."27018" = STRING: "2013-12-27,20:37:51.0,+0:0"
MONGO-MIB::flushLastDateTime."27019" = STRING: "2013-12-27,20:38:05.0,+0:0"
MONGO-MIB::cursorTotalOpen."27017" = INTEGER: 2
Error in packet.
Reason: (genError) A general failure occured
Failed object: MONGO-MIB::cursorTotalOpen."27017"