Install SVN Server on Fedora 31/30, CentOS/RHEL 8.0/7.7 - Comment Page: 7
This is guide, howto install SVN (Subversion) server on Fedora 31/30/29/28, CentOS 8.0/7.7/6.10, Red Hat (RHEL) 8.0/7.7/6.10.
What is SVN (Subversion)?
Subversion is a free/open-source version control system. Subversion manages files and directories, and the changes made to them, over time. This allows you to recover older versions of your data, or examine the history of how your data changed. In this regard, many people think of a version control system as a sort of "time machine".
[inttf_post_ad1]
Install SVN (Subversion) Server on Fedora 31/30/29/28, CentOS 8.0/7.7/6.10, Red Hat (RHEL) 8.0/7.7/6.10
1. Change root user
su -
## OR ##
sudo -i
2. Install needed...
Hi,
Is it a requirement for the SVN users also to have accounts under /home/, ? I am using CentOS and I keep getting the following ;
svn ls http://x.y.x.z/svn/ –username t1 –password xxx
svn: access to ‘http://x.y.x.z/svn’ forbidden
My SVN directory setup is as follows;
/var/projects/svn
The config file is as follows;
cat /etc/httpd/conf.d/subversion.conf
LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so
DAV svn
SVNParentPath /var/projects/svn
AuthType Basic
AuthName “Subversion repositories”
AuthUserFile /etc/svn-auth-users
AuthzSVNAccessFile /etc/svn-access-control
Require valid-user
$ cat /etc/svn-access-control
[groups]
testgroup = j1mb1r, testsvn
[/testrepo:/]
@testgroup = rw
I don’t have home directories for these users. Do I need to set it ?
Hi johnwilcox,
You don’t need real Linux users, it should be enough if you have this user on your “auth-users” file and “access-control” file. Check both files and restart Apache.
please teach me
1. how to delete the exist user (such like testuser)?
2. I complete all the steps you show up, and I use Tortoise tool to access SVN. When I check-out the folder from SVN in local folder and I do some tests (such like import some files in the folder). Then I can’t see any additional label on those files such labels are like “Green confirmed”, “Red exclamation” …etc. Can you teach me how to enable those functions?
thanks
Hi Orozco,
1. You can delete user from htpasswd file using following command:
2. Do you mean some Tortoise SVN client specific options? You can check Tortoise SVN settings, maybe you can enable those colors from there.
Oh i have another problem,htpassd can’t create the file /etc/svn-auth-users,What should i do?
Hi sam,
You have to create this file also as root user.
If you check this guide first step, here is commands howto change root user:
Thanks man.
Hi, i cant execute this command. chcon -R -t httpd_sys_rw_content_t /var/www/svn/testrepo, even the apache cant restart?
Do i have to follow apache and svn read more installations and configurations for svn to work?
hi team,
i can access svn repos from URL but when i am committing project on the svn server then not taking user name and password. and below mentioned error i am getting.
error while creating module: org.tigris:subversion.javal.clientException :RA Layerrequest failed
svn: server sent unexpected return value (403 Forbidden) in response to MKACTIVITY request for /SVN/Repos/!Svn/act/3b9f9810-2eb1-4a37-a16832f74506b35a
Hi varun,
A few questions first.
Is this just fresh install or was this working before?
Are you using some external client to do commit?
Did you updated some packages or modified configs, before this problem occurred?
What OS you are running?
No i dont have any client i was using through eclipse, can you help me for the svn client for centos 6.0
Please help me for SVN client
Actually you use client when you use SVN through Eclipse. One question is, do you have exactly same path on SVN server what you use on your Eclipse client?
Another thing to try is use svn command line client on server. Do you still get same error?
And you can also check your server /etc/audit/audit.log file, do you have any svn/subversion errors?
And also you could post output of following commands:
Thakns a lot. I was searching for SELinux entry for SVN.
Hello
Thaks for this tutorial, it make me the day!
I have an error with fedora 18, on importing templates with:
svn import -m ‘Initial import’ /tmp/svn-structure-template/ http://localhost/svn/testrepo/
but trubel was when i added next two lines to block anonymous users:
## Disable anonymous access ##
anon-access = none
## Enable access control ##
authz-db = authz
for some reason fedora have trubels for recognize them.
Simply coment lines (becuse mark an errorr to restart httpd), restar it and create template with your instructions.
I hope this coment was helpful.
Regards
Hello again.
Let me make an correction.
SELinux was active and send to me an un expected server answer.
setenforece 0
do de job
Regards
Hi Team,
can i receive mail when users commit his project on the SVN server, If this is possible then please help me what need to be do?
Hi varun Kumar,
Just check alternatives to accomplish this task.
Actually you can use svn post-commit hook, like described here or you can use redeveloped/improved version of mailer.py svnmailer, which looks actually very nice script.
I haven’t tested this, but looks very easy to get email notifications after commits.
Hi JR
I am getting httpd unpacking error while trying to install
mod_dav_svn.
on centOS 6.4Running Transaction
Installing : subversion-1.6.11-9.el6_4.x86_64 1/3
Installing : httpd-2.2.15-29.el6.centos.x86_64 2/3
Error unpacking rpm package httpd-2.2.15-29.el6.centos.x86_64
warning: /etc/httpd/conf/httpd.conf created as /etc/httpd/conf/httpd.conf.rpmnew
warning: /etc/httpd/conf/magic created as /etc/httpd/conf/magic.rpmnew
error: unpacking of archive failed on file /etc/httpd/logs: cpio: rename
Installing : mod_dav_svn-1.6.11-9.el6_4.x86_64 3/3
Verifying : mod_dav_svn-1.6.11-9.el6_4.x86_64 1/3
Verifying : subversion-1.6.11-9.el6_4.x86_64 2/3
Verifying : httpd-2.2.15-29.el6.centos.x86_64 3/3
Installed:
mod_dav_svn.x86_64 0:1.6.11-9.el6_4 subversion.x86_64 0:1.6.11-9.el6_4
Failed:
httpd.x86_64 0:2.2.15-29.el6.centos
Hi Akhil,
Could you post output of following commands:
I followed your articles to install my SVN server with Apache2 successfully. Now I want to enable https. Do you have some instructions like this?
Hi Jirong Hu,
Do you want use self-signed SSL certificate or commercial SSL certificate?
Hi JR
I’m post some step then I to do. Please help me a sulotion for error :
DAV svn
SVNParentPath /var/www/svn
AuthType Basic
AuthName “Subversion repositories”
AuthUserFile /etc/apache2/dav_svn.passwd
AuthzSVNAccessFile /etc/apache2/mods-enabled/dav_svn.authz
Require valid-user
5. Create Repository for test:
mkdir /var/www/svn
6. Authencation for user access forder
svnadmin create myproject
chown -R www-data myproject
7. Create username
htpasswd -cm /etc/sapache2/dav_svn.passwd testuser1
htpasswd -m /etc/apache2/dav_svn.passwd testuser2
9. Configure file dav_svn.authz control access for every user.
[groups]
testuser1
testuser2
[myproject:/]
testgroup1 = rw
testuser2 = r
Hi sinhatpro,
I read your both comments and looks like you don’t have myproject2 just only myproject?
Then also your dav_svn.authz file groups is missing group names, you only list testuser1 and testuser2, then you set rw permission to testgroup1.
But yes you are right, it’s not SELinux problem, because you are using Ubuntu…