MongoDB 查看存储引擎
Posted xibuhaohao
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了MongoDB 查看存储引擎相关的知识,希望对你有一定的参考价值。
需要登录到具体的主/从节点查询,mongos查询不到
db.serverStatus()
其中有这个
"storageEngine" : "name" : "wiredTiger", "supportsCommittedReads" : true, "readOnly" : false, "persistent" : true ,
查看WiredTiger内部缓存到底占用了多少内存的方式是,在mongo shell中之行以下命令
db.runCommand( serverStatus: 1 ).wiredTiger.cache["bytes currently in the cache"]
如果不想重启mongoDB,可以在线修改,如下
db.adminCommand(setParameter: 1, wiredTigerEngineRuntimeConfig: "cache_size=8G")
以上是关于MongoDB 查看存储引擎的主要内容,如果未能解决你的问题,请参考以下文章