【文章內(nèi)容簡介】
\Subversion\bin下輸入:svnsync sync file:///F:/svn/svnproject username username password password如下圖所示:如上截圖所示,會一直走下去直至目標(biāo)庫與源庫的版本號完全一致為止。2) 同步結(jié)束后,如下圖所示:到這一步時(shí),SVN遠(yuǎn)程備份就已經(jīng)完成了,如果版本庫較大時(shí),備份的時(shí)間可能會有點(diǎn)慢,要有耐心,用一天也是有可能的,你可以打開目標(biāo)庫看看,和源庫是一樣的。注意:應(yīng)該定期的一周或者兩周打開命令窗口輸入:svnsync sync file:///F:/svn/svnproject 已達(dá)到定期同步的目的。5具體操作操作流程概括: 在要備份的機(jī)器上建立版本庫:svnadmin create svn 進(jìn)入hooks目錄:cd svn/svnproject/hooks/ : ,,并且清空原有的所有內(nèi)容,保存。 修改文件: prerevpropchange文件,為 echo “Changing revision properties other than svn:log is prohibited” amp。2exit 0(1修改為0即可) 同步初步:svnsync init file:///F:/svn/svnproject :8081/svn/svnprojectsvnsync: Destination repository is already synchronizing from ’svn://′ 實(shí)現(xiàn)同步:svnsync sync file:///F:/svn/svnproject –username username –password password1 6遇到的問題與解決方法:Svnsync:Cannot initialize(初始化) a repository with content in it :當(dāng)版本庫有內(nèi)容時(shí)不能初始化如果反復(fù)操作都是同樣錯(cuò)誤的話,很可能是你版本庫有內(nèi)容,需要你版本庫svn,重新按照svn服務(wù)器的安裝手冊里SVN與apache的集成來重新新建版本庫。7同步工具svnsync出錯(cuò)常見問題一:在使用svnsync同步兩個(gè)版本庫時(shí)經(jīng)常出現(xiàn)如下的錯(cuò)誤,并自動中斷了同步操作:Copied properties for revision 461.svnsync: Server sent unexpected return value (502 Bad Gateway) in response to PROPFIND request for ‘/svn/!svn/vcc/default’當(dāng)再次運(yùn)行svnsync sync file:///F:/svn/svnproject時(shí),有可能出現(xiàn)“Failed to get lock on destination repos”的錯(cuò)誤信息,使同步操作無法繼續(xù)進(jìn)行:F:\Subversion svnsync sync file:///F:/svn/svnprojectFailed to get lock on destination repos, currently held by ‘firehack:963c090945ad644fb3837e35d445028f’Failed to get lock on destination repos, currently held by ‘firehack:963c090945ad644fb3837e35d445028f’svnsync: Couldn’t get lock on destinati