This problem has occurred for several days. The log contains dozens of nowritehasbeendoneonthisconnection times a day. The operation done by the program is to throw getLastError when a problem occurs, and then check the getLastError method. W has several values. 1: After writing the Code, any server can proceed to the next step.
This problem has occurred for several days. The log contains dozens of no write has been done on this connection times a day, so it has been studied for several days. The operation done by the program is to throw getLastError when a problem occurs, and then check the getLastError method. W has several values. 1: After writing the Code, any server can proceed to the next step.
This problem has occurred for several days. The log contains dozens of times of no write has been done on this connection,
So I studied it for several days.
The operation done by the program is to throw getLastError when a problem occurs.
Then I checked the getLastError method. W has several values,
1: Any server can perform the next step after writing the script.
2: two instances are required.
0: The write operation is continued, regardless of whether the write is completed or not.
Another value is majority. After reading the official documentation, I understand that majority is used for values greater than 2. The following is an official explanation
The above is an official explanation of several parameters.
Another value is j, true, false, and true to enable logging.
For example, w: 1, j: true, you must write the write operation to journal on a server before proceeding to the next step.
As shown in the figure, you must finish writing journal to return a valid value.
From the red line, we can see that majority will replace a number greater than 2,
Return to the question, report the error, and find the version problem. We can verify by using the following method: On 2.2, remove an empty set, and then immediately enter getLastError (w: 1) To return the question error, but on 2.6, no.