title: Admin user to not able to login to other database on mongodb
body: <p>mongo user can able to login on admin database.But can't able to login other databases. </p>
  
  <p>I have given following privileges to the user.</p>
  
  <p>Privileges command : </p>
  
  <pre><code>db.createUser( { user: "root", pwd: "password", roles: [ "readWriteAnyDatabase", "userAdminAnyDatabase", "dbAdminAnyDatabase", "clusterAdmin" ]} )
  </code></pre>
  
  <p>While accessing to other DB form Mongo Shell I got below error</p>
  
  <p>Command line :</p>
  
  <pre><code>C:\mongodb\bin&gt;mongo.exe database-name -u root -p
  
  2014-12-01T12:00:05.806+0000 Error: 18 { ok: 0.0, errmsg: "auth failed", code: 18 } at src/mongo/shell/db.js:1210
  exception: login failed
  </code></pre>
  
  <p>So How can I give access to the DB with the same user?Can anyone please help on this.</p>