-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: 2.0.6
-
Component/s: Networking
-
None
-
Environment:Ubuntu, CentOS, AMI - running MongoDB 2.06 enterprise (reproducible via both simply extracting the binaries not the packaged install).
Testing with snmpwalk -
-----------------------
$snmpwalk -m MONGO-MIB -v 2c -c mongodb 127.0.0.1:1161 1.3.6.1.4.1.37601 MONGO-MIB::serverName."3001" = STRING: "3001" MONGO-MIB::sysUpTime."3001" = Timeticks: (931) 0:00:09.31 MONGO-MIB::globalOpInsert."3001".0 = Counter32: 0 MONGO-MIB::globalOpQuery."3001".0 = Counter32: 1 MONGO-MIB::globalOpUpdate."3001".0 = Counter32: 0 MONGO-MIB::globalOpDelete."3001".0 = Counter32: 0 MONGO-MIB::globalOpGetMore."3001".0 = Counter32: 0 MONGO-MIB::memoryResident."3001" = INTEGER: 15 MB MONGO-MIB::memoryVirtual."3001" = INTEGER: 661 MB MONGO-MIB::memoryMapped."3001" = INTEGER: 0 MB MONGO-MIB::memoryMapped."3001" = No more variables left in this MIB View (It is past the end of the MIB tree) sysadmin@ubuntu:/data/db/master$ mongo-e --port 3001 MongoDB shell version: 2.0.6 connecting to: 127.0.0.1:3001/test > db.serverStatus() { "host" : "ubuntu:3001",
and using Ubuntu with /etc/mongodb.conf and starting via upstart -
hillickm@dub-10gen-linux-1:/usr/share/snmp/mibs$ snmpwalk -m /usr/share/snmp/mibs/MONGO-MIB.txt -v 2c -c mongodb 127.0.0.1:1161 1.3.6.1.4.1.37601 MONGO-MIB::serverName."27017" = STRING: "27017" MONGO-MIB::sysUpTime."27017" = Timeticks: (70639) 0:11:46.39 MONGO-MIB::globalOpInsert."27017".0 = Counter32: 0 MONGO-MIB::globalOpQuery."27017".0 = Counter32: 1 MONGO-MIB::globalOpUpdate."27017".0 = Counter32: 0 MONGO-MIB::globalOpDelete."27017".0 = Counter32: 0 MONGO-MIB::globalOpGetMore."27017".0 = Counter32: 0 MONGO-MIB::memoryResident."27017" = INTEGER: 18 MB MONGO-MIB::memoryVirtual."27017" = INTEGER: 722 MB MONGO-MIB::memoryMapped."27017" = INTEGER: 0 MB hillickm@dub-10gen-linux-1:/usr/share/snmp/mibs$ mongoe MongoDB shell version: 2.0.6 connecting to: test > db.serverStatus() { "host" : "dub-10gen-linux-1", "version" : "2.0.6", "process" : "mongod",
The serverName value is returning the wrong value (in both instances the port number is returned).