title: setting up mongodb replica sets
body: <p>I am a newbie to mongo db and looking to set up a replica set. I am confused though as how I can achieve this.</p>
  
  <p>I want to have a primary, secondary and arbiter of 3 different machines, each running mongo.</p>
  
  <p>I have been trying to set it up but have made a mess of it I think! How can I remove any replica sets/configuration I have in place?</p>
  
  <p>I have installed mongo, and pointed each instance of mongo at a config file like this:</p>
  
  <pre><code>logpath=D:\mongodb\log\mongo.log 
  logappend=true
  dbpath=D:\mongodb\data
  directoryperdb=true
  port = 27017
  replSet = rsMySet
  </code></pre>
  
  <p>From here though, I am not sure what to do. I have read a number of articles, examples etc but all is confusing. </p>
  
  <p>Could someone provide step by step instructions of how it can be done?</p>
  
  <p>Also, I want to connect to this replica set from a C# web application. What should my connection string point at? the primary, secondary or how does it work? Also, what user should be used to access mongo? I use integrated security when accessing sql server, is the same possible here?</p>
  
  <p>Thanks,
  Niall</p>