title: copying mongo database to local
body: <p>I need to copy a mongo database from my Mongo Cloud Atlas and use it with my meteor app locally, but after doing the following steps, <code>db.users.find().count()</code> still reports the "older" database count not the new one I thought I correctly restored after mongodump. Any ideas?</p>
  
  <p>dump from the Atlas cluster, run from the app parent directory:<br>
  <code>mongodump --host Cluster0-shard-0/cluster0-shard-00-00-oko1k.mongodb.net:27017,cluster0-shard-00-01-oko1k.mongodb.net:27017,cluster0-shard-00-02-oko1k.mongodb.net:27017 --ssl --username myname --password myPswd --authenticationDatabase admin --db dbName
  </code></p>
  
  <p>Terminal reports lines like:<br>
  <code>
  2018-03-17T05:03:57.462+1100    writing dbName.tempLinksGroupsCol to 
  2018-03-17T05:03:57.465+1100    done dumping dbName.commonCol (1 document)
  </code></p>
  
  <p>Confirm the presence of a dump directory which contains a directory "dbName".</p>
  
  <p>copy data from newly dumped dbName to my local dbName by running this command from the app parent directory:  </p>
  
  <p><code>mongorestore --maintainInsertionOrder -h 127.0.0.1 --port 3001 --drop -d dbName dump/dbName
  </code></p>
  
  <p>I get lines like:<br>
  <code>
  2018-03-17T05:21:48.826+1100    finished restoring dbName.cronHistory (0 documents)
  2018-03-17T05:21:48.826+1100    done
  </code>
  switch to the app directory and run the command:<br>
  <code>meteor</code>
  open a new terminal and run the command:<br>
  <code>meteor mongo</code></p>
  
  <p>issue the command from the mongo shell:<br>
  <code>db.users.find().count()</code></p>
  
  <p>Still reports the old count not the new one from the restored database.</p>