svn搭建完毕出现500错误原因之一

出现500的原因是由于配置的时候少生成了授权文件,
通过锁定服务器的日志文件 tail -f /var/log/apache2/error.log 得到的错误日志如下:
[Sat Aug 25 09:16:33 2012] [error] [client 192.168.1.101] Could not fetch resource information. [500, #0]
[Sat Aug 25 09:16:33 2012] [error] [client 192.168.1.101] Could not open the requested SVN filesystem [500, #2]
[Sat Aug 25 09:16:33 2012] [error] [client 192.168.1.101] Could not open the requested SVN filesystem [500, #2]
[Sat Aug 25 09:20:07 2012] [notice] caught SIGTERM, shutting down
[Sat Aug 25 09:20:08 2012] [notice] Apache/2.2.16 (Ubuntu) DAV/2 SVN/1.6.12 configured -- resuming normal operations
[Sat Aug 25 09:49:34 2012] [notice] caught SIGTERM, shutting down
[Sat Aug 25 09:49:36 2012] [notice] Apache/2.2.16 (Ubuntu) DAV/2 SVN/1.6.12 configured -- resuming normal operations
[Sat Aug 25 10:05:05 2012] [notice] caught SIGTERM, shutting down
[Sat Aug 25 10:05:06 2012] [notice] Apache/2.2.16 (Ubuntu) DAV/2 SVN/1.6.12 configured -- resuming normal operations
[Sat Aug 25 10:17:37 2012] [error] [client 192.168.1.101] (2)No such file or directory: Could not open password file: /etc/apache2/dav_svn.passwd
解决方法是生成对应的文件:
现在通过命令设置SVN账户:
Shell代码 收藏代码

1. sudo htpasswd -c /etc/apache2/dav_svn.passwd <username>

sudo htpasswd -c /etc/apache2/dav_svn.passwd <username>


这里用到参数-c,是因为/etc/apache2/dav_svn.passwd文件不存在,如果文件存在,则无需该参数!否则,将覆盖掉原有密码文件!
形如:
引用
sudo htpasswd -c /etc/apache2/dav_svn.passwd snowolf
New password:
Re-type new password:
Updating password for user snowolf

可以追加多个账户!
引用
sudo htpasswd /etc/apache2/dav_svn.passwd zlex
New password:
Re-type new password:
Updating password for user zlex
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值