title: How to check if Mongodb is properly installed
body: <p>I installed MongoDb yesterday on a Mac Snow Leopard and got the following error message</p>
  
  <pre><code>Mongo::ConnectionFailure: Failed to connect to a master node at localhost:27017
  </code></pre>
  
  <p>when trying to run some tests in Rails that used a mongodb.</p>
  
  <p>Another SO question <a href="https://stackoverflow.com/questions/4837427/mongo-ruby-connection-problem">mongo - ruby connection problem</a> about the same error message had an answer that recommended removing the lock file</p>
  
  <pre><code> sudo rm /var/lib/mongodb/mongod.lock
  </code></pre>
  
  <p>but when I run that command i'm getting </p>
  
  <pre><code> No such file or directory
  </code></pre>
  
  <p>Any ideas how I can figure out how to get it working or see if it's properly installed?</p>