使用 munin 监控 mongodb

首先启用Mongodb的httpinterface

修改 mongodb.conf

注释此行

#nohttpinterface = true

httpinterface 端口为 mongodb端口+1000

如mongodb默认端口为 27018  则httpinterface 为 28018

需要重启mongodb

下载插件

#wget http://github.com/erh/mongo-munin/tarball/master

下载下来文件名是 master 重命名之后再解压

#tar xvf erh-mongo-munin-*tar.gz
#cp erh-mongo-munin-*/mongo_* /etc/munin/plugins/
#munin-node restart

在munin服务节点上

#sudo -u munin /usr/share/munin/munin-update

$ cd /etc/munin/plugins/
$ munin-run mongo_ops
getmore.value 0
insert.value 46235
update.value 44290
command.value 13918
query.value 444044
delete.value 0

参考 http://docs.mongodb.org/ecosystem/tools/munin/

, 相关的文章:

暂无评论

写评论