VPS侦探论坛

 找回密码
 注册
查看: 6700|回复: 3

求助:运行/root/vhost.sh 添加域名,不能正常访问,添加过程中报错

[复制链接]
发表于 2012-4-14 09:49:33 | 显示全部楼层 |阅读模式

求助:运行/root/vhost.sh 添加域名,不能正常访问,添加过程中报错

运行/root/vhost.sh 添加域名,aaa.com
提示:

nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful

Restart Nginx......
Restart Apache......
Warning: DocumentRoot [/usr/local/apache/aaa] does not exist

查看了一下,/usr/local/nginx/conf/vhost/域名.conf,也存在

安装过程中输入域名所在目录环节,我输入的不是aaa.com而是aaa,就是让它存放在/home/wwwroot/aaa/而不是/home/wwwroot/aaa.com/中。

/home/wwwroot/中也没有aaa目录,手动创建,我的解析是没问题的,打开主页,提示:
Internet Explorer 无法显示该网页
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
 楼主| 发表于 2012-4-14 17:26:32 | 显示全部楼层

补充说明



打开网页:

Access forbidden!
You don't have permission to access the requested directory. There is either no index document or the directory is read-protected.

If you think this is a server error, please contact the webmaster.

Error 403
www.aaa.com
Sat Apr 14 17:24:07 2012
Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8o PHP/5.2.17p1
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
发表于 2012-4-14 17:31:50 | 显示全部楼层

vhost.sh添加时的目录需要输入全路径

不行就自己创建目录,然后修改配置文件中的目录
/usr/local/nginx/conf/vhost/域名.conf
/usr/local/apache/conf/vhost/域名.conf
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
 楼主| 发表于 2012-4-14 21:36:49 | 显示全部楼层

非常感谢,已经改好了,情况依旧,是不是需要重启一下什么的,如何操作啊?




非常感谢,已经改好了,情况依旧,是不是需要重启一下什么的,如何操作啊?
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2024-9-22 19:30 , Processed in 0.026284 second(s), 17 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表