Study the cluster configuration under Windows, after checking the data after testing, found that there are several problems to record
The configuration process is referenced in this article:
Http://www.cnblogs.com/zhanjun/p/4649277.html
Configure three nodes, Port: 32000,32001,32002
Post-Configuration issues:
1 Connect MONGO db, enter command:
C:\users\administrator>mongo localhost:32000
Tips:
2017-11-05t11:47:02.626+0800 I control [main] Hotfix KB2731284 or later update
is not installed, would zero-out data files
Think what is wrong, check the data to install patches, so download after installation, restart, or reported this error. Regardless of it, the system can also run edit, query operations.
2 Install the query tool Robomongo, when creating a connection, the total hint is not connected, but I started with the default port to create a database can be connected, and later found
The connected server cannot write localhost or computer name, written as an IP address (127.0.0.1 or actual LAN address)
3 when the primary service node is created, an error is added from the service node and the quorum node:
Rs0:primary> Rs.add ("localhost:32001")
{
"OK": 0,
"ErrMsg": "Either all host names in a replica set configuration must is
localhost references, or none must be; Found 1 out of 4 ",
"Code": 103
}
Use computer name, success (try with localhost and 127.0.0.1, fail)
How to test for success from the server.
Create a dataset on the master node or edit the data in the dataset to automatically update from the server
It appears that automatic data replication is achieved, but it does not know how it actually works. As I have previously configured the MySQL log synchronization, the test is also normal synchronization, but in the actual operation, synchronization is often problematic.