小白求指导,关于apache虚拟目录出现403Forbidden的问题。
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
小白求指导,关于apache虚拟目录出现403Forbidden的问题。
小白求指导,关于apache虚拟目录出现403Forbidden的问题。
前段时间买了一个burst vps 2#。
安装环境LAMP,设置成虚拟目录想要多绑几个域名。
在httpd-vhosts.conf里设置了两个虚拟站点。
www.kkblo.com
这个访问正常。
www.holowo.com
这个访问就提示403Forbidden,但是可以Ping通。
试过很多方法了,在本机host里绑定了测试域名也无法访问,都显示403Forbidden,即使把目录指向kkblo的目录也一样。
只有kkblo这个域名可以访问。
没有安装selinux
配置文件里的 AllowOverride All 和 Allow from all 也都配置了。
请各位高手帮忙分析下。。。。
小弟在此感激不尽……
顺便想弱弱的问一句,,burst vps有两个IP,第二个IP怎么启用啊?
前段时间买了一个burst vps 2#。
安装环境LAMP,设置成虚拟目录想要多绑几个域名。
在httpd-vhosts.conf里设置了两个虚拟站点。
www.kkblo.com
这个访问正常。
www.holowo.com
这个访问就提示403Forbidden,但是可以Ping通。
试过很多方法了,在本机host里绑定了测试域名也无法访问,都显示403Forbidden,即使把目录指向kkblo的目录也一样。
只有kkblo这个域名可以访问。
没有安装selinux
配置文件里的 AllowOverride All 和 Allow from all 也都配置了。
请各位高手帮忙分析下。。。。
小弟在此感激不尽……
顺便想弱弱的问一句,,burst vps有两个IP,第二个IP怎么启用啊?
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
补充一句,目录权限都给了777。
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
再补充一句,,今天在本地的虚拟机里又配置了一遍LAMP,本地host绑定测试域名访问虚拟机没有出现403。。。 ![:em20 :em20](./images/smilies/em20.gif)
![:em20 :em20](./images/smilies/em20.gif)
- 枫叶饭团
- 帖子: 14683
- 注册时间: 2010-06-16 1:05
- 系统: Mac OS X
- 来自: Tencent
- 联系:
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
我说我在家里也是这样子,至今我也没解决。。。换个目录就是TM的无法访问
- link_01
- 帖子: 1024
- 注册时间: 2008-11-05 13:24
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
虚拟主机的配置文本拿来看看
笔记
-------------------------------------
http://blog.163.com/wqt_1101
-------------------------------------
http://blog.163.com/wqt_1101
- qy117121
- 论坛版主
- 帖子: 50559
- 注册时间: 2007-12-14 13:40
- 系统: Winbuntu
- 来自: 志虚国乌由市
- 联系:
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
不要给777权限吧,有些程序,给了777会500错误的
应该是apache配置文件的问题吧
我用的lnmp 对apache不了解
应该是apache配置文件的问题吧
我用的lnmp 对apache不了解
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin admin@kkblo.com
ServerName www.kkblo.com
DocumentRoot "/var/www/dyzhan"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/dyzhan">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@kkblo.com
ServerName kkblo.com
DocumentRoot "/var/www/dyzhan"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/dyzhan">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@holowo.com
ServerName www.holowo.com
DocumentRoot "/var/www/gaoxiao"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/gaoxiao">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@holowo.com
ServerName holowo.com
DocumentRoot "/var/www/gaoxiao"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/gaoxiao">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
查了很多资料,配置文件没有问题。
<VirtualHost *:80>
ServerAdmin admin@kkblo.com
ServerName www.kkblo.com
DocumentRoot "/var/www/dyzhan"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/dyzhan">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@kkblo.com
ServerName kkblo.com
DocumentRoot "/var/www/dyzhan"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/dyzhan">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@holowo.com
ServerName www.holowo.com
DocumentRoot "/var/www/gaoxiao"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/gaoxiao">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
<VirtualHost *:80>
ServerAdmin admin@holowo.com
ServerName holowo.com
DocumentRoot "/var/www/gaoxiao"
DirectoryIndex index.html index.htm index.php
<Directory "/var/www/gaoxiao">
Options FollowSymLinks
AllowOverride All
Order deny,allow
allow from All
</Directory>
</VirtualHost>
查了很多资料,配置文件没有问题。
- link_01
- 帖子: 1024
- 注册时间: 2008-11-05 13:24
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
你的/var/www/gaoxiao目录是空的或者缺个autoindex ?
笔记
-------------------------------------
http://blog.163.com/wqt_1101
-------------------------------------
http://blog.163.com/wqt_1101
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
/var/www/gaoxiao
这个目录不是空的,有一套DEDE 程序。有index.php和index.html
配置文件里
DirectoryIndex index.html index.htm index.php
默认首页文件也加了。
就是头疼这个问题啊……
这个目录不是空的,有一套DEDE 程序。有index.php和index.html
配置文件里
DirectoryIndex index.html index.htm index.php
默认首页文件也加了。
就是头疼这个问题啊……
- link_01
- 帖子: 1024
- 注册时间: 2008-11-05 13:24
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
没有办法了,只能你在实际情况下,tail -f -s 2 error.log;然后一点一点的查权限和配置了。很特别的错误,只能耐心点了;
可以考虑移走gaoxiao下的网站程序、调整两个域名顺序;有可能的话,停用第一个域名,只配置一个虚拟主机测试
弄好了,告诉大家怎么解决的![:em09 :em09](./images/smilies/em09.gif)
可以考虑移走gaoxiao下的网站程序、调整两个域名顺序;有可能的话,停用第一个域名,只配置一个虚拟主机测试
![:em11 :em11](./images/smilies/em11.gif)
弄好了,告诉大家怎么解决的
![:em09 :em09](./images/smilies/em09.gif)
笔记
-------------------------------------
http://blog.163.com/wqt_1101
-------------------------------------
http://blog.163.com/wqt_1101
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
![:em06 :em06](./images/smilies/em06.gif)
谢谢各位的耐心解答。
![:em11 :em11](./images/smilies/em11.gif)
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
我真的很晕。估计burst vps每个IP只可以绑定一个域名。
我把holowo指向另一个IP,现在可以访问了……
也不出现403了。
![:em06 :em06](./images/smilies/em06.gif)
我把holowo指向另一个IP,现在可以访问了……
也不出现403了。
![:em06 :em06](./images/smilies/em06.gif)
- sleepsun
- 帖子: 25
- 注册时间: 2009-06-22 17:03
Re: 小白求指导,关于apache虚拟目录出现403Forbidden的问题。
![:em06 :em06](./images/smilies/em06.gif)
是我域名解析的时候填错IP地址了,绑到别人服务器上哩……
十分感谢诸位的帮忙。。。。