SVN安装
服务器环境配置
- 设置服务器的limit参数
* soft nproc 1000000
* hard nproc 1000000
* soft nofile 1000000
* hard nofile 1000000
- 创建svn服务管理账户,将uid和gid设为80
groupadd www -g 80useradd www -u 80 -M -s /sbin/nologin -g www
- 创建Svnhome目录
mkdir -p /svnhome/repos
chown -R www:www /svnhome/repos
SVN安装
- 安装apr和apr-util
- Apr和apr-util必须安装在同一个目录中!*
yum -y install openldap openldap-devel
wget http://mirrors.cnnic.cn/apache/apr/apr-1.5.2.tar.gz
tar -zxvf apr-1.5.2.tar.gz
cd apr-1.5.2
./configure --prefix=/usr/local/apr && make && make install
cd ../
wget http://mirrors.cnnic.cn/apache/apr/apr-util-1.5.4.tar.gz
tar -zxvf apr-util-1.5.4.tar.gz
cd apr-util-1.5.4
./configure --with-sqlite3 --with-ldap --prefix=/usr/local/apr --with-apr=/usr/local/apr/ && make && make install
cd ../
- 安装self-1.2.1
- svn 1.8支持http协议不再使用neon了*
yum -y install expat-devel pcre pcre-devel
wget http://serf.googlecode.com/files/serf-1.2.1.tar.bz2
tar xjf serf-1.2.1.tar.bz2cd serf-1.2.1
./configure --prefix=/usr/local/serf --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr
make && make installcd ..
- 安装apache 2.4.12
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.36.tar.gz
tar -zxvf pcre-8.36.tar.gzcd pcre-8.36
./configure
make
make installcd ../
wget http://mirrors.cnnic.cn/apache//httpd/httpd-2.4.12.tar.gz
tar -zxvf httpd-*cd httpd-*
mv ../apr-1.5.2 srclib/apr
mv ../apr-util-1.5.4 srclib/apr-util
./configure --prefix=/usr/local/apache22 --with-ldap --enable-ldap --enable-authnz-ldap --enable-dav --enable-so --enable-ssl --sysconfdir=/usr/local/etc/apache22 --with-included-apr && make && make installcd ../
- 安装svn
wget wget http://archive.apache.org/dist/subversion/subversion-1.8.9.tar.gz
tar -zxvf subversion-1.8.9.tar.gz
cd subversion-1.8.9
sh get-deps.sh
./configure --with-apxs=/usr/local/apache22/bin/apxs --with-apr=/usr/local/apr --with-apr-util=/usr/local/apr --with-zlib --with-openssl --enable-maintainer-mode --with-serf=/usr/local/serf --enable-mod-activation
make
make install
- 测试
svn --version
svn, version 1.8.9 (r1591380)compiled Jun 24 2015, 15:54:16 on x86_64-unknown-linux-gnu
Copyright (C) 2014 The Apache Software Foundation.
This software consists of contributions made by many people;see the NOTICE file for more information.
Subversion is open source software, see http://subversion.apache.org/
The following repository access (RA) modules are available:
* ra_svn : Module for accessing a repository using the svn network protocol.
- with Cyrus SASL authentication
- handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
- handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
- using serf 1.2.1
- handles 'http' scheme
- handles 'https' scheme