While accessing the database in command line, the 'show dbs' list all the existing databases showing the one I want to access as empty.
EDIT: Neverless using the database and running db.stats() it show the correct size of data.
The output of show dbs :
db1 (empty)
db2 (empty)
db3 0.999755859375GB
db_5 (empty)
But I can access, query, count and show the data stored in db_5.
Can someone explain me why this is shown as empty? Can I export it correctly without loosing data?
EDIT: After export and then stopping and restarting mongodb: database is now shown as completly empty and I'm then unable to select count or show data.
In my case I was accessing mongo without credentials. So changed my command to
mongo --username mongouser --password mongopass
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With