Skip to content

Commit 5945ee5

Browse files
committed
Updating the recommendations
1 parent f323a18 commit 5945ee5

File tree

7 files changed

+13
-13
lines changed

7 files changed

+13
-13
lines changed

articles/cosmos-db/mongodb/vcore/how-to-connect-mongoshell.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -35,31 +35,31 @@ If you accidentally open all the ports you will be warned before saving the chan
3535
To add your Azure Cosmos DB cluster to Mongo shell, perform the following steps:
3636
1. Retrieve the connection information for your Azure Cosmos DB for MongoDB vCore using the instructions [here](quickstart-portal.md#get-cluster-credentials).
3737

38-
![GIF for getting connection string](./media/connect-using-mongoshell/gettingconnectionstringfromportal.gif)
38+
![GIF for getting connection string](./media/connect-using-mongoshell/getting-connectionstring-from-portal.gif)
3939
Once you have the connection string you can either
4040
- Have the shell prompt you to enter the password or
4141
- Provide the password as a part of the connection string
4242

4343
2. Connect using Mongo Shell
4444

45-
#### A. By entering the password in the MongoShell Prompt
45+
**A. By entering the password in the MongoShell Prompt**
4646

47-
![PNG Prompt image for password for MongoShell](./media/connect-using-mongoshell/passwordpromptinshell.PNG)
47+
![PNG Prompt image for password for MongoShell](./media/connect-using-mongoshell/password-prompting-shell.PNG)
4848

49-
Your connection string would look like this
50-
```
51-
"mongodb+srv://<username>@<servername>.mongocluster.cosmos.azure.com/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000"
52-
```
49+
Your connection string would look like this:
50+
```
51+
"mongodb+srv://<username>@<servername>.mongocluster.cosmos.azure.com/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000"
52+
```
5353
Here is an example of how the command looks like :
54-
```
55-
mongosh "mongodb+srv://[email protected]/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000
56-
```
57-
![GIF for connecting by entering password](./media/connect-using-mongoshell/mongoshellconnect.gif)
54+
```
55+
mongosh "mongodb+srv://[email protected]/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000
56+
```
57+
![GIF for connecting by entering password](./media/connect-using-mongoshell/mongo-shell-connect.gif)
5858

5959
Once you provide the password and are successfully authenticated you will notice some warning stating *"This server or service appears to be an emulation of MongoDB"*
6060
This can be ignored. Its just shell way of notifying that you are not connection to an emulation of MongoDB. Since it is an Azure as a platform as a service offering this is expected.
6161

62-
#### B. By providing the password as a part of the connection string
62+
**B. By providing the password as a part of the connection string**
6363

6464
Alternately you can also use a connection string with the password in which case the format looks something like this
6565
```
@@ -70,7 +70,7 @@ Here is an example of how the command looks like :
7070
```
7171
mongosh "mongodb+srv://mongodbvcoretesting.mongocluster.cosmos.azure.com/?tls=true&authMechanism=SCRAM-SHA-256&retrywrites=false&maxIdleTimeMS=120000" --username "testuser" -password "******"
7272
```
73-
![PNG Image for password as a part of connection string ](./media/connect-using-mongoshell/connectionstringwithpassword.PNG)
73+
![PNG Image for password as a part of connection string ](./media/connect-using-mongoshell/connectionstring-with-password.PNG)
7474

7575
## Next step
7676

Binary file not shown.

0 commit comments

Comments
 (0)