[DOCS-9570] Docs for SERVER-3181: Add option to listDatabases to only get db names, not size info Created: 05/Dec/16  Updated: 18/Apr/17  Resolved: 17/Apr/17

Status: Closed
Project: Documentation
Component/s: Server
Affects Version/s: None
Fix Version/s: 3.4.3, 3.2.13

Type: Task Priority: Major - P3
Reporter: Emily Hall Assignee: Kay Kim (Inactive)
Resolution: Duplicate Votes: 0
Labels: commands, listDatabases, performance
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates DOCS-10011 Need to document namesOnly option for... Closed
Participants:
Days since reply: 7 years, 10 weeks, 2 days ago
Epic Link: PM-248

 Description   

Add nameOnly option to listDatabases.

Engineering Ticket Description:

I have about 29377 files (including datafile and nsfile), 13666 databases. The total size is about 1TB. The mongod started with parameters "smallfiles" and "noprealloc".
When I run the command listDatabases, it takes too long on calculating "sizeOnDisk" and determining the empty of database, more than a hour sometimes. But I just need a list of database names. An option to not display size or empty probably makes sense.
I found that mongod will receive the listDatabases command in the following cases:
1. Dump all databases use mongodump
2. A Member of replica set doing initialSync
3. Add a new shard to a cluster.
In these cases, listDatabases may cause mongod overload and can not do the normal queries.


Generated at Thu Feb 08 07:58:40 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.