本文介绍了无法打开文件"svn/repo/db/txn-current-lock":权限被拒绝的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经安装了Linux服务器,并在其上安装了Apache和SVN以及dav_svn.现在,当我尝试使用Tortoise SVN上传到https://x.x.x.x:x/svn/repo时,我会得到

I have set up a Linux Server and installed Apache and SVN and dav_svn on it. Now, when I try to upload to https://x.x.x.x:x/svn/repo with Tortoise SVN I get

Can't open file '/server/svn/repo/db/txn-current-lock': Permission denied

我已经正确设置了SSL(我可以检出,没有问题,甚至由于端口转发也可以远程访问).

I have Set up my SSL correctly (I can checkout, no problems, even remotely due to Port Forwarding).

我猜想这与Repository文件夹的Linux所有权有关,我该如何设置/命令是什么?

I'm guessing this has to do with the Linux Ownership of the Repository folders, How must I set this/ what are the commands?

推荐答案

这是一个常见问题.您几乎可以肯定会遇到权限问题.要解决此问题,请确保apache用户具有对整个存储库的读/写访问权限.为此,请对svn存储库下的所有内容分别使用chown -R apache:apache *chmod -R 664 *.

This is a common problem. You're almost certainly running into permissions issues. To solve it, make sure that the apache user has read/write access to your entire repository. To do that, chown -R apache:apache *, chmod -R 664 * for everything under your svn repository.

另外,请参见 此处 此处 你仍然被困住.

Also, see here and here if you're still stuck.

"664"字符串是权限的八进制(基数8)表示.这里有三位数字,分别代表所有者其他任何人(有时称为世界")的权限文件或目录.

The "664" string is an octal (base 8) representation of the permissions. There are three digits here, representing permissions for the owner, group, and everyone else (sometimes called "world"), respectively, for that file or directory.

请注意,每个基数8位可以用3位表示("0"为000,"7"为111).每一点都代表着什么:

Notice that each base 8 digit can be represented with 3 bits (000 for '0' through 111 for '7'). Each bit means something:

  • 第一位:读取权限
  • 第二位:写入权限
  • 第三位:执行权限

例如,文件上的764表示:

For example, 764 on a file would mean that:

  • 所有者(第一位数字)具有读/写/执行(7)权限
  • 该组(第二位数字)具有读/写(6)权限
  • 其他所有人(第三位数字)均已阅读(4)权限

希望能解决所有问题!

这篇关于无法打开文件"svn/repo/db/txn-current-lock":权限被拒绝的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-03 01:41