Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> NginX + PHP + FastCGI
mdco
post
Post #1





Grupa: Zarejestrowani
Postów: 324
Pomógł: 5
Dołączył: 14.12.2004

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


Czy ktos z Was instalował Nginx?
Zrobiłem według instrukcji http://eriz.pcinside.pl/weblog/alternatywa...ubuntu-113.html
Pewnie cos zwaliłem (IMG:http://forum.php.pl/style_emoticons/default/smile.gif) .
Serwer działa, natomiast z phpem sa problemy, tzn przy wywolaniu pliku php dostaje Bład 502.
http://r2f.com.pl/1.php

Wiecie jaka moze byc przyczyna?
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi
nagle.pl
post
Post #2





Grupa: Zarejestrowani
Postów: 2
Pomógł: 0
Dołączył: 6.01.2008

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


hmm masz dostęp do shella?
ps aux
i ewentualnie netstat -l
Nigdy nie konfigurowałem nginx'a z fcgi, więc mogę się mylic. Mozesz miec tez namieszane w skrypcie:
Cytat
  1. #!/bin/bash
  2. ## ABSOLUTE path to the PHP binary
  3. PHPFCGI="/usr/local/bin/php"
  4. ## tcp-port to bind on
  5. FCGIPORT="1234"
  6. ## IP to bind on
  7. FCGIADDR="127.0.0.1"
  8. ## number of PHP children to spawn
  9. PHP_FCGI_CHILDREN=5
  10. ## number of request before php-process will be restarted
  11. PHP_FCGI_MAX_REQUESTS=1000
  12. # allowed environment variables sperated by spaces
  13. ALLOWED_ENV="ORACLE_HOME PATH USER"
  14. ## if this script is run as root switch to the following user
  15. USERID=www
  16. ################## no config below this line
  17. if test x$PHP_FCGI_CHILDREN = x; then
  18. PHP_FCGI_CHILDREN=5
  19. fi
  20. ALLOWED_ENV="$ALLOWED_ENV PHP_FCGI_CHILDREN"
  21. ALLOWED_ENV="$ALLOWED_ENV PHP_FCGI_MAX_REQUESTS"
  22. ALLOWED_ENV="$ALLOWED_ENV FCGI_WEB_SERVER_ADDRS"
  23. if test x$UID = x0; then
  24. EX="/bin/su -m -c \"$PHPFCGI -q -b $FCGIADDR:$FCGIPORT\" $USERID"
  25. else
  26. EX="$PHPFCGI -b $FCGIADDR:$FCGIPORT"
  27. fi
  28. echo $EX
  29. # copy the allowed environment variables
  30. E=
  31. for i in $ALLOWED_ENV; do
  32. E="$E $i=${!i}"
  33. done
  34. # clean environment and set up a new one
  35. nohup env - $E sh -c "$EX" &> /dev/null &
Go to the top of the page
+Quote Post

Posty w temacie


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 Aktualny czas: 15.10.2025 - 21:19