Differences

This shows you the differences between two versions of the page.

Link to this comparison view

en:simple:mongodb [05/06/2016 at 02:48]
Alexandre L. (Gandi) [MongoDB on Simple Hosting]
en:simple:mongodb [11/14/2017 at 20:49] (current)
Richard M. (Gandi) [Importing / Exporting a database]
Line 87: Line 87:
 <code> <code>
 # Export entire database # Export entire database
-$ mongodump --db database_name --out ~/tmp/mongodump-yyyy-mm-dd+$ mongodump --db database_name --out /srv/data/tmp/mongodump-yyyy-mm-dd
  
 # Export a collection within a database # Export a collection within a database
-$ mongodump --collection collection_name --db database_name --out ~/tmp/mongodump-yyyy-mm-dd+$ mongodump --collection collection_name --db database_name --out /srv/data/tmp/mongodump-yyyy-mm-dd
 </code> </code>
  
Last modified: 11/14/2017 at 20:49 by Richard M. (Gandi)