Skip to content

Commit 5bc0829

Browse files
Replace mongo options with mongosh
1 parent 9d7d58c commit 5bc0829

26 files changed

+108
-107
lines changed

snooty.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ intersphinx = [ "https://pymongo.readthedocs.io/en/stable/objects.inv",
66
"https://docs.atlas.mongodb.com/objects.inv",
77
"https://docs.mongodb.com/php-library/master/objects.inv",
88
"https://docs.mongodb.com/compass/current/objects.inv",
9-
"https://docs.mongodb.com/database-tools/objects.inv"
9+
"https://docs.mongodb.com/database-tools/objects.inv",
10+
"https://docs.mongodb.com/mongodb-shell/objects.inv"
1011
]
1112

1213
# toc_landing_pages are pages that have pages nested beneath them

source/appendix/security/appendixC-openssl-client.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ B. Generate the Test PEM File for Client
174174

175175
mongosh --tls --tlsCertificateSelector subject="<TestClientCertificateCommonName>"
176176

177-
Although still available, :option:`--ssl <mongo --ssl>` and
177+
Although still available, :option:`--ssl <mongosh --ssl>` and
178178
:option:`--sslCertificateSelector <mongo
179179
--sslCertificateSelector>` are :ref:`deprecated as of MongoDB 4.2
180180
<4.2-tls>`.

source/core/retryable-writes.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ MongoDB Drivers
7575

7676
:mongosh:`mongosh </>`
7777
To enable retryable writes in :mongosh:`mongosh </>`, use
78-
the :option:`--retryWrites <mongo --retryWrites>` command line option:
78+
the :option:`--retryWrites <mongosh --retryWrites>` command line option:
7979

8080
.. code-block:: bash
8181

source/core/security-ldap-external.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -405,9 +405,9 @@ Connecting to a MongoDB server using LDAP Authorization
405405
When using LDAP for authorization, users connecting via
406406
:mongosh:`mongosh </>` must:
407407

408-
- set :option:`--authenticationDatabase <mongo --authenticationDatabase>` to ``$external``.
408+
- set :option:`--authenticationDatabase <mongosh --authenticationDatabase>` to ``$external``.
409409

410-
- set :option:`--authenticationMechanism <mongo --authenticationMechanism>` to the appropriate authentication
410+
- set :option:`--authenticationMechanism <mongosh --authenticationMechanism>` to the appropriate authentication
411411
mechanism.
412412

413413
If using :ref:`LDAP authentication <security-ldap>`, set this to ``PLAIN``.
@@ -417,13 +417,13 @@ When using LDAP for authorization, users connecting via
417417

418418
If using :ref:`x.509 <security-auth-x509>`, set this to ``MONGODB-X.509``.
419419

420-
- set :option:`--username <mongo --username>` to a username that respects the
420+
- set :option:`--username <mongosh --username>` to a username that respects the
421421
:setting:`security.ldap.authz.queryTemplate`, or any configured
422422
:setting:`security.ldap.userToDNMapping` template.
423423

424-
- set :option:`--password <mongo --password>` to the appropriate password.
424+
- set :option:`--password <mongosh --password>` to the appropriate password.
425425

426-
Include the :option:`--host <mongo --host>` and :option:`--port <mongo --port>` of the MongoDB server,
426+
Include the :option:`--host <mongo --host>` and :option:`--port <mongosh --port>` of the MongoDB server,
427427
along with any other options relevant to your deployment.
428428

429429
For example, the following operation authenticates to a MongoDB server running

source/core/security-x.509.txt

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,14 @@ To connect and authenticate using x.509 client certificate:
6565

6666
- For MongoDB 4.2 or greater, include the following options for the client:
6767

68-
- :option:`--tls <mongo --tls>` (or the deprecated :option:`--ssl
68+
- :option:`--tls <mongosh --tls>` (or the deprecated :option:`--ssl
6969
<mongo --ssl>` option)
7070

71-
- :option:`--tlsCertificateKeyFile <mongo --tlsCertificateKeyFile>`
71+
- :option:`--tlsCertificateKeyFile <mongosh --tlsCertificateKeyFile>`
7272
(or the deprecated :option:`--sslPEMKeyFile
7373
<mongo --sslPEMKeyFile>` option)
7474

75-
- :option:`--tlsCertificateKeyFilePassword <mongo --tlsCertificateKeyFile>`
75+
- :option:`--tlsCertificateKeyFilePassword <mongosh --tlsCertificateKeyFile>`
7676
(or the deprecated :option:`--sslPEMKeyPassword
7777
<mongo --sslPEMKeyPassword>` option) if the certificate key file is encrypted
7878

@@ -84,17 +84,17 @@ To connect and authenticate using x.509 client certificate:
8484

8585
- For MongoDB 4.0 and earlier, include the following options for the client:
8686

87-
- :option:`--ssl <mongo --ssl>`
87+
- :option:`--ssl <mongosh --ssl>`
8888

89-
- :option:`--sslPEMKeyFile <mongo --sslPEMKeyFile>`
89+
- :option:`--sslPEMKeyFile <mongosh --sslPEMKeyFile>`
9090

91-
- :option:`--sslPEMKeyPassword <mongo --sslPEMKeyPassword>` option if
92-
the :option:`--sslPEMKeyFile <mongo --sslPEMKeyFile>` is encrypted.
91+
- :option:`--sslPEMKeyPassword <mongosh --sslPEMKeyPassword>` option if
92+
the :option:`--sslPEMKeyFile <mongosh --sslPEMKeyFile>` is encrypted.
9393

9494
- :option:`--authenticationDatabase '$external'
9595
<mongo --authenticationDatabase>`
9696

97-
- :option:`--authenticationMechanism MONGODB-X509 <mongo --authenticationMechanism>`
97+
- :option:`--authenticationMechanism MONGODB-X509 <mongosh --authenticationMechanism>`
9898

9999
You can also make the TLS/SSL connection first, and then use
100100
:method:`db.auth()` in the ``$external`` database to authenticate.

source/core/sharded-cluster-query-router.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -346,9 +346,9 @@ server>`, with the :option:`--auth <mongod --auth>` option in order to enforce R
346346
Alternatively, enforcing :doc:`/core/security-internal-authentication` for
347347
inter-cluster security also enables user access controls via RBAC.
348348

349-
With RBAC enforced, clients must specify a :option:`--username <mongo --username>`,
350-
:option:`--password <mongo --password>`, and
351-
:option:`--authenticationDatabase <mongo --authenticationDatabase>` when
349+
With RBAC enforced, clients must specify a :option:`--username <mongosh --username>`,
350+
:option:`--password <mongosh --password>`, and
351+
:option:`--authenticationDatabase <mongosh --authenticationDatabase>` when
352352
connecting to the :binary:`~bin.mongos` in order to access cluster resources.
353353

354354
Each cluster has its own cluster users. These users cannot be used

source/includes/extracts-ssl-facts.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ ref: ssl-facts-mongo-ssl-hostname-verification
8282
content: |
8383
8484
:mongosh:`mongosh </>` verifies that the hostname (specified
85-
in :option:`--host <mongo --host>` option or the connection string)
85+
in :option:`--host <mongosh --host>` option or the connection string)
8686
matches the ``SAN`` (or, if ``SAN`` is not present, the ``CN``) in
8787
the certificate presented by the :binary:`~bin.mongod` or
8888
:binary:`~bin.mongos`. If ``SAN`` is present, :mongosh:`mongosh </>`

source/includes/fact-authenticate.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ associated with that user.
55
To authenticate using :mongosh:`mongosh </>`, either:
66

77
- Use the :mongosh:`mongosh </>` command-line authentication options
8-
(:option:`--username <mongo --username>`,
9-
:option:`--password <mongo --password>`, and
10-
:option:`--authenticationDatabase <mongo --authenticationDatabase>`)
8+
(:option:`--username <mongosh --username>`,
9+
:option:`--password <mongosh --password>`, and
10+
:option:`--authenticationDatabase <mongosh --authenticationDatabase>`)
1111
when connecting to the :binary:`~bin.mongod` or
1212
:binary:`~bin.mongos` instance, or
1313

source/includes/steps-configure-ldap-sasl-activedirectory-authentication.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -283,12 +283,12 @@ pre: |
283283
Use :mongosh:`mongosh </>` to authenticate to the MongoDB
284284
server, set the following options:
285285
286-
- :option:`--host <mongo --host>` with the hostname of the MongoDB server
287-
- :option:`--port <mongo --port>` with the port of the MongoDB server
288-
- :option:`--username <mongo --username>` to the user's username
289-
- :option:`--password <mongo --password>` to the user's password
290-
- :option:`--authenticationMechanism <mongo --authenticationMechanism>` to ``'PLAIN'``
291-
- :option:`--authenticationDatabase <mongo --authenticationDatabase>` to ``'$external'``
286+
- :option:`--host <mongosh --host>` with the hostname of the MongoDB server
287+
- :option:`--port <mongosh --port>` with the port of the MongoDB server
288+
- :option:`--username <mongosh --username>` to the user's username
289+
- :option:`--password <mongosh --password>` to the user's password
290+
- :option:`--authenticationMechanism <mongosh --authenticationMechanism>` to ``'PLAIN'``
291+
- :option:`--authenticationDatabase <mongosh --authenticationDatabase>` to ``'$external'``
292292
293293
.. example::
294294
@@ -317,7 +317,7 @@ pre: |
317317
.. note::
318318
319319
If you want to authenticate as an existing non-``$external`` user, set
320-
:option:`--authenticationMechanism <mongo --authenticationMechanism>` to SCRAM authentication mechanism (e.g. ``SCRAM-SHA-1`` or ``SCRAM-SHA-256`` as appropriate). This requires
320+
:option:`--authenticationMechanism <mongosh --authenticationMechanism>` to SCRAM authentication mechanism (e.g. ``SCRAM-SHA-1`` or ``SCRAM-SHA-256`` as appropriate). This requires
321321
that the MongoDB server's :setting:`setParameter`
322322
:parameter:`authenticationMechanisms` includes ``SCRAM-SHA-1`` and/or ``SCRAM-SHA-256``.
323323

source/includes/steps-control-access-to-mongodb-windows-with-kerberos-authentication.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ action:
113113
option, rather than an IP address or unqualified hostname.
114114
115115
If you are connecting to a system whose hostname does not
116-
match the Kerberos name, use :option:`--gssapiHostName <mongo --gssapiHostName>`
116+
match the Kerberos name, use :option:`--gssapiHostName <mongosh --gssapiHostName>`
117117
to specify the Kerberos FQDN that it responds to.
118118
- pre: |
119119
Alternatively, you can first connect :binary:`mongo.exe

0 commit comments

Comments
 (0)