I want to enable the features of my Mongodb 3.4 after upgrading. I have sharded cluster enviroment And after I ran the commands:

use admin
db.adminCommand ({setFeatureCompatibilityVersion: "3.4"})

In mongos instance I got the following output:

{"ok": 1}

But when I try to check with it succeeded with command:

db.adminCommand ({getParameter: 1, featureCompatibilityVersion: 1})

I get the following output:

{"ok": 0, "errmsg": "no option found to get"}

And when I check in ops manager I see that the command did not work

  • And db.serverStatus().version command gives you 3.4.x answer?
    – JJussi
    Commented May 9, 2018 at 14:35

1 Answer 1


You probably ran your command

 db.adminCommand ({getParameter: 1, featureCompatibilityVersion: 1})

on a mongos instance. The documentation states in this case:

The operation is undefined on the mongos instances. For a sharded cluster that has access control enabled, to run the command against a member of the shard replica set, you must connect to the member as a shard local user.

When you connect to a mongod instead, the command should work as expected.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.