Subversion (SVN) Propfind 405 错误

发布于 2024-08-17 04:45:06 字数 958 浏览 7 评论 0原文

我是 Subversion 的新手,有人告诉我这是自切片面包以来最好的东西。我尝试过谷歌,但我只是对错误的地方一无所知,并尝试了多种不同的建议。我收到以下错误。

位置信息指定不正确。

svn: Propfind of '/svn': 405 不允许使用方法 (http://IPADDRESS),IPADDRESS 为 IP我的服务器。

当我尝试通过 Zend Studio 登录时,我收到此消息。我使用以下内容尝试登录:

URL: http://IPADDRESS/svn/
用户名:fakeuser
密码:fakepassword

我认为问题出在该文件周围,因为错误“位置信息指定不正确”。该文件包含在 httpd.conf 文件中。我已经重新启动了 Apache,并且重新启动 Apache 时没有出现错误。

<Location /project1>
   DAV svn
   SVNPath /home/jhughes/project1
   AuthzSVNAccessFile /home/jhughes/.svn-policy-file
   AuthName "SVN Repositories"
   AuthType Basic
   AuthUserFile /home/jhughes/.svn-auth-file
   Satisfy Any
   Require valid-user
</Location>

我花了几个小时在这上面但无法得到它。

我没有使用代理服务器。我正在使用服务器的 IP 地址,因为我的服务器上有多个域,并且认为这可能是一个问题。

I am brand new to Subversion and have been told that this is the best thing since sliced bread. I have tried Google, and I am just drawing blanks on what is wrong and have tried multiple different suggestions. I get the following error.

The Location information has been specified incorrectly.

svn: Propfind of '/svn': 405 Method not allowed (http://IPADDRESS) with IPADDRESS being the IP of my server.

I get this when I try to log in through Zend Studio. I use the following to try to login:

URL: http://IPADDRESS/svn/
Username: fakeuser
Password: fakepassword

I believe that the issue is around this file because of the error "Location Information has been specified incorrectly". This file is included in the httpd.conf file. I have restarted Apache and there are not errors when restarting Apache.

<Location /project1>
   DAV svn
   SVNPath /home/jhughes/project1
   AuthzSVNAccessFile /home/jhughes/.svn-policy-file
   AuthName "SVN Repositories"
   AuthType Basic
   AuthUserFile /home/jhughes/.svn-auth-file
   Satisfy Any
   Require valid-user
</Location>

I have spent a few hours on this and cannot get it.

I am not using a proxy server. I am using the IP address of the server, because I have multiple domains on the server and thought this may be an issue.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

我的黑色迷你裙 2024-08-24 04:45:06

我认为你的网址有部分责任 - 尝试更多类似

http://username:password @IPADDRESS/svn/project1/

I think your URL is partly to blame - try something more along the lines of

http://username:password@IPADDRESS/svn/project1/

末骤雨初歇 2024-08-24 04:45:06

这可能更多是服务器故障的问题,但这是我的看法:

问题 1. 位置需要是“/project1”而不仅仅是“project1”...这可能是位置错误的根源。您可以在 Apache 的日志中查找类似的内容(可能是 /etc/httpd/logs/error_log,但这取决于您的操作系统和设置)。

可能的问题:我从未在用户文件夹中看到过 SVN 存储库设置。您很可能需要查看 SVN 本身的设置并确保 Apache 中的 SVNPath 与其匹配。通常它类似于 /svn。同样,它可能是这样设置的,只是我从未见过的东西。

你所听到的都是真的。 SVN 很棒,但通过 DAV 设置它通常不适合胆小的人。 Zend Studio是否支持通过SSH连接SVN?这样就容易多了。

This is probably more a question for Server Fault, but here's my take on it:

Problem 1. Location needs to be "/project1" not just "project1" ... that's probably the source of your Location error. You can look in Apache's logs for things like this (possibly /etc/httpd/logs/error_log, but it depends on your OS and settings).

Possible problem: I've never seen an SVN repository setup in a user folder. Most likely you need to look at the settings for SVN itself and make sure the SVNPath in Apache matches it. Usually its something like /svn. Again it might be setup that way, just something I've never seen.

What you've been told is true. SVN rocks, though setting it up through DAV is not usually for the faint of heart. Does Zend Studio support connecting to SVN through SSH? That's far easier to get going.

强者自强 2024-08-24 04:45:06

我认为您希望将配置放入 块而不是 块中。我最初将配置放在 块中,并且遇到了无尽的 PROPFIND 错误,直到我将其移动到 块中。

这是我的工作配置(不适用于 SVN,只是一个独立的 WebDAV 服务器):

Alias /webdav /webdav
DavLockDB "/etc/apache2/var/DavLock"
<Directory /webdav>
    Allow from all
    DAV On
    Require all granted
    Options Indexes
    AuthType Basic
    AuthName "webdav"
    AuthUserFile /etc/apache2/webdav.passwd
    Require valid-user
</Directory>

确保 webdav 目录已 chown 给您的 Web 用户(例如 www -数据)。

I think you want to put your configuration inside a <Directory> block rather than a <Location> block. I originally had my configuration inside a <Location> block and was getting endless PROPFIND errors until I moved it into a <Directory> block.

Here's my working configuration (not for SVN, just a stand-alone WebDAV server):

Alias /webdav /webdav
DavLockDB "/etc/apache2/var/DavLock"
<Directory /webdav>
    Allow from all
    DAV On
    Require all granted
    Options Indexes
    AuthType Basic
    AuthName "webdav"
    AuthUserFile /etc/apache2/webdav.passwd
    Require valid-user
</Directory>

Make sure the webdav directory is chowned to your web user (e.g. www-data).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文