Comments (26)
是不是 nginx 进程没重启?
from ngx_http_google_filter_module.
才发邮件给你,还以为你没看到,如何启动?
from ngx_http_google_filter_module.
@cuber 发给你的邮件附件里边有Nginx配置文件,你看看有没有问题。
from ngx_http_google_filter_module.
看你的配置,应该是装了某个发行版,一般来说这样子就可以重启了
sudo /etc/init.d/nginx stop
sudo /etc/init.d/nginx start
from ngx_http_google_filter_module.
login as: root
[email protected]'s password:
Last login: Tue Aug 11 10:58:34 2015 from 117.95.165.65
[root@default ~]# sudo /etc/init.d/nginx stop
sudo: /etc/init.d/nginx: command not found
[root@default ~]# sudo /etc/init.d/nginx start
sudo: /etc/init.d/nginx: command not found
[root@default ~]#
怎么提示找不到?
不可能是发行版,下载的地址都是说明里上边一部分的过程
from ngx_http_google_filter_module.
from ngx_http_google_filter_module.
你还是把你的环境,是编译安装的nginx还是其他,说清楚吧
from ngx_http_google_filter_module.
@xavierskip 用的是这个页面的最简安装那个步骤的内容,没用下边的发行版:https://github.com/cuber/ngx_http_google_filter_module/blob/master/README.zh-CN.md
你怎么看?
from ngx_http_google_filter_module.
建议使用 which nginx ,确认下 nginx 在哪里,然后在使用 重启命令呗。
from ngx_http_google_filter_module.
@wenson 让你见笑了,Linux命令我一点都不了解,都是按照别人的步骤来的,这些真的不懂。
[root@default ~]# which nginx
/usr/bin/which: no nginx in (/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)
难道要我交出端口和密码?!
from ngx_http_google_filter_module.
第一步:
查看 nginx是否正常启动?
命令:ps axu| grep nginx
如果没有启动建议可是使用find 命令 找下 nginx 在哪里
命令:find / -name nginx
然后尝试重启看看?
第二步:
查看配置文件是否正常?
建议贴出来 瞧瞧
from ngx_http_google_filter_module.
@wenson 下边是运行命令的结果:
[root@default ~]# ps axu| grep nginx
root 18564 0.0 0.5 5108 644 ? Ss 10:05 0:00 nginx: master process /opt/nginx-1.7.8/sbin/nginx
nobody 18565 0.0 1.1 5244 1288 ? S 10:05 0:00 nginx: worker process
root 18790 0.0 0.4 2280 556 pts/0 S+ 23:25 0:00 grep nginx
[root@default ~]# find / -name nginx
/root/nginx-1.7.8/objs/nginx
/opt/nginx-1.7.8/sbin/nginx
配置文件待会邮给你,麻烦看一下。
from ngx_http_google_filter_module.
@wenson 额,你的主页好像没你的邮箱,我发出来吧
#user nobody;
worker_processes 1;
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/nginx.pid;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#access_log logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
server {
listen 80;
server_name jingwei.pub;
resolver 8.8.8.8;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
google on;
google_scholar on;
google_language "zh-CN";
google_robots_allow on;
google_ssl_off "www.google.com";
}
#error_page 404 /404.html;
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php$ {
# proxy_pass http://127.0.0.1;
#}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php$ {
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
# another virtual host using mix of IP-, name-, and port-based configuration
#
#server {
# listen 8000;
# listen somename:8080;
# server_name somename alias another.alias;
# location / {
# root html;
# index index.html index.htm;
# }
#}
# HTTPS server
#
#server {
# listen 443 ssl;
# server_name localhost;
# ssl_certificate cert.pem;
# ssl_certificate_key cert.key;
# ssl_session_cache shared:SSL:1m;
# ssl_session_timeout 5m;
# ssl_ciphers HIGH:!aNULL:!MD5;
# ssl_prefer_server_ciphers on;
# location / {
# root html;
# index index.html index.htm;
# }
#}
}
from ngx_http_google_filter_module.
@zhongjingwei
1、 /opt/nginx-1.7.8/sbin/nginx stop
2、 /opt/nginx-1.7.8/sbin/nginx start
重启下web server 呗。
from ngx_http_google_filter_module.
[root@default ~]# /opt/nginx-1.7.8/sbin/nginx stop
nginx: invalid option: "stop"
[root@default ~]# /opt/nginx-1.7.8/sbin/nginx start
nginx: invalid option: "start"
貌似还是不行
from ngx_http_google_filter_module.
试试 这个 /opt/nginx-1.7.8/sbin/nginx -s reload
from ngx_http_google_filter_module.
@wenson 哈哈OK了,不知道是那一步产生了效果,你知道吗?好像就是这条命令/opt/nginx-1.7.8/sbin/nginx -s reload ,这是什么意思,顺便学习一下
from ngx_http_google_filter_module.
done.
改密码吧
from ngx_http_google_filter_module.
重启 nginx 而已
参考资料:
http://blog.chinaunix.net/uid-29791971-id-4702007.html
from ngx_http_google_filter_module.
@wenson 我觉得这个速度不够快,显然没我的shadowsocks快,有没有什么办法优化一下?
from ngx_http_google_filter_module.
@wenson 这是网址:jingwei.pub
你来体验一下速度,看看还能不能优化
from ngx_http_google_filter_module.
@wenson 我又重做了一边,现在貌似又不行了,我输入/opt/nginx-1.7.8/sbin/nginx -s reload ,返回的结果是:
[root@default ~]# /opt/nginx-1.7.8/sbin/nginx -s reload
nginx: [emerg] directive "resolver" is not terminated by ";" in /opt/nginx-1.7.8/conf/nginx.conf:43
这样正确吗?
from ngx_http_google_filter_module.
@wenson 好吧,我看懂了,是我太大意,少了一个;
from ngx_http_google_filter_module.
小小意见,这样写 配置文件不太干净,有空研究下 vhosts吧。
参考资料:http://tabalt.net/blog/nginx-virtual-host/
from ngx_http_google_filter_module.
@wenson 好像是我的vps太渣了,后来我又在DigitalOcean上搭建了一下,几乎搜索结果都是秒开,就是心疼钱
from ngx_http_google_filter_module.
很高兴你的问题解决了。
btw. 自从出了国际氮气瓶,上海电信根本无法愉快的玩耍了...
from ngx_http_google_filter_module.
Related Issues (20)
- 建立谷歌学术镜像 HOT 1
- 能不能一台服务器同时代理谷歌和谷歌学术 HOT 1
- google登录 HOT 2
- error HOT 1
- error
- nginx core dump HOT 4
- unknown directive "google" HOT 6
- Tag a release
- 请更新zlib源
- unknown directive "goole" in /etc/nginx/conf/nginx.conf:44 HOT 10
- demo网站外无法访问 HOT 1
- 撸了一个简易的一键脚本 HOT 2
- GitLab
- http://xx.xx.xx.xx/?gws_rd=cr,ssl无法代理 HOT 2
- Could you update this module to support nginx 1.18 HOT 1
- 能不能请教map反代 HOT 1
- 有没有高手能用iis urlrewrite成功gg反代的
- 我们的系统检测到您的计算机网络中存在异常流量。此网页用于确认这些请求是由您而不是自动程序发出的 HOT 1
- Hi, Can this module support gmail?
- What is up with demo site?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ngx_http_google_filter_module.