diff --git a/source/includes/steps-control-access-to-mongodb-windows-with-kerberos-authentication.yaml b/source/includes/steps-control-access-to-mongodb-windows-with-kerberos-authentication.yaml index d78f0a75478..3f3318ec1da 100644 --- a/source/includes/steps-control-access-to-mongodb-windows-with-kerberos-authentication.yaml +++ b/source/includes/steps-control-access-to-mongodb-windows-with-kerberos-authentication.yaml @@ -85,10 +85,13 @@ action: - pre: You can connect and authenticate from the command line. language: sh code: | - mongo.exe --authenticationMechanism=GSSAPI --authenticationDatabase='$external' \ - --username reportingapp@EXAMPLE.NET + mongo.exe --host hostname.example.net --authenticationMechanism=GSSAPI --authenticationDatabase='$external' --username reportingapp@EXAMPLE.NET + post: | + If you are connecting to a system whose hostname does not + match the Kerberos name, use :option:`--gssapiHostName ` + to specify the Kerberos FQDN that it responds to. - pre: | - Or, alternatively, you can first connect :program:`mongo.exe` to the + Alternatively, you can first connect :program:`mongo.exe` to the :program:`mongod.exe`, and then from the :program:`mongo.exe` shell, use the :method:`db.auth()` method to authenticate in the ``$external`` database. diff --git a/source/includes/steps-control-access-to-mongodb-with-kerberos-authentication.yaml b/source/includes/steps-control-access-to-mongodb-with-kerberos-authentication.yaml index 90781b68d16..2ba9548cc60 100644 --- a/source/includes/steps-control-access-to-mongodb-with-kerberos-authentication.yaml +++ b/source/includes/steps-control-access-to-mongodb-with-kerberos-authentication.yaml @@ -100,10 +100,13 @@ action: - pre: You can connect and authenticate from the command line. language: sh code: | - mongo --authenticationMechanism=GSSAPI --authenticationDatabase='$external' \ - --username application/reporting@EXAMPLE.NET + mongo --host hostname.example.net --authenticationMechanism=GSSAPI --authenticationDatabase='$external' --username application/reporting@EXAMPLE.NET + post: | + If you are connecting to a system whose hostname does not + match the Kerberos name, use :option:`--gssapiHostName ` + to specify the Kerberos FQDN that it responds to. - pre: | - Or, alternatively, you can first connect :program:`mongo` to the + Alternatively, you can first connect :program:`mongo` to the :program:`mongod`, and then from the :program:`mongo` shell, use the :method:`db.auth()` method to authenticate in the ``$external`` database.