Created
November 12, 2019 04:49
-
-
Save ryanvgates/7c78e28f30adcacdfb0ad94912ee5162 to your computer and use it in GitHub Desktop.
Mongo Gotcha: use myDB from cli
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
..[ryan@host] - [~/Documents/git/repo] - [Mon Aug 26, 12:16] | |
..[$] <( (git)-[branch]-)> mongo | |
MongoDB shell version v4.0.3 | |
connecting to: mongodb://127.0.0.1:27017 | |
WARNING: No implicit session: Logical Sessions are only supported on server versions 3.6 and greater. | |
Implicit session: dummy session | |
MongoDB server version: 3.2.15 | |
WARNING: shell and server versions do not match | |
> use myDB | |
switched to db myDB | |
> db.runCommand({ dbHash:1 }) | |
{ | |
"host" : "fa34c6baf5a9", | |
"collections" : { | |
"3_20_1_1" : "b21dc0787d226ca7668f901d18f434f8", | |
"3_20_2_1" : "4f60ad3345ef546712ec3e72fc86f95b", | |
"3_5_3" : "da5097b8683c8f19c48c22abf63ebffa", | |
"3_5_5" : "4121a956b7160d49ca0ca8d6bf4b282a", | |
"4_20_3_2" : "573da6f1fac32422403a2e2a1c7b16e6", | |
"4_5_7" : "25951ce17fbc465187c7c6e075846686", | |
"5_20_4_3" : "4057fa6630cd40e474179ea5a9c4d87b", | |
"5_5_9" : "39cbf0af85f1e486cdbf8e7fc75e06e4" | |
}, | |
"md5" : "bc73814f993c792129acd5ad3c5565a0", | |
"timeMillis" : 76, | |
"fromCache" : [ ], | |
"ok" : 1 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment