一、安装

Install the package

Install subversion from the official repositories.

Create a repository

Create your repository

mkdir /path/to/repos/
svnadmin create /path/to/repos/repo1

Your initial repository is empty, if you want to import files into it, use the following command.

svn import ~/code/project1 file:///path/to/repos/repo1 --message 'Initial repository layout'

Set access policies

Edit the file /path/to/repos/repo1/conf/svnserve.conf and uncomment or add the line under [general]

password-db = passwd

You might also want to change the default option for anonymous users.

anon-access = read

Replace "read" with "write" for a repository that anyone can commit to, or set it to "none" to disable all anonymous access.

Now edit the file /path/to/repos/repo1/conf/passwd

[users]
harry = foopassword
sally = barpassword

The above defines users harry and sally, with passwords foopassword and barpassword, change it as you like

Start the server daemon

Before you start the server, edit the configuration file:

/etc/conf.d/svnserve
SVNSERVE_ARGS="--root=/path/to/repos"

The --root=/path/to/repos option set the root of repository tree. If you have multiple repositories use --root=/path-to/reposparent. Then access independent repositories by passing in repository name in the URL: svn://host/repo1. make sure that the user has read/write access to the repository files)

Optionally add a --listen-port if you want a different port, or other options.

By default, the service runs as root. If you want to change that, add a drop-in:

/etc/systemd/system/svnserve.service.d/50-custom.conf
[Service]
User=svn

Now start the svnserve.service daemon.

二、注意事项(大坑)

1、如果出现,这样的错误信息,“svnserve: 不能绑定服务器套接字: 地址已经被使用”
那先把svnserve进程干掉。
具体做法是
$ ps -aux | grep svnserve
 #查看进程,svnserve的pid为16663
 $ kill -9 16663 #干掉svnserve
 再次运行$ systemctl start svnserve 
 
 但是利用ps -aux查找进程时,没有找到进程。
 最后的方式是,kill掉守护进程xinetd,然后重新拉起进程svnserve
  
   2、报Option expected
  1. svn: E200002: error while parsing config file :/ home/..../svnserve.conf
  2. svn: E200002: line 19: Option expected

  这是因为修改svnserve.conf时,打开注释时,配置的前面有空格,应该顶格写。

  修改后即可。

3、ping不通

  先看看有没有插网线。

 
参考:
https://wiki.archlinux.org/index.php/Subversion
http://blog.csdn.net/zxnlmj/article/details/40621279
http://www.mamicode.com/info-detail-1100667.html
http://blog.csdn.net/duguduchong/article/details/8819028

arch搭建SVN服务器的更多相关文章

  1. 如何搭建SVN服务器,详细安装步骤。

    SVN服务器端安装 下载: VisualSVN是一款图形化svn服务器.官网 http://www.visualsvn.com/server/ 下载地址: http://www.visualsvn.c ...

  2. CentOS 7搭建SVN服务器

    安装步骤如下: 1.yum install subversion 2.查看安装版本 svnserve --version 3.创建SVN版本库目录 mkdir -p /var/svn/svnrepos ...

  3. Linux下搭建SVN服务器及自动更新项目文件到web目录(www)的方法

    首先搭建SVN服务器 1,安装SVN服务端 直接用apt-get或yum安装subversion即可(当然也可以自己去官方下载安装) sudo apt-get install subversion   ...

  4. 记录第一次搭建svn服务器

    搭建svn服务器需要另外的软件, 在此以32位的为例: 安装过程非常简单, 一直下一步下一步确定就好了, svn安装完毕再安装中文语言包, 安装完成后可以在设置里面找到中文简体选择就OK了 主要记录一 ...

  5. 如何在win上搭建SVN服务器

    本博文转自:http://www.cnblogs.com/armyfai/p/3985660.html SVN简介: 为什么要使用SVN? 程序员在编写程序的过程中,每个程序员都会生成很多不同的版本, ...

  6. Ubuntu 14.04 下搭建SVN服务器 svn://

    Ubuntu 14.04 下搭建SVN服务器 svn:// 安装软件包: sudo apt-get install subversion 之后选择SVN服务文件及配置文件的放置位置.我放在了/srv下 ...

  7. Mac 搭建 SVN 服务器环境

    Mac 搭建 SVN 服务器环境 一.创建svn repository svnadmin create /path/svn/pro //仓库位置,svn是svn的目录,pro是一个版本库的目录 PS: ...

  8. Ubuntu 14.04快速搭建SVN服务器及日常使用【转】

    转自:http://www.linuxidc.com/Linux/2015-05/117735.htm 1.介绍  Subversion是一个自由,开源的版本控制系统,这个版本库就像一个普通的文件服务 ...

  9. 原 Linux搭建SVN 服务器2

    原 Linux搭建SVN 服务器 发表于1年前(2014-08-05 17:55)   阅读(12257) | 评论(3) 31人收藏此文章, 我要收藏 赞3 摘要 Linux搭建SVN 服务器 目录 ...

随机推荐

  1. 【转】 Pro Android学习笔记(三七):Fragment(2):基础小例子

    目录(?)[-] 小例子运行效果 Pre-step一点准备 Step 1Activity的布局 小例子运行效果 这是一个书名和书简介的例子.运行如下图.Activity由左右两个Fragment组成, ...

  2. GCC提供的几个內建函数

    参考 https://gcc.gnu.org/onlinedocs/gcc-4.3.2/gcc/Other-Builtins.html#Other-Builtins https://en.wikipe ...

  3. glusterfs安装配置简单使用

    GlusterFS是一种分布式分布式文件系统,默认采用无中心完全对等架构,搭建维护使用十分简单,是很受欢迎的分布式文件系统. 官网https://www.gluster.org/,官网上表示Glust ...

  4. Python-Redis的String操作

    Ubuntu安装Redis sch01ar@ubuntu:~$ sudo apt install redis-server sch01ar@ubuntu:~$ redis-server sch01ar ...

  5. CentOS 配置RDP

    XRDP服务器 CentOS安装XRDP实现远程桌面访问: 由于安装的是远程桌面,因此需要安装桌面显示服务:# yum install vnc-server 下面开始配置XRDP服务 l  配置环境: ...

  6. qtp重定义数组大小

    a dim arr1() ) a  dim arr() ReDim arr(a) arr arr ) arr For each i in arr     print arr(i) Next

  7. C#设计模式(8)——桥接模式

    一.概念 桥接模式即将抽象部分与实现部分脱耦,使它们可以独立变化. 二.模型 三.代码实现 // 客户端调用 // 类似Web应用程序 class Client { static void Main( ...

  8. free查看内存情况

    free命令可以显示当前系统未使用的和已使用的内存数目,还可以显示被内核使用的内存缓冲区. free [option]     -b:以Byte为单位显示内存使用情况:      -k:以KB为单位显 ...

  9. 《精通Spring4.X企业应用开发实战》读后感第六章(内部工作机制、BeanDefinition、InstantiationStrategy、BeanWrapper)

  10. 如何设置 Windows 默认命令行窗口大小和缓冲区大小

    关键字: 命令行不能全屏 命令行最大化只有一半屏幕 命令行 字体 背景 颜色 解决方案:http://unmi.cc/save-windows-command-size/ 简要说明: win+r,输入 ...