`
不爱不见
  • 浏览: 274475 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

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
3
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics