You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by James <ol...@yahoo.com> on 2014/09/05 06:20:39 UTC

cannot connect to svnserve locally and remotely

I got latest subversion setup on my latest Fedora  20. 

I created repository. 

I modified the svnserve.conf file and the passwd file in that repository.
I modified the firewall to open 3690 to public for TCP.
The svnserve.service is running. but I got E000013 error when I try to connect to it with svn protocol locally (the same machine) and remotely. The error message is this:

$svn co svn://devserver/Playground Playground --username bowing
svn: E000013: Unable to connect to a repository at URL 'svn://devserver/Playground'
svn: E000013: Can't open file '/home/svn/Playground/format': Permission denied

The svnserve is running:

$systemctl status svnserve.service
svnserve.service - Subversion protocol daemon
   Loaded: loaded (/usr/lib/systemd/system/svnserve.service; enabled)
   Active: active (running) since Fri 2014-09-05 00:10:29 EDT; 2min 16s ago
  Process: 1111 ExecStart=/usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid $OPTIONS (code=exited, status=0/SUCCESS)
 Main PID: 1129 (svnserve)
   CGroup: /system.slice/svnserve.service
           └─1129 /usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid -r /home/svn


how to diagnosis the issue? how to fix it?

Thanks,
James

Re: cannot connect to svnserve locally and remotely

Posted by James <ol...@yahoo.com>.
Thank you guys.  Connected!!!!

It is selinux stop the connection to the svnserve.

I should mentioned that I have create an user group and changed the owner and permission on the repository.
I also modified the svnserve.conf and passwd files of that repository and enabled to use passwd and added users in the passwd file.

But it seems the password policy doesn't work. Anyuser can connect to that repository. I read the svn-book and few online instructions. I do enabled the policy but it doesn't work for me. Any thoughts? Maybe because my repository is empty (no custom files yet)? But I guess it shouldn't matter, right?


Another question is how can I set the selinux allows the svnserve connections? I don't want to turn it off just because the subversion.

Thanks,
James




On Friday, September 5, 2014 5:31 AM, Philip Martin <ph...@wandisco.com> wrote:
 


James <ol...@yahoo.com> writes:


> I got latest subversion setup on my latest Fedora  20. 

> $svn co svn://devserver/Playground Playground --username bowing
> svn: E000013: Unable to connect to a repository at URL 'svn://devserver/Playground'
> svn: E000013: Can't open file '/home/svn/Playground/format': Permission denied
>
> The svnserve is running:
>
> $systemctl status svnserve.service
> svnserve.service - Subversion protocol daemon
>    Loaded: loaded (/usr/lib/systemd/system/svnserve.service; enabled)
>    Active: active (running) since Fri 2014-09-05 00:10:29 EDT; 2min 16s ago
>   Process: 1111 ExecStart=/usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid $OPTIONS (code=exited, status=0/SUCCESS)
>  Main PID: 1129 (svnserve)
>    CGroup: /system.slice/svnserve.service
>            └─1129 /usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid -r /home/svn

One possible cause is that the repository in /home/svn is owned
different user from the from user running svnserve and the svnserve user
doesn't have OS level access to the files.  If this is the case then
either use the same user or use group permissions.

Another possible cause is that selinux prevents svnserve from accessing
any files in /home.  Put selinux into the permissive mode and the GUI
will alert you to selinux violations and provide hints on how to modify
selinux to allow the access.  Or move the repository into the location
to which selinux allows access.

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*

Re: cannot connect to svnserve locally and remotely

Posted by Philip Martin <ph...@wandisco.com>.
James <ol...@yahoo.com> writes:

> I got latest subversion setup on my latest Fedora  20. 

> $svn co svn://devserver/Playground Playground --username bowing
> svn: E000013: Unable to connect to a repository at URL 'svn://devserver/Playground'
> svn: E000013: Can't open file '/home/svn/Playground/format': Permission denied
>
> The svnserve is running:
>
> $systemctl status svnserve.service
> svnserve.service - Subversion protocol daemon
>    Loaded: loaded (/usr/lib/systemd/system/svnserve.service; enabled)
>    Active: active (running) since Fri 2014-09-05 00:10:29 EDT; 2min 16s ago
>   Process: 1111 ExecStart=/usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid $OPTIONS (code=exited, status=0/SUCCESS)
>  Main PID: 1129 (svnserve)
>    CGroup: /system.slice/svnserve.service
>            └─1129 /usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid -r /home/svn

One possible cause is that the repository in /home/svn is owned
different user from the from user running svnserve and the svnserve user
doesn't have OS level access to the files.  If this is the case then
either use the same user or use group permissions.

Another possible cause is that selinux prevents svnserve from accessing
any files in /home.  Put selinux into the permissive mode and the GUI
will alert you to selinux violations and provide hints on how to modify
selinux to allow the access.  Or move the repository into the location
to which selinux allows access.

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*

Re: cannot connect to svnserve locally and remotely

Posted by Stefan Sperling <st...@elego.de>.
On Thu, Sep 04, 2014 at 09:20:39PM -0700, James wrote:
> I got latest subversion setup on my latest Fedora  20. 
> 
> I created repository. 
> 
> I modified the svnserve.conf file and the passwd file in that repository.
> I modified the firewall to open 3690 to public for TCP.
> The svnserve.service is running. but I got E000013 error when I try to connect to it with svn protocol locally (the same machine) and remotely. The error message is this:
> 
> $svn co svn://devserver/Playground Playground --username bowing
> svn: E000013: Unable to connect to a repository at URL 'svn://devserver/Playground'
> svn: E000013: Can't open file '/home/svn/Playground/format': Permission denied
> 
> The svnserve is running:
> 
> $systemctl status svnserve.service
> svnserve.service - Subversion protocol daemon
>    Loaded: loaded (/usr/lib/systemd/system/svnserve.service; enabled)
>    Active: active (running) since Fri 2014-09-05 00:10:29 EDT; 2min 16s ago
>   Process: 1111 ExecStart=/usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid $OPTIONS (code=exited, status=0/SUCCESS)
>  Main PID: 1129 (svnserve)
>    CGroup: /system.slice/svnserve.service
>            └─1129 /usr/bin/svnserve --daemon --pid-file=/run/svnserve/svnserve.pid -r /home/svn
> 
> 
> how to diagnosis the issue? how to fix it?
> 
> Thanks,
> James

The user svnserve runs as needs read/write access to the repository.

Use chmod(1) to fix acess permissions and chown(1) to fix ownership.
Or perhaps use some SELinux tools to adjust access permissions (I don't
know which commands to use in that case).