Hi,
So I've upgraded from 1.6.3 to 1.8.0, and none of my virtual hosts on my localhost are working. I am getting a 403 forbidden error on localhost/phpmyadmin - i've tried setting the folder with phpmyadmin to 777 to see if it would fix it... nope.
But far more concerning is I'm getting a bad gateway for all my virtual hosts. I backed up my virtual hosts and purged and reinstalled nginx to 1.8.0. Through my default virtual host I can access http://localhost and get the Welcome to nginx on Debian! screen - But aside from that nothing else is working
Just for clarity there was nothing wrong at all when using nginx 1.6.3 - Everything was being accessed no problems.
So my set up is nginx 1.8.0, php5-fpm 5.5.24
I have two virtual hosts - default (config is as it is out of the box) and yii2-dthfw
(my own virtual host). I have other virtuals hosts but I'd like to get one working first and then can work on the
others.
yii2-dthfw config is as follows:
server {
charset utf-8;
client_max_body_size 128M;
listen 80; ## listen for ipv4
#listen [::]:80 default_server ipv6only=on; ## listen for ipv6
server_name yii2-dthfw.dive;
root /media/Development/www/dthdesign-new/yii2/dthfw2/web;
index index.php;
access_log /media/Development/www/dthdesign-new/yii2/dthfw2/log/access.log combined;
error_log /media/Development/www/dthdesign-new/yii2/dthfw2/log/error.log warn;
location / {
# Redirect everything that isn't a real file to index.php
try_files $uri $uri/ /index.php?$args;
}
# uncomment to avoid processing of calls to non-existing stati
c files by Yii
#location ~ \.(js|css|png|jpg|gif|swf|ico|pdf|mov|fla|zip|rar)$ {
# try_files $uri =404;
#}
#error_page 404 /404.html;
location ~ \.php$ {
include fastcgi.conf;
#fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/var/run/php5-fpm.sock;
include fastcgi_params;
try_files $uri =404;
}
location ~ /\.(ht|svn|git) {
deny all;
}
}
When I access http://yii2-dthfw.dive - I just get a 502 bad gateway, or 504 bad gateway error
This is the error message I get in the above log file
2015/05/13 11:21:06 [error] 4545#0: *1 recv() failed (104: Connection reset by peer) while reading response header from upstream, client: 127.0.0.1, server: yii2-dthfw.dive, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "yii2-dthfw.dive"
php5-fpm log is empty and /var/log/nginx/error.log indicates nothing:
So I've upgraded from 1.6.3 to 1.8.0, and none of my virtual hosts on my localhost are working. I am getting a 403 forbidden error on localhost/phpmyadmin - i've tried setting the folder with phpmyadmin to 777 to see if it would fix it... nope.
But far more concerning is I'm getting a bad gateway for all my virtual hosts. I backed up my virtual hosts and purged and reinstalled nginx to 1.8.0. Through my default virtual host I can access http://localhost and get the Welcome to nginx on Debian! screen - But aside from that nothing else is working
Just for clarity there was nothing wrong at all when using nginx 1.6.3 - Everything was being accessed no problems.
So my set up is nginx 1.8.0, php5-fpm 5.5.24
I have two virtual hosts - default (config is as it is out of the box) and yii2-dthfw
(my own virtual host). I have other virtuals hosts but I'd like to get one working first and then can work on the
others.
yii2-dthfw config is as follows:
server {
charset utf-8;
client_max_body_size 128M;
listen 80; ## listen for ipv4
#listen [::]:80 default_server ipv6only=on; ## listen for ipv6
server_name yii2-dthfw.dive;
root /media/Development/www/dthdesign-new/yii2/dthfw2/web;
index index.php;
access_log /media/Development/www/dthdesign-new/yii2/dthfw2/log/access.log combined;
error_log /media/Development/www/dthdesign-new/yii2/dthfw2/log/error.log warn;
location / {
# Redirect everything that isn't a real file to index.php
try_files $uri $uri/ /index.php?$args;
}
# uncomment to avoid processing of calls to non-existing stati
c files by Yii
#location ~ \.(js|css|png|jpg|gif|swf|ico|pdf|mov|fla|zip|rar)$ {
# try_files $uri =404;
#}
#error_page 404 /404.html;
location ~ \.php$ {
include fastcgi.conf;
#fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/var/run/php5-fpm.sock;
include fastcgi_params;
try_files $uri =404;
}
location ~ /\.(ht|svn|git) {
deny all;
}
}
When I access http://yii2-dthfw.dive - I just get a 502 bad gateway, or 504 bad gateway error
This is the error message I get in the above log file
2015/05/13 11:21:06 [error] 4545#0: *1 recv() failed (104: Connection reset by peer) while reading response header from upstream, client: 127.0.0.1, server: yii2-dthfw.dive, request: "GET / HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "yii2-dthfw.dive"
php5-fpm log is empty and /var/log/nginx/error.log indicates nothing: