Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

 
Reply to this topicStart new topic
> nginx - 502 Bad Gateway
raven666
post 6.06.2015, 19:39:57
Post #1





Grupa: Zarejestrowani
Postów: 11
Pomógł: 0
Dołączył: 22.09.2014

Ostrzeżenie: (0%)
-----


Witam,
Mam do was pytanie przez co może mi wyskakiwać 502 Bad Gateway ?
Teraz obecie mam frameworka cakephp tak wszystko fajnie chodzi, jedynie gdy robię pr (print_r) funkcje podobne, nginx pada i mam nginx - 502 Bad Gateway.
Czasami print_r się wyświetli ale jak już po f5 pada i jest 502 Bad Gateway

Dzięki za pomoc

error log:
  1. 2015/06/06 14:34:20 [error] 11591#0: *15 recv() failed (104: Connection reset by peer) while reading response header from upstream, client: 83.238.236.90, server: domena.pl, request: "POST /users/login HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "domena.pl", referrer: "http://domena.pl/users/login"


ngnix
  1. server {
  2. listen 80 default_server;
  3. listen [::]:80 default_server ipv6only=on;
  4.  
  5. root /www/domena.pl/htdocs/webroot;
  6. index index.php index.html index.htm;
  7.  
  8. server_name domena.pl www.domena.pl;
  9.  
  10. access_log /www/domena.pl/logs/access.log;
  11. error_log /www/domena.pl/logs/error.log;
  12.  
  13. location / {
  14. index index.php index.html index.htm;
  15. try_files $uri $uri/ /index.php?$uri&$args;
  16. }
  17.  
  18. location ~ \.php$ {
  19. try_files $uri =404;
  20. fastcgi_pass unix:/var/run/php5-fpm.sock;
  21. fastcgi_index index.php;
  22. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  23. include fastcgi_params;
  24. }
  25. }
Go to the top of the page
+Quote Post
rad11
post 7.06.2015, 13:51:53
Post #2





Grupa: Zarejestrowani
Postów: 1 270
Pomógł: 184
Dołączył: 7.10.2012
Skąd: Warszawa

Ostrzeżenie: (0%)
-----


Poczytaj moze cos znajdziesz:
https://www.google.pl/search?q=15+recv()+fa...93&ie=UTF-8
Go to the top of the page
+Quote Post
raven666
post 7.06.2015, 14:10:36
Post #3





Grupa: Zarejestrowani
Postów: 11
Pomógł: 0
Dołączył: 22.09.2014

Ostrzeżenie: (0%)
-----


No szukałem już ale jest dużo różnych przyczyn i próbowałem pare i nic z tego :/
teraz w sumie niewiem czy to wina nginxa czy cakephp 3 :/
postawiłem to samo na apache2 i jest podobny problem tylko zamiast bad gateway mam że połączenie zostało zresetowane i całość pada, dopiero po restarcie apacha straona wraca. dziwne że tylko ja mam z tym problem.
Go to the top of the page
+Quote Post
by_ikar
post 8.06.2015, 09:17:35
Post #4





Grupa: Zarejestrowani
Postów: 1 798
Pomógł: 307
Dołączył: 13.05.2009
Skąd: Gubin/Wrocław

Ostrzeżenie: (0%)
-----


Sprawdź logi php'a.
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 12.07.2025 - 19:01