SVN power failure recovery

Description of the problem: The SVN server is suddenly powered off, and the entire SVN server cannot work after restarting.
Error condition: Error: cannot open file "*\db\current": The file or directory is corrupt and cannot be read.
Solution:
First, the SVN version log information is stored in the revprops directory under the DB directory of the SVN repository,
and the latest file is named with the current version number. For example: "4082"
Second, the SVN version log file also has an index document current under the DB directory. The content in the document must have the name of the
latest log file, such as: "4082 4nr6 i". We only focus on the previous string of "4082".

Because the client just submits the program code when the power outage is down, and at this time, the SVN system first updates the content in the current document, and then generates a new log file such as "4082". At this time, the content in current is correct, but the format of the content in the generated log file is completely incorrect, which is the real reason that SVN cannot work.

For these analyses, we only need to change the content of the current document in the DB directory to the previous version such as "4081", and
then delete the latest document such as "4082" in the revprops directory

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325864864&siteId=291194637