nginx php-fpm
Bila anda mengalami masalah yang sama, belum tentu solusinya sama, jadi ada baiknya selalu melihat log error nginx sebelumnya, pada kasus yang saya alami error tersebut karena php-fpm belum dijalankan, kemarin saya reboot server tetapi lupa menjalankan service php-fpm berikut ini log errornya

2013/04/02 07:08:32 [error] 1172#0: *15 connect() failed (111: Connection refused) while connecting to upstream, client: 74.196.26.53, server: lirikkaro.com, request: "GET /manager/html HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "118.xxx.xxx.119"
2013/04/02 07:08:32 [error] 1172#0: *15 open() "/usr/share/nginx/html/50x.html" failed (2: No such file or directory), client: 74.196.26.53, server: lirikkaro.com, request: "GET /manager/html HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "118.xxx.xxx.119"
2013/04/02 08:16:56 [error] 1172#0: *17 connect() failed (111: Connection refused) while connecting to upstream, client: 36.70.24.179, server: lirikkaro.com, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "118.xxx.xxx.119"
2013/04/02 08:16:56 [error] 1172#0: *17 open() "/usr/share/nginx/html/50x.html" failed (2: No such file or directory), client: 36.70.24.179, server: lirikkaro.com, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "118.xxx.xxx.119"

118.xxx.xxx.119 adalah IP server yang saya gunakan, sengaja dihilangkan sebagian untuk menjaga privasi. Cara untuk mengatasinya adalah dengan menjalankan service php-fpm

su -c "service php-fpm start"

agar kejadian yang sama tidak terulang kembali, maka aktifkan php-fpm otomatis setiap system reboot dengan cara

su -c "chkconfig php-fpm on"

Leave a comment

Your email address will not be published. Required fields are marked *