title: Restarting replication set MongoDB
body: <p>I just created replica set within Mongo db, and I am curious when turn off cmd window, or when I type ctrl + c, so in case I want to run replica set again, how am I going to do that ? Which steps are needed ? Hopefully I will not have to start all over again in creating rs?</p>
  
  <p>Thank You.</p>
  
  <p>here is what I got. </p>
  
  <pre><code>MongoDB Enterprise &gt; rs.status()
  {
      "set" : "rs0",
      "date" : ISODate("2017-11-26T03:14:48.098Z"),
      "myState" : 1,
      "term" : NumberLong(2),
      "heartbeatIntervalMillis" : NumberLong(2000),
      "optimes" : {
              "lastCommittedOpTime" : {
                      "ts" : Timestamp(1511666085, 1),
                      "t" : NumberLong(2)
              },
              "appliedOpTime" : {
                      "ts" : Timestamp(1511666085, 1),
                      "t" : NumberLong(2)
              },
              "durableOpTime" : {
                      "ts" : Timestamp(1511666085, 1),
                      "t" : NumberLong(2)
              }
      },
      "members" : [
              {
                      "_id" : 0,
                      "name" : "mario:27017",
                      "health" : 1,
                      "state" : 1,
                      "stateStr" : "PRIMARY",
                      "uptime" : 818,
                      "optime" : {
                              "ts" : Timestamp(1511666085, 1),
                              "t" : NumberLong(2)
                      },
                      "optimeDate" : ISODate("2017-11-26T03:14:45Z"),
                      "electionTime" : Timestamp(1511665273, 1),
                      "electionDate" : ISODate("2017-11-26T03:01:13Z"),
                      "configVersion" : 7,
                      "self" : true
              },
              {
                      "_id" : 1,
                      "name" : "mario:27018",
                      "health" : 1,
                      "state" : 2,
                      "stateStr" : "SECONDARY",
                      "uptime" : 804,
                      "optime" : {
                              "ts" : Timestamp(1511666085, 1),
                              "t" : NumberLong(2)
                      },
                      "optimeDurable" : {
                              "ts" : Timestamp(1511666085, 1),
                              "t" : NumberLong(2)
                      },
                      "optimeDate" : ISODate("2017-11-26T03:14:45Z"),
                      "optimeDurableDate" : ISODate("2017-11-26T03:14:45Z"),
                      "lastHeartbeat" : ISODate("2017-11-26T03:14:46.565Z"),
                      "lastHeartbeatRecv" : ISODate("2017-11-26T03:14:46.575Z"),
                      "pingMs" : NumberLong(0),
                      "syncingTo" : "mario:27017",
                      "configVersion" : 7
              },
              {
                      "_id" : 2,
                      "name" : "mario:27019",
                      "health" : 1,
                      "state" : 7,
                      "stateStr" : "ARBITER",
                      "uptime" : 39,
                      "lastHeartbeat" : ISODate("2017-11-26T03:14:46.570Z"),
                      "lastHeartbeatRecv" : ISODate("2017-11-26T03:14:47.762Z"),
                      "pingMs" : NumberLong(0),
                      "configVersion" : 7
              }
      ],
      "ok" : 1
  </code></pre>
  
  <p>}</p>