Transferred from: http://www.blogjava.net/nkjava/archive/2011/08/29/357502.html
Build SVN service, effective management code, the following three steps can be quickly done.
1. Installation
#yum Install Subversion
Determine if the installation was successful
#subversion-V
Svnserve, Version 1.6.11 (r934486)
The above prompts indicate that the installation was successful.
If prompted as follows:-bash:subversion:command not found
After finding:
[Email protected]]# svnserve--versionsvnserve, version 1.6.11 (r934486)
Compiled APR 11 2013, 16:13:51
Copyright (C) 2000-2009 CollabNet.
Subversion is open source software, see http://subversion.tigris.org/
This product includes software developed by CollabNet (http://www.Collab.Net/).
The following repository back-end (FS) modules is available:
* Fs_base:module for working with a Berkeley DB repository.
* Fs_fs:module for working with a plain file (FSFS) repository.
Cyrus SASL authentication is available.
With SVN software, you also need to build an SVN repository.
#mkdir/opt/svn/repos
#svnadmin Create/opt/svn/repos
After executing the above command, we automatically set up several files under repos, namely Conf, Db,format,hooks, locks, README.txt.
2. Configuration
The above operation is very simple, a few commands will be done, the following operation is not difficult.
Go to the above generated folder conf, configure it, there are several files Authz, passwd, svnserve.conf
Where Authz is the permission control, you can set which users can access which directories, passwd is to set the user and password, Svnserve is to set up SVN-related operations.
2.1 Set passwd First
[Users]
# Harry = Harryssecret
# sally = Sallyssecret
Hello=123
User name = password
So we set up a hello user, 123 password
2.2 Set permissions again Authz
[/]
hello= RW
This means that the Hello user has read and write access to all directories, but can also be qualified.
If you use it yourself, read it directly.
2.3 Final Setting snvserv.conf
Anon-access = none # makes non-authorized users inaccessible
auth-access = Write # Enables authorized users to have write permissions
password-db = password
authz-db = authz # access Control file
Realm =/opt/svn/repos # authentication namespace, Subversion is displayed in the authentication prompt and as a keyword for credential caching.
The default configuration is used. All of the above statements must be shelf written, the left cannot be blank, or an error will occur.
Well, with the above configuration, your svn will be OK.
3. Connection
Start svn:svnserve-d-r/opt/svn/repos
If you already have SVN running, you can run it on a different port.
svnserve-d-r/opt/svn/repos--listen-port 3391
So that the same server can run multiple Svnserver
OK, after the successful launch, you can use it.
It is recommended to use TORTOISESVN with the connection address: Svn://your server addresses (if port is required to specify ports: port number)
After the connection can upload the local files, effectively manage your code.
Through the above three steps, you can quickly build up SVN, open your project, if you feel useful, please leave a message, thank you for your support.
Reprint please famous from (Public Information Service network), thank you!
I'm glad this article has reached the first Baidu search, will continue to work hard to write original and high-quality blog post.
If you think this article is helpful to you, please support the blog Head of the ads, blog head of the book, is the author of a selection of learning Linux and other related books.
CentOS Install SVN server