- You don’t have permission to access / on this server.
当出现以上错误信息时,先更改所指向路径的访问权限(如Documents)。
- apache AH01630: client denied by server configuration
2.4的vhosts写法格式不同,需要把
Order deny,allow
Allow from all
Allow from host ip
修改为
Require all granted
Require host ip
整体格式参考如下:
<VirtualHost *:80>
ServerName localhost
DocumentRoot “/Users/sunliang/Documents/SVN-web/web”
DirectoryIndex index.html index.php
ErrorLog “/private/var/log/apache2/sites-error_log”
CustomLog “/private/var/log/apache2/sites-access_log” common
<Directory “/Users/sunliang/Documents/SVN-web/web”>
Options -Indexes +FollowSymlinks
AllowOverride All
Require all granted
</Directory>
</VirtualHost>