show collections not showing all collections while db.stats() showing

63 views
Skip to first unread message

Mukesh Kumar

unread,
May 19, 2017, 11:38:01 AM5/19/17
to mongodb-user
We have mongodb v2.4.5 running. When I do show collections, it shows 2 collections only but in db.stats(); count is showing more than 100. Even I have checked data directory also, file of not showing collections(when I do show collections, that collection doesn't exist there).

Is it a bug of this version or what, couldn't find anything related to this issue.

Please let me know if needed more info on this.

Thanks in advance.

Mukesh Kumar

unread,
May 23, 2017, 6:23:49 AM5/23/17
to mongodb-user
Any update on this, is it a bug.

Asya Kamsky

unread,
May 23, 2017, 11:30:50 AM5/23/17
to mongodb-user
Did you check Jira?  Is your mongod server and mongo shell the same version?  Both 2.4.5 (that's quite old).  You can check the two versions in the shell via:
> db.version()  // for server
> version()   // for shell


There've been some issues (i.e. https://jira.mongodb.org/browse/SERVER-16728) but mostly having to do with mismatch of shell versions and server versions which exposes some incompatibilities.

Mukesh Kumar

unread,
May 23, 2017, 12:44:04 PM5/23/17
to mongodb-user
Yes, I checked, no Jira ticket matched as per our current issue, both mongod & mongo shell version is same. Let me know if more info needed.

> db.version()
2.4.5
> version()
2.4.5
Reply all
Reply to author
Forward
0 new messages