Hi I have one more question
I started mongos and I see in sh.status() two shards which I created
vagrant@m103:~$ mongo --port 26000 -u “m103-admin” -p “m103-pass” --authenticationDatabase “admin”
MongoDB shell version v3.6.9
connecting to: mongodb://127.0.0.1:26000/
Implicit session: session { “id” : UUID(“10d8e934-42d1-4f0a-9808-b42198cc5e03”) }
MongoDB server version: 3.6.9
MongoDB Enterprise mongos> sh.status()
— Sharding Status —
sharding version: {
“_id” : 1,
“minCompatibleVersion” : 5,
“currentVersion” : 6,
“clusterId” : ObjectId(“5c4bd411cc93628af232bdc3”)
}
shards:
{ “_id” : “m103-repl”, “host” : “m103-repl/192.168.103.100:27001,192.168.103.100:27003,m103:27002”, “state” : 1 }
{ “_id” : “m103-repl-2”, “host” : “m103-repl-2/192.168.103.100:27004,192.168.103.100:27005,192.168.103.100:27006”, “state” : 1 }
active mongoses:
“3.6.9” : 1
autosplit:
Currently enabled: yes
balancer:
Currently enabled: yes
Currently running: no
Failed balancer rounds in last 5 attempts: 5
Last reported error: Could not find host matching read preference { mode: “primary” } for set m103-repl
Time of Reported error: Sat Jan 26 2019 18:02:33 GMT+0000 (UTC)
Migration Results for the last 24 hours:
No recent migrations
databases:
{ “_id” : “applicationData”, “primary” : “m103-repl”, “partitioned” : false }
{ “_id” : “config”, “primary” : “config”, “partitioned” : true }
config.system.sessions
shard key: { “_id” : 1 }
unique: false
balancing: true
chunks:
m103-repl 1
{ “_id” : { “$minKey” : 1 } } -->> { “_id” : { “$maxKey” : 1 } } on : m103-repl Timestamp(1, 0)
{ “_id” : “testDatabase”, “primary” : “m103-repl”, “partitioned” : false }
MongoDB Enterprise mongos>
Then I actually killed all the Mongod instances of the replica set “m103-repl-2” I mean
All the three mongd process 192.168.103.100:27004,192.168.103.100:27005,192.168.103.100:27006"
at this point of time, if I goto mongos and see sh.status()
it is still showing both the shards with the nodes
192.168.103.100:27004,192.168.103.100:27005,192.168.103.100:27006"
which are actually not running.
can you explain me on it.