There\'s a typo in my MongoDB database name and I\'m looking to rename the database.
I can copy and delete like so...
db.copyDatabase(\'old_name\', \
The above process is slow,you can use below method but you need to move collection by collection to another db.
use admin db.runCommand({renameCollection: "[db_old_name].[collection_name]", to: "[db_new_name].[collection_name]"})