A rapid reconstruction method for large-version SVN database backup

Source: Internet
Author: User
Tags svn uuid

SVN warehouses are typically a real-time backup warehouse that configures Svnsync. The repository is copied from one version of the main library, but if the main library already has hundreds of thousands of versions, it is not possible to expect a new backup warehouse with a simple svnsync init, and then start sync from version 0.

To quickly rebuild a backup, you can use the following methods to process

1. First the main library hotcopy a

Svnadmin hotcopy Reponame Reponame-bak
2. Sync Backup to Standby

Rsync-avz Reponame-bak Username@bakserver:/svnroot-path
3. In the standby machine to increase the database SVN permissions

4. Set synchronization properties on a standby

#设置主库的uuid
SVN PS Svn:sync-from-uuid The main library's UUID--revprop-r 0 http://bakserver/repo/reponame
#设置主库的url
SVN PS svn:sync-from-url http://masterserver/repo/reponame--revprop-r 0 http://bakserver/repo/reponame
#设置热备的最新版
Lastver= ' Svnlook youngest Reponame-bak '
SVN PS Svn:sync-last-merged-rev $lastver--revprop-r 0 http://bakserver/repo/reponame
5. The newly submitted version after synchronizing Hotcopy

Svnsync Sync Http://bakserver/repo/reponame

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.