{"id":6953,"date":"2016-09-30T11:50:22","date_gmt":"2016-09-30T03:50:22","guid":{"rendered":"http:\/\/jpuyy.com\/?p=6953"},"modified":"2016-09-30T11:50:22","modified_gmt":"2016-09-30T03:50:22","slug":"8-245%e5%8d%87%e7%ba%a7subversion","status":"publish","type":"post","link":"https:\/\/jpuyy.com\/?p=6953","title":{"rendered":"8.245\u5347\u7ea7subversion"},"content":{"rendered":"<p>1. \u505c\u6b62apache \/etc\/init.d\/httpd stop \u5907\u4efd\/etc\/httpd\/modules\u4e0b\u7684mod_dav_svn.so\u548cmod_authz_svn.so\u5230\/data\/svn_bak\/repos\/updatesvn<br \/>\ncp mod_dav_svn.so \/data\/svn_bak\/repos\/updatesvn\/<br \/>\ncp mod_authz_svn.so \/data\/svn_bak\/repos\/updatesvn\/<br \/>\nbackup mysql usvn database<br \/>\n2. \u5347\u7ea7\u7248\u672c\u5e93\u76f8\u5173\u4f5c\u4e1a<br \/>\n2.1 \u5347\u7ea7subversion1.8.3 a. \u5907\u4efd\u539f\u64cd\u4f5c\u7cfb\u7edf\u5185subversion\u76f8\u5173\u6267\u884c\u811a\u672c\u3002 \u66ff\u6362\u8def\u5f84\u6ce8\u610f\u4e00\u4e0b\u76ee\u5f55\uff1a\/usr\/bin \/usr\/loal\/bin svn svnadmin.bak svndumpfilter svnlook.bak svnsync svnadmin svn_bak svnlook svnserve svnversion b. \u7f16\u8bd1apache\u76f8\u5173\u6a21\u5757\uff0c \u4e0b\u8f7dsubversion1.8.3\uff0c\u7f16\u8bd1\uff0c\u5b89\u88c5 \u5907\u4efd\/etc\/httpd\/modules\u4e0b\u7684mod_dav_svn.so\u548cmod_authz_svn.so\u5230\/data\/svn_bak\/repos\/updatesvn c. \u5347\u7ea7\u7cfb\u7edfsvn\uff0csvnadmin\u7b49subversion\u76f8\u5173\u6267\u884c\u6587\u4ef6\u7248\u672c\u3002 \u66ff\u6362\u8def\u5f84\u6ce8\u610f\u4e00\u4e0b\u76ee\u5f55\uff1a\/usr\/bin and \/usr\/local\/bin<br \/>\n2.2 \u5bf9\u8001\u7248\u672csvn\u5e93\u8fdb\u884c\u5347\u7ea7\u3002 a. \u5c06svn\u7248\u672c\u5e93\u7684\u540d\u79f0\u8bb0\u5f55\u5728\/root\/svnrepo\u4e2d b. \u4f7f\u7528dump\u65b9\u5f0f\u5907\u4efdsvn\u6570\u636e\u5230\/data\/svn_bak\/repos\/updatesvn cd \/var\/www\/html\/usvn\/files\/ mv svn svn1 cd svn1 for i in `cat \/root\/svnrepo`; do svnadmin dump $i &gt; \/data\/svn_bak\/repos\/updatedump\/$i;done c. \u5c06pre-commit\u91cd\u65b0\u5efa\u7acb\u8f6f\u94fe<br \/>\n3. \u542f\u52a8apache \/etc\/init.d\/httpd start \u6d4b\u8bd5\u5347\u7ea7\u540esvn\u7248\u672c\u662f\u5426\u80fd\u6b63\u5e38\u4f7f\u7528\u3002<\/p>\n<p>[root@office files]# du -sh *24K authz4.0K authz.bak4.0K htpasswd5.5G svn6.5G svn1<\/p>\n","protected":false},"excerpt":{"rendered":"<p>1. \u505c\u6b62apache \/etc\/init.d\/httpd stop \u5907\u4efd\/etc\/httpd\/modules\u4e0b\u7684mod_dav_svn.so\u548cmod_authz_svn.so\u5230\/data\/svn_bak\/repos\/updatesvn cp mod_dav_svn.so \/data\/svn_bak\/repos\/updatesvn\/ cp mod_authz_svn.so \/data\/svn_bak\/repos\/updatesvn\/ backup mysql usvn database 2. \u5347\u7ea7\u7248\u672c\u5e93\u76f8\u5173\u4f5c\u4e1a 2.1 \u5347\u7ea7subversion1.8.3 a. \u5907\u4efd\u539f\u64cd\u4f5c\u7cfb\u7edf\u5185subversion\u76f8\u5173\u6267\u884c\u811a\u672c\u3002 \u66ff\u6362\u8def\u5f84\u6ce8\u610f\u4e00\u4e0b\u76ee\u5f55\uff1a\/usr\/bin \/usr\/loal\/bin svn svnadmin.bak svndumpfilter svnlook.bak svnsync svnadmin svn_bak svnlook svnserve svnversion b. \u7f16\u8bd1apache\u76f8\u5173\u6a21\u5757\uff0c \u4e0b\u8f7dsubversion1.8.3\uff0c\u7f16\u8bd1\uff0c\u5b89\u88c5 \u5907\u4efd\/etc\/httpd\/modules\u4e0b\u7684mod_dav_svn.so\u548cmod_authz_svn.so\u5230\/data\/svn_bak\/repos\/updatesvn c. \u5347\u7ea7\u7cfb\u7edfsvn\uff0csvnadmin\u7b49subversion\u76f8\u5173\u6267\u884c\u6587\u4ef6\u7248\u672c\u3002 \u66ff\u6362\u8def\u5f84\u6ce8\u610f\u4e00\u4e0b\u76ee\u5f55\uff1a\/usr\/bin and \/usr\/local\/bin 2.2 \u5bf9\u8001\u7248\u672csvn\u5e93\u8fdb\u884c\u5347\u7ea7\u3002 a. \u5c06svn\u7248\u672c\u5e93\u7684\u540d\u79f0\u8bb0\u5f55\u5728\/root\/svnrepo\u4e2d b. \u4f7f\u7528dump\u65b9\u5f0f\u5907\u4efdsvn\u6570\u636e\u5230\/data\/svn_bak\/repos\/updatesvn cd \/var\/www\/html\/usvn\/files\/ mv svn svn1 cd svn1 [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[],"class_list":["post-6953","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/posts\/6953","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/jpuyy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6953"}],"version-history":[{"count":1,"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/posts\/6953\/revisions"}],"predecessor-version":[{"id":6954,"href":"https:\/\/jpuyy.com\/index.php?rest_route=\/wp\/v2\/posts\/6953\/revisions\/6954"}],"wp:attachment":[{"href":"https:\/\/jpuyy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6953"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jpuyy.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=6953"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jpuyy.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=6953"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}