db.serverCmdLineOpts()
db.serverCmdLineOpts() will displays the arguments and configuration options used to start the mongoddb, (configuration details inside /etc/mongod.conf )
output
> db.serverCmdLineOpts() { "argv" : [ "/usr/bin/mongod", "-f", "/etc/mongod.conf" ], "parsed" : { "config" : "/etc/mongod.conf", "net" : { "port" : 27017 }, "processManagement" : { "fork" : true, "pidFilePath" : "/var/run/mongodb/mongod.pid" }, "storage" : { "dbPath" : "/var/lib/mongo", "journal" : { "enabled" : true } }, "systemLog" : { "destination" : "file", "logAppend" : true, "path" : "/var/log/mongodb/mongod.log" } }, "ok" : 1 }