To optimize performance of a multi-node MongoDB environment, NetBrain suggests configuring the MongoDB readPreference setting to secondaryPreferred.
 
This setting will ensure that the NetBrain services use the primary/master node for write operations and use the secondary/slave node for read operations.
 
Solution
1. Configure secondaryPreferred on NetBrain Web Server by modifying the NBConfig.json file.
"mongodb_servers":{
      "servers_URL":["192.168.31.248:27017","192.168.31.171:27017","192.168.32.201:27017"],
      "user":"encrypted:Xa0wvkHsHoz9b4DgMM83F9wdEFw5zcSnWRgJ6QMvv7k=",
      "password":"encrypted:mai7idnq6tlTWnfZWqlyWXWyk/mSFRHPqMB4oDQ5xEc=",
      "replicaSet":"rs",
      "extraOptions":"authMechanism=SCRAM-SHA-256&readPreference=secondaryPreferred&w=majority&wtimeoutMS=30000",
      "ssl":false,
      "cert_verification":"none"
   },