nginx 代理 tomcat 502 bad gateway
来源:互联网 发布:在计算机领域 数据是 编辑:程序博客网 时间:2024/05/22 14:53
nginx能收到80请求,但是无法转到tomcat:8080.
直接访问http://x.x.x.x:8080/project 可以访问
查看/var/log/nginx/error.log
2015/04/01 11:38:13 [crit] 2895#0: *10 connect() to 127.0.0.1:8080 failed (13: Permission denied) while connecting to upstream, client: 10.12.70.206, server: localhost:8080, request: "GET /bpp HTTP/1.1", upstream: "http://127.0.0.1:8080/app", host: "10.11.202.204"解决方案:
http://stackoverflow.com/questions/25235453/nginx-proxy-server-localhost-permission-denied
I was able to find a solution after 2 days of searching. Somehow SELinux was not permitting Nginx to proxy to my server. Running the command below fixed the issue.
-P permanent的意思
/usr/sbin/setsebool -P httpd_can_network_connect true
0 0
- nginx 代理 tomcat 502 bad gateway
- nginx 502 bad gateway
- nginx 502 Bad Gateway
- 502 Bad Gateway nginx
- nginx 502 bad gateway
- nginx 502 bad gateway
- 解决nginx 502 bad gateway
- Homestead nginx 502 Bad Gateway
- nginx页面加载不全或提示502bad gateway,nginx反向代理端口号丢失
- nginx 502 Bad Gateway 错误问题收集
- nginx 502 Bad Gateway 错误问题收集
- nginx 502 Bad Gateway 错误问题收集
- nginx 502 Bad Gateway 错误解决办法
- Nginx 502 Bad Gateway错误的解决办法
- nginx 502 Bad Gateway 错误问题收集
- flask uwsgi nginx 出现502 Bad Gateway
- 配置nginx报502 bad gateway
- nginx 502 Bad Gateway 错误问题收集
- Missing Number
- Windows Server 2003登录时不按Ctrl+Alt+Del
- 滤波器
- Linux下文件的压缩与打包
- C#调用C++编写的DLL函数各种参数传递问题
- nginx 代理 tomcat 502 bad gateway
- linux 命令のtar
- 我国的现状与前景
- 解决数据库root访问权限
- 【原创】ubuntu 添加开启启动项
- PHP版消灭星星实现算法
- 设计模式1--策略模式(the strategy design pattern)
- 关于Linux内核源码中是如何区别进程上下文和中断上下文
- Android-GridView实例(优化列表数据加载,图片圆角,LruCache优化)