系统版本:
0 1 |
[root@Centos6 /]# cat /etc/redhat-release CentOS release 6.6 (Final) |
获取IP:
0 1 2 3 4 5 6 |
[root@Centos6 /]# dig www.google.com.hk +short 172.217.1.35 [root@Centos6 /]# dig www.google.com.hk +short 216.58.216.131 [root@Centos6 /]# dig www.google.com.hk +short 216.58.216.67 [root@hk /]# dig www.google.com.hk +short |
拓展版本:
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
[root@Centos6 conf]# cat ./nginx.conf worker_processes 1; events { worker_connections 1024; } http { include mime.types; default_type application/octet-stream; sendfile on; keepalive_timeout 65; upstream www.google.com { server 216.58.193.67:443; server 216.58.193.68:443; server 216.58.199.99:443; server 216.58.216.131:443; server 216.58.193.163:443; server 216.58.219.3:443; server 216.58.216.3:443; server 172.217.1.36:443; server 172.217.1.35:443; server 173.194.38.211:443; server 173.194.72.199:443; server 173.194.38.212:443; server 173.194.38.210:443; server 173.194.38.208:443; server 64.233.187.199:443; server 64.233.189.199:443; server 74.125.203.199:443; server 74.125.23.199:443; } gzip on; gzip_min_length 1k; gzip_buffers 4 16k; gzip_http_version 1.1; gzip_comp_level 9; gzip_types text/plain application/javascript text/css application/xml; gzip_vary on; server { listen 443; server_name note.t4x.org; resolver 8.8.8.8; ssl on; ssl_certificate XXX.crt; ssl_certificate_key XXX.key; location / { proxy_pass https://www.google.com; google on; google_scholar on; google_language "en"; root /web/site/google; index index.php index.html index.htm; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_headers_hash_max_size 51200; proxy_headers_hash_bucket_size 6400; } } } |
参考文档:https://note.t4x.org/system/ngx-http-google-filter-module/
参考文档:https://note.t4x.org/error/could-not-build-optimal-proxy-headers-hash/
获取IP地址:http://tool.chinaz.com/dns/
获取IP地址:http://tool.chinaz.com/nslookup/SourceByrd's Weblog-https://note.t4x.org/system/nginx-google-upstream/
SourceByrd's Weblog-https://note.t4x.org/system/nginx-google-upstream/
申明:除非注明Byrd's Blog内容均为原创,未经许可禁止转载!详情请阅读版权申明!