wxforex 发表于 2011-4-28 16:59:17

lnmpa的泛解析也不生效....(解决)

在nginx设置里 添加了*.abc.com   可一浏览就跳到了默认页面上了

[ 本帖最后由 wxforex 于 2011-4-29 12:22 编辑 ]

wxforex 发表于 2011-4-28 17:01:59

从新添加了次网站
还是不行

[ 本帖最后由 wxforex 于 2011-4-28 17:06 编辑 ]

dianso 发表于 2011-4-28 19:46:12

我的也是这个问题,军哥帮忙解决下啊!

licess 发表于 2011-4-28 21:05:20

贴配置文件

wxforex 发表于 2011-4-28 21:15:37


ServerAdmin webmaster@example.com
php_admin_value open_basedir "/home/wwwroot/www.527togo.com:/tmp/:/var/tmp/:/proc/"
DocumentRoot "/home/wwwroot/www.527togo.com"
ServerName *.527togo.com
#ServerAlias*.527togo.com
#ErrorLog "logs/-error_log"
#CustomLog "logs/-access_log" common

=====================下面是nginx的================
server
        {
                listen       80;
                server_name *.527togo.com;
                index index.html index.htm index.php default.html default.htm default.php;
                root/home/wwwroot/www.527togo.com;

                location / {
                        try_files $uri @apache;
                        }

                location @apache {
                        internal;
                        proxy_pass http://127.0.0.1:88;
                        include proxy.conf;
                        }

                location ~ .*\.(php|php5)?$
                        {
                                proxy_pass http://127.0.0.1:88;
                                include proxy.conf;
                        }

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

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

                access_log off;
        }

dianso 发表于 2011-4-28 21:16:11

server
        {
                listen       80;
                server_name 014.cc *.014.cc;
                index index.html index.htm index.php default.html default.htm default.php;
                root/home/wwwroot/014.cc;

                location / {
                        try_files $uri @apache;
                        }

                location @apache {
                        internal;
                        proxy_pass http://127.0.0.1:88;
                        include proxy.conf;
                        }

                location ~ .*\.(php|php5)?$
                        {
                                proxy_pass http://127.0.0.1:88;
                                include proxy.conf;
                        }

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

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

                log_format014.cc'$remote_addr - $remote_user [$time_local] $request '
             '$status $body_bytes_sent $http_referer '
             '$http_user_agent $http_x_forwarded_for';
                access_log/home/wwwlogs/014.cc.log014.cc;
        }



给014.cc添加了个*.014.cc

然后单独添加其他子域名的时候打开的还是014.cc


server
        {
                listen       80;
                server_name g.014.cc;
                index index.html index.htm index.php default.html default.htm default.php;
                root/home/wwwroot/014.cc/g/;

                location / {
                        try_files $uri @apache;
                        }

                location @apache {
                        internal;
                        proxy_pass http://127.0.0.1:88;
                        include proxy.conf;
                        }

                location ~ .*\.(php|php5)?$
                        {
                                proxy_pass http://127.0.0.1:88;
                                include proxy.conf;
                        }

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

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

                log_formatg.014.cc'$remote_addr - $remote_user [$time_local] $request '
             '$status $body_bytes_sent $http_referer '
             '$http_user_agent $http_x_forwarded_for';
                access_log/home/wwwlogs/g.014.cc.logg.014.cc;
        }

licess 发表于 2011-4-29 09:05:16

回复 5# 的帖子

ServerName 换成www.abc.com
写成ServerAlias*.527togo.com试试

dianso 发表于 2011-4-29 11:18:43

还是不行。。。。。。。。。

wxforex 发表于 2011-4-29 12:21:06

成了 谢谢哈
n的设置里
server_name www.527togo.com *.527togo.com;

a的设置里
ServerName www.527togo.com
ServerAlias*.527togo.com

dianso 发表于 2011-4-29 21:30:21

我的还是不行,按你的这样设置了
页: [1]
查看完整版本: lnmpa的泛解析也不生效....(解决)