title: mongodb 3.4.2 InvalidIndexSpecificationOption error: The field 'unique' is not valid for an _id index specification
body: <p>The command <code>db.testCollection.createIndex( { _id: 1 }, {name: "_id_2", unique: true, background: true} )</code> fails on mongo version 3.4.2, but not 3.2.11.  The mongo documentation indicates the version 3.4 supports both the <code>unique</code> and <code>background</code> attributes.</p>
  
  <p>Mongo 3.4.2 fails ...</p>
  
  <pre><code>&gt; use testDB
  switched to db testDB
  &gt; db.testCollection.createIndex( { _id: 1 }, {name: "_id_2", unique: true, background: true} )
  {
      "ok" : 0,
      "errmsg" : "The field 'unique' is not valid for an _id index specification. Specification: { ns: \"testDB.testCollection\", v: 1, key: { _id: 1.0 }, name: \"_id_2\", unique: true, background: true }",
      "code" : 197,
      "codeName" : "InvalidIndexSpecificationOption"
  }
  &gt; 
  </code></pre>
  
  <p>Mongo 3.2.11 works ...</p>
  
  <pre><code>&gt; use testDB
  switched to db testDB
  &gt; db.testCollection.createIndex( { _id: 1 }, {name: "_id_2", unique: true, background: true} )
  {
      "createdCollectionAutomatically" : false,
      "numIndexesBefore" : 1,
      "numIndexesAfter" : 1,
      "note" : "all indexes already exist",
      "ok" : 1
  }
  &gt; 
  </code></pre>
  
  <p>Anyone know of a work around?  </p>
  
  <p>We're using the Mongoose Node.js wrapper to create the Mongo indexes, so not adding the <code>unique</code> and <code>background</code> attributes isn't an option.</p>
  
  <p>Cheers!</p>
  
  <p>Ed</p>