As you might have noticed, we installed the inetutils-ping Linux package, which allows us to run the ping command. For that purpose, you'll find a script called /path/to/repo/chapters/14/verify_connections.sh that tests network communications between servers, as shown here:
#!/bin/bash
docker exec learn-mongo-shard-1 /bin/bash -c \
"ping -c1 shard2.biglittle.local"
docker exec learn-mongo-shard-2 /bin/bash -c \
"ping -c1 shard3.biglittle.local"
docker exec learn-mongo-shard-3 /bin/bash -c \
"ping -c1 config1.biglittle.local"
docker exec learn-mongo-config /bin/bash -c \
"ping -c1 mongos1.biglittle.local"
docker exec learn-mongo-mongos /bin/bash -c \
"ping -c1 shard1.biglittle.local"
After running docker-compose up, from another Terminal window, here is the output from the verification script:
Now, we'll have a look at deploying the replica set to represent the...