一、安装

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. Linux系统中‘dmesg’命令处理故障和收集系统信息的7种用法

    转自:https://linux.cn/article-3587-1.html 'dmesg'命令显示linux内核的环形缓冲区信息,我们可以从中获得诸如系统架构.cpu.挂载的硬件,RAM等多个运行 ...

  2. HTML表格中<td scope="col">与<td scope="row">的含义

    HTML表格中<td scope="col">与<td scope="row">的含义 表格中 <td scope="c ...

  3. 使用pygame制作一个简单的游戏

    翻译自Will McGugan的<Beginning Game Development with Python and Pygame –From Novice to Professional&g ...

  4. 关于SCANF 与 GETS(C语言)

    SCANF遇到空格会自动停止录入字符串,而GETS不会,GETS可以用于输入带空格的字符串

  5. POJ 3690 Constellations (哈希)

    题意:给定上一n*m的矩阵,然后的t个p*q的小矩阵,问你匹配不上的有多少个. 析:可以直接用哈希,也可以用AC自动机解决. 代码如下: #pragma comment(linker, "/ ...

  6. layui js中求某一天距今天有多少天

    <script> lay('#version').html('-v'+ laydate.v); //执行一个laydate实例 laydate.render({ elem: '#test1 ...

  7. 【Spring-任务调度】

    Spring-任务调度: spring内部有一个task是Spring自带的一个设定时间自动任务调度task使用的时候很方便,但是他能做的东西不如quartz那么的多!可以使用注解和配置两种方式,配置 ...

  8. NetCore 学习笔记(DI 实例生命周期)

    Transient: 每一次GetService都会创建一个新的实例 Scoped:    在同一个Scope内只初始化一个实例,同一个请求内只会被创建一次 Singleton :整个应用程序生命周期 ...

  9. sql各种查询技巧

    SQL Server T-SQL高级查询 高级查询在数据库中用得是最频繁的,也是应用最广泛的. Ø 基本常用查询 --select select * from student; --all 查询所有 ...

  10. Exceptionless - .Net Core开源日志框架

    Exceptionless - .Net Core开源日志框架 作者:markjiang7m2 原文地址:https://www.cnblogs.com/markjiang7m2/p/11020140 ...