syewcom 发表于 2012-3-24 07:59:24

绑定域名不成功是什么原因??还有VPS重启后网站就打不开了是什么原因?

# /root/vhost.sh
=========================================================================
Add Virtual Host for LNMP V0.8,Written by Licess
=========================================================================
LNMP is a tool to auto-compile & install Nginx+MySQL+PHP on Linux
This script is a tool to add virtual host for nginx
For more information please visit http://www.lnmp.org/


=========================================================================
Please input domain:
(Default domain: www.lnmp.org):www.yunxianren.com
===========================
www.yunxianren.com is exist!
===========================
Do you want to add more domain name? (y/n)
y
Type domainname,example(bbs.vpser.net forums.vpser.net luntan.vpser.net):
yunxianren.com
===========================
domain list=yunxianren.com
===========================
Please input the directory for the domain:www.yunxianren.com :
(Default directory: /home/wwwroot/www.yunxianren.com):
===========================
Virtual Host Directory=/home/wwwroot/www.yunxianren.com
===========================
===========================
Allow Rewrite rule? (y/n)
===========================
n
===========================
You choose rewrite=none
===========================
===========================
Allow access_log? (y/n)
===========================
n


Press any key to start create virtul host...
Create Virtul Host directory......
set permissions of Virtual Host directory......
You select the exist rewrite rule:/usr/local/nginx/conf/none.conf
Test Nginx configure file......
nginx: invalid number of arguments in "include" directive in /usr/local/nginx/conf/vhost/=========================================================================.conf:8
nginx: configuration file /usr/local/nginx/conf/nginx.conf test failed


Restart Nginx......
nginx: invalid number of arguments in "include" directive in /usr/local/nginx/conf/vhost/=========================================================================.conf:8
=========================================================================
Add Virtual Host for LNMP V0.8,Written by Licess
=========================================================================
For more information please visit http://www.lnmp.org/


Your domain:www.yunxianren.com
Directory of www.yunxianren.com:/home/wwwroot/www.yunxianren.com


=========================================================================
#

[ 本帖最后由 syewcom 于 2012-3-24 08:56 编辑 ]

licess 发表于 2012-3-24 08:22:48

给出的信息不完整,但是可以看出配置文件肯定有错误信息

syewcom 发表于 2012-3-24 08:51:18

我不太懂,看不懂是什么问题


server
        {
                listen       80;
                server_name www.yunxianren.com yunxianren.com;
                index index.html index.htm index.php default.html default.htm default.php;
                root/home/wwwroot/www.yunxianren.com;

                include none.conf;
                location ~ .*\.(php|php5)?$
                        {
                                fastcgi_passunix:/tmp/php-cgi.sock;
                                fastcgi_index index.php;
                                include fcgi.conf;
                        }

                location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
                        {
                                expires      30d;
                        }

                location ~ .*\.(js|css)?$
                        {
                                expires      12h;
                        }

                access_log off;
        }

syewcom 发表于 2012-3-24 08:51:40

这个配置文件不是自动生成的吗?怎么会有错呢

licess 发表于 2012-3-24 11:02:45

/usr/local/nginx/sbin/nginx -t 发错误信息
页: [1]
查看完整版本: 绑定域名不成功是什么原因??还有VPS重启后网站就打不开了是什么原因?