如何检查MongoDB的当前配置 [英] How to check the current configuration of MongoDB
本文介绍了如何检查MongoDB的当前配置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我已经找到了不同的配置选项的文档,但是如何检查正在使用的选项在实时系统上使用?
I've found documentation for the different configuration options, but how can I check which options are being used on a live system?
有没有办法查看设置了哪些选项,或者至少使用了哪个配置文件?
Is there a way to see which options were set, or at minimum which configuration file is being used?
推荐答案
找到了答案: https://stackoverflow.com/a /9361047/947305
mongo shell中有一个 getCmdLineOpts 命令.运行以下命令:
There's a getCmdLineOpts command in the mongo shell. Run the following:
db._adminCommand( {getCmdLineOpts: 1})
这篇关于如何检查MongoDB的当前配置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文