MongoDB replicaset - Delay in election I have local set up for 3 mongo DB instances with successful replica set. (1 Primary, 2 secondary).

If I terminate Primary instance, one of the secondaries becomes Primary but its taking around 10 seconds.

Is there a way I can reduce the time.

I have updated rs.config as below:

  config = rs.config()
  {
"_id" : "rs0",
"version" : 3,
"protocolVersion" : NumberLong(1),
"members" : [
    {
        "_id" : 0,
        "host" : "127.0.0.1:27020",
        "arbiterOnly" : false,
        "buildIndexes" : true,
        "hidden" : false,
        "priority" : 1,
        "tags" : {

        },
        "slaveDelay" : NumberLong(0),
        "votes" : 1
    },
    {
        "_id" : 1,
        "host" : "127.0.0.1:27021",
        "arbiterOnly" : false,
        "buildIndexes" : true,
        "hidden" : false,
        "priority" : 1,
        "tags" : {

        },
        "slaveDelay" : NumberLong(0),
        "votes" : 1
    },
    {
        "_id" : 2,
        "host" : "127.0.0.1:27022",
        "arbiterOnly" : false,
        "buildIndexes" : true,
        "hidden" : false,
        "priority" : 1,
        "tags" : {

        },
        "slaveDelay" : NumberLong(0),
        "votes" : 1
    }
],
"settings" : {
    "chainingAllowed" : true,
    "heartbeatIntervalMillis" : 1000,
    "heartbeatTimeoutSecs" : 3,
    "electionTimeoutMillis" : 10000,
    "catchUpTimeoutMillis" : 2000,
    "getLastErrorModes" : {

    },
    "getLastErrorDefaults" : {
        "w" : 1,
        "wtimeout" : 0
    },
    "replicaSetId" : ObjectId("5976e7bd5b7837e0fbba2871")
  }
}


EDIT

I have reinstalled MongoDB enterprise edition:

   MongoDB shell version: 3.2.15
Yes!
Check here.

You can adjust 


settings.heartbeatTimeoutSecs
settings.electionTimeoutMillis
settings.catchUpTimeoutMillis
settings.heartbeatIntervalMillis