ISPManager 5 - phpmyadmin - connect() to unix:/var/run/php-fpm.apache.sock failed

Материал из Wiki - Iphoster - the best ever hosting and support. 2005 - 2024
Перейти к:навигация, поиск

ISPManager 5 - phpmyadmin - connect() to unix:/var/run/php-fpm.apache.sock failed

500 ошибка при заходе на phpmyadmin, в логах Apache видим ошибку:

2017/01/06 10:09:19 [crit] 30398#30398: *561 connect() to unix:/var/run/php-fpm.apache.sock failed (2: No such file or directory) while connecting to upstream, client: , server: , request: "GET /phpmyadmin/ HTTP/1.1", upstream: "fastcgi://unix:/var/run/php-fpm.apache.sock:", host: ""

Правим конфиг nginx для ISPManager 5:

# vi /etc/nginx/vhosts-includes/phpmyadmin.conf
#location ~ ^/phpmyadmin/(.+\.php)$ {
#       alias /usr/share/phpMyAdmin/$1;
#       fastcgi_pass unix:/var/run/php-fpm.apache.sock;
#       fastcgi_index index.php;
#       fastcgi_param SCRIPT_FILENAME $request_filename;
#       include fastcgi_params;
#       error_page 502 = @apache;
#       error_page 404 = @apache;
#}
#location @apache {
location ~ ^/phpmyadmin/(.+\.php)$ {
       error_log /dev/null crit;
       proxy_pass http://127.0.0.1:8080;
       proxy_redirect http://127.0.0.1:8080 /;
       proxy_set_header Host $host;
       proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
       proxy_set_header X-Forwarded-Proto $scheme;
}


то есть делаем проксирование только на apache на 8080 порт