Create multiple SVN version Libraries under OcentOS

Source: Internet
Author: User

Create multiple SVN version Libraries under OcentOS

Create multiple SVN version Libraries under OcentOS

The SVN server version library has two formats,

One is FSFS,

One type is BDB

After a file is uploaded to the SVN version library, the uploaded file is no longer stored in the original file format, but is compressed into version library data by svn in its custom format, stored in the version library.

In the FSFS format, the data is stored in the db directory of the version library, and the revs and revprops in the database store the difference data and log information submitted each time.

Create a version library for BDB storage $ mkdir/opt/svn/repositories $ svnadmin create -- fs-type bdb/opt/svn/repositories create a version library for FSFS storage $ mkdir/opt /svn/repos $ svnadmin create -- fs-type fsfs/opt/svn/repos #/opt/svn/is the root directory, but different folder names need to be included in the actual check. [root @ iZ94hzx4xerZ svn] # ll total ready 6 root 4096 Mar 21 reposdrwxr-xr-x 6 root 4096 Mar 21 repositories [root @ iZ94hzx4xerZ svn] # svnserve-d-r/ opt/svn/start svn: method I. svnserve-d-r/opt/svn/# The default start port number is 3690. Method 2: su-svn-c "svnserve-d-listen-port 9999-r/opt/svn/" where: su-svn indicates to start svn as user svn; -d Indicates running in daemon mode (running in the background);-listen-port 9999 indicates using port 9999, which can be replaced with the required port. Note that the root permission is required to use ports lower than 1024.-r/opt/svn specifies that the root directory is/opt/svn. 9. Check whether netstat-tunlp is enabled | grep svn if the following information is displayed, tcp 0 0 0.0.0.0: 9999 0.0.0.0 is successfully started: * LISTEN 10973/svnserve10: Add svn to startup and edit rc. local file: vi/etc/rc. d/rc. add the following startup command to local:/usr/local/svn/bin/svnserve-d-listen-port 9999-r/opt/svn11. If you want to stop svn, run the following command: killall svnserve

12. If you want to use svn as a service: in/etc/rc. d/init. d/create a file named svn in the directory and set the permission to 755: chmod 755/etc/rc. d/init. d/svn edit svn file: vi/etc/rc. d/init. d/svn: Add the following code:

#! /Bin/bash # build thisfile in/etc/rc. d/init. d/svn # chmod 755/etc/rc. d/init. d/svn # Run the following command in centos to manage svn: service svn start (restart/stop) SVN_HOME =/opt/svnif [! -F "/usr/local/svn/bin/svnserve"] thenecho "svnserver startup: cannot start" exitficase "$1" instart) echo "Starting svnserve... "/usr/local/svn/bin/svnserve-d -- listen-port 999999-r $ SVN_HOMEecho" Finished! "; Stop) echo" Stoping svnserve... "killall svnserveecho" Finished! "; Restart) $0 stop $0 start; *) echo" Usage: svn {start | stop | restart} "exit 1 esac

Then you can start svn in the service SVN start (restart/stop) mode. There are many ways to access svn through web. Refer to configuring websvn or bsSvnBrowser.

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.