cuber / ngx_http_google_filter_module

Nginx Module for Google Mirror
BSD 2-Clause "Simplified" License
3.35k stars 779 forks source link

经常出现如下错误:如图 #69

Closed weaming closed 8 years ago

weaming commented 8 years ago

2015-11-21 16 18 44

cuber commented 8 years ago

把 upstream www.google.com 这块删掉试试

weaming commented 8 years ago

@cuber 现在正常了,没有删掉这块代码,而是添加了一些nginx配置项,具体是哪些起作用了,我也不清楚。

cuber commented 8 years ago

Orz, 好的,如果还有问题,你可以把你的配置都贴出来

weaming commented 8 years ago
user www-data;
worker_processes 4;
pid /var/run/nginx.pid;
#daemon off;
#master_process off;

events {
    worker_connections  1024;
}

http {
    include       mime.types;
    default_type  application/octet-stream;

sendfile on;
tcp_nopush on;
tcp_nodelay on;
types_hash_max_size 2048;
gzip on;
gzip_disable "msie6";
#include /etc/nginx/conf.d/*.conf;
#include /etc/nginx/sites-enabled/*;

    keepalive_timeout  65;

    server {
        server_name gg.ruanjiadeng.com;
        listen 80;

        resolver 8.8.8.8;
        location / {
        google on;
        google_scholar on;
        }
    }

#   upstream www.google.com {
#       server 216.58.221.36:443;
#       server 216.58.221.35:443;
#       server 216.58.221.34:443;
#       server 216.58.221.33:443;
#       server 216.58.221.32:443;
#       server 216.58.221.31:443;
#   }

    server {
        listen       80  default_server;
        server_name  _;
        return       404;
    }
}
weaming commented 8 years ago

@cuber 你看看是哪些起作用了(upstream是刚刚注释的)

cuber commented 8 years ago

@weaming upstream 的 ip invalid 了我估计。如果不是特殊情况,upstream 建议关闭,不然需要定期更新