1. 개요

SVN에 대해서는 몇차례 다뤄진 바 있습니다.

  • SVN이란?

-> https://sarc.io/index.php/miscellaneous/1189-subversion

  • OS X에서 Apache Subversion Installation

-> http://sarc.io/index.php/miscellaneous/29-os-x-apache-subversion-installation

  • Apache 웹서버 상에 SVN 설치

-> http://sarc.io/index.php/miscellaneous/151-apache-svn


2. 설치 

오늘은 그냥 SVN을 설치하는 방법을 공유합니다.

먼저 SVN 설치 여부를 확인합니다.

# svn
-bash: svn: command not found

설치가 되어 있지 않으므로 yum을 이용하여 설치합니다.

# yum install subversion
Loaded plugins: fastestmirror
Determining fastest mirrors
 * base: mirror.oasis.onnetcorp.com
 * extras: mirror.oasis.onnetcorp.com
 * updates: mirror.oasis.onnetcorp.com
base                                                                                                       | 3.7 kB     00:00
base/primary_db                                                                                            | 4.6 MB     00:01
extras                                                                                                     | 2.9 kB     00:00
extras/primary_db                                                                                          |  33 kB     00:00
updates                                                                                                    | 3.4 kB     00:00
updates/primary_db                                                                                         | 3.2 MB     00:01
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package subversion.x86_64 0:1.6.11-15.el6_7 will be installed
--> Processing Dependency: perl(URI) >= 1.17 for package: subversion-1.6.11-15.el6_7.x86_64
--> Processing Dependency: libneon.so.27()(64bit) for package: subversion-1.6.11-15.el6_7.x86_64
--> Running transaction check
---> Package neon.x86_64 0:0.29.3-3.el6_4 will be installed
--> Processing Dependency: libgnutls.so.26(GNUTLS_1_4)(64bit) for package: neon-0.29.3-3.el6_4.x86_64
--> Processing Dependency: libproxy.so.0()(64bit) for package: neon-0.29.3-3.el6_4.x86_64
--> Processing Dependency: libpakchois.so.0()(64bit) for package: neon-0.29.3-3.el6_4.x86_64
--> Processing Dependency: libgnutls.so.26()(64bit) for package: neon-0.29.3-3.el6_4.x86_64
---> Package perl-URI.noarch 0:1.40-2.el6 will be installed
--> Running transaction check
---> Package gnutls.x86_64 0:2.8.5-18.el6 will be installed
--> Processing Dependency: libtasn1.so.3(LIBTASN1_0_3)(64bit) for package: gnutls-2.8.5-18.el6.x86_64
--> Processing Dependency: libtasn1.so.3()(64bit) for package: gnutls-2.8.5-18.el6.x86_64
---> Package libproxy.x86_64 0:0.3.0-10.el6 will be installed
--> Processing Dependency: libproxy-python = 0.3.0-10.el6 for package: libproxy-0.3.0-10.el6.x86_64
--> Processing Dependency: libproxy-bin = 0.3.0-10.el6 for package: libproxy-0.3.0-10.el6.x86_64
---> Package pakchois.x86_64 0:0.4-3.2.el6 will be installed
--> Running transaction check
---> Package libproxy-bin.x86_64 0:0.3.0-10.el6 will be installed
---> Package libproxy-python.x86_64 0:0.3.0-10.el6 will be installed
---> Package libtasn1.x86_64 0:2.3-6.el6_5 will be installed
--> Finished Dependency Resolution
 
Dependencies Resolved
 
==================================================================================================================================
 Package                            Arch                      Version                            Repository                  Size
==================================================================================================================================
Installing:
 subversion                         x86_64                    1.6.11-15.el6_7                    updates                    2.3 M
Installing for dependencies:
 gnutls                             x86_64                    2.8.5-18.el6                       base                       347 k
 libproxy                           x86_64                    0.3.0-10.el6                       base                        39 k
 libproxy-bin                       x86_64                    0.3.0-10.el6                       base                       9.0 k
 libproxy-python                    x86_64                    0.3.0-10.el6                       base                       9.1 k
 libtasn1                           x86_64                    2.3-6.el6_5                        base                       238 k
 neon                               x86_64                    0.29.3-3.el6_4                     base                       119 k
 pakchois                           x86_64                    0.4-3.2.el6                        base                        21 k
 perl-URI                           noarch                    1.40-2.el6                         base                       117 k
 
Transaction Summary
==================================================================================================================================
Install       9 Package(s)
 
Total download size: 3.2 M
Installed size: 14 M
Is this ok [y/N]: y
Downloading Packages:
(1/9): gnutls-2.8.5-18.el6.x86_64.rpm                                                                      | 347 kB     00:00
(2/9): libproxy-0.3.0-10.el6.x86_64.rpm                                                                    |  39 kB     00:00
(3/9): libproxy-bin-0.3.0-10.el6.x86_64.rpm                                                                | 9.0 kB     00:00
(4/9): libproxy-python-0.3.0-10.el6.x86_64.rpm                                                             | 9.1 kB     00:00
(5/9): libtasn1-2.3-6.el6_5.x86_64.rpm                                                                     | 238 kB     00:00
(6/9): neon-0.29.3-3.el6_4.x86_64.rpm                                                                      | 119 kB     00:00
(7/9): pakchois-0.4-3.2.el6.x86_64.rpm                                                                     |  21 kB     00:00
(8/9): perl-URI-1.40-2.el6.noarch.rpm                                                                      | 117 kB     00:00
(9/9): subversion-1.6.11-15.el6_7.x86_64.rpm                                                               | 2.3 MB     00:00
----------------------------------------------------------------------------------------------------------------------------------
Total                                                                                             2.4 MB/s | 3.2 MB     00:01
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : libproxy-bin-0.3.0-10.el6.x86_64                                                                               1/9
  Installing : libproxy-python-0.3.0-10.el6.x86_64                                                                            2/9
  Installing : libproxy-0.3.0-10.el6.x86_64                                                                                   3/9
  Installing : perl-URI-1.40-2.el6.noarch                                                                                     4/9
  Installing : libtasn1-2.3-6.el6_5.x86_64                                                                                    5/9
  Installing : gnutls-2.8.5-18.el6.x86_64                                                                                     6/9
  Installing : pakchois-0.4-3.2.el6.x86_64                                                                                    7/9
  Installing : neon-0.29.3-3.el6_4.x86_64                                                                                     8/9
  Installing : subversion-1.6.11-15.el6_7.x86_64                                                                              9/9
  Verifying  : libproxy-0.3.0-10.el6.x86_64                                                                                   1/9
  Verifying  : libproxy-bin-0.3.0-10.el6.x86_64                                                                               2/9
  Verifying  : pakchois-0.4-3.2.el6.x86_64                                                                                    3/9
  Verifying  : libproxy-python-0.3.0-10.el6.x86_64                                                                            4/9
  Verifying  : libtasn1-2.3-6.el6_5.x86_64                                                                                    5/9
  Verifying  : gnutls-2.8.5-18.el6.x86_64                                                                                     6/9
  Verifying  : neon-0.29.3-3.el6_4.x86_64                                                                                     7/9
  Verifying  : perl-URI-1.40-2.el6.noarch                                                                                     8/9
  Verifying  : subversion-1.6.11-15.el6_7.x86_64                                                                              9/9
 
Installed:
  subversion.x86_64 0:1.6.11-15.el6_7
 
Dependency Installed:
  gnutls.x86_64 0:2.8.5-18.el6                  libproxy.x86_64 0:0.3.0-10.el6         libproxy-bin.x86_64 0:0.3.0-10.el6
  libproxy-python.x86_64 0:0.3.0-10.el6         libtasn1.x86_64 0:2.3-6.el6_5          neon.x86_64 0:0.29.3-3.el6_4
  pakchois.x86_64 0:0.4-3.2.el6                 perl-URI.noarch 0:1.40-2.el6
 
Complete!

설치가 완료된 것 같으니 실행을 해봅니다.

# svn
Type 'svn help' for usage.

svnserve도 실행합니다.

# svnserve
You must specify exactly one of -d, -i, -t or -X.
Type 'svnserve --help' for usage.

svnserve로 기동을 해봅니다.

# service svnserve start
Starting svnserve:                                         [  OK  ]

svnserve로 중지를 해봅니다.

# service svnserve stop
Stopping svnserve:                                         [  OK  ]

svnserve로 현재 상태를 확인합니다.

# service svnserve status
svnserve is stopped

기본 포트는 3690입니다.

# netstat -an | grep 3690
tcp        0      0 0.0.0.0:3690                0.0.0.0:*                   LISTEN 

저장소를 만듭니다.

# mkdir /svn
# cd /svn
# svnadmin create --fs-type fsfs welcome
# ls -l
total 4
drwxr-xr-x 6 root root 4096 Dec 21 15:03 welcome