Skip to content

Instantly share code, notes, and snippets.

@richjenks
Created January 21, 2018 13:40
Show Gist options
  • Save richjenks/6106332f545b548f47e9240043a2c236 to your computer and use it in GitHub Desktop.
Save richjenks/6106332f545b548f47e9240043a2c236 to your computer and use it in GitHub Desktop.
MongoDB Snippets
// Start
mongod --dbpath C:\Programs\MongoDB\Data
// Dump & Restore
mongodump --host HOST_NAME --db DATABASE_NAME --username USERNAME --password "PASSWORD" --out BACKUP_PATH
mongorestore --host HOST_NAME --db DATABASE_NAME RESTORE_PATH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment