I have a mongodb running on server:27017.
From a different machine, I installed mongo-client and connected to mongodb running on server.
I have three dbs in mongo: admin, local, and template (these were created for me by a script).
When I do:
use template
db.stats()
I get:
db.stats()
{
"db" : "template",
"collections" : 2,
"views" : 0,
"objects" : 1001,
"avgObjSize" : 565.1118881118881,
"dataSize" : 565677,
"storageSize" : 110592,
"numExtents" : 0,
"indexes" : 5,
"indexSize" : 86016,
}
If, however, I do
show collections
or
db.getCollectionNames()
I get nothing.
What does this mean? Why is there a DB with indexes and objects, but no collections, and why does the count of collections in template db >0, but show collections gives nothing back?