diff --git a/collectors/0/mongo3.py b/collectors/0/mongo3.py index 41f490d4..7694d575 100755 --- a/collectors/0/mongo3.py +++ b/collectors/0/mongo3.py @@ -217,18 +217,20 @@ def runDbStats(c): continue print 'mongo.db.%s %d %s db=%s' % (metric, ts, cur, db_name) - raw_metrics = res['raw'] - for key, value in raw_metrics.items(): + + # raw_metrics = res['raw'] + # for key, value in raw_metrics.items(): + for key, value in res.items(): replica_name = key.split('/', 1)[0] - replica_desc = key.split('/', 1)[1] + # replica_desc = key.split('/', 1)[1] for metric in MONGOS_RAW_METRICS: cur = value - try: - for m in metric.split('.'): - cur = cur[m] - except KeyError: - continue + # try: + # for m in metric.split('.'): + # cur = cur[m] + # except KeyError: + # continue print 'mongo.rs.%s %d %s replica=%s db=%s' % (metric, ts, cur, replica_name, db_name) def runReplSetGetStatus(c): diff --git a/collectors/etc/mongodb3_conf.py b/collectors/etc/mongodb3_conf.py index 66ffecd9..8cdb769d 100644 --- a/collectors/etc/mongodb3_conf.py +++ b/collectors/etc/mongodb3_conf.py @@ -15,7 +15,7 @@ def get_settings(): return { - "db": "db1,db2", + "db": "argus-alert,argus-statistics,argus-users,argus-web", "config": "192.168.0.10:27017,192.168.0.11:27017", "mongos": "192.168.0.13:27017", "replica": "192.168.0.14:27017",