Hesta create to muche socket php-fpm

Hi,

I have 2 files new files in ktalog “/usr/local/hestia/data/templates/web/php-fpm/” using them wywyając ich wywalać mi one of the installed version of php. displaying an error that the socket “here address” is already occupied and you can not run for example php8.1-fpm.
How to improve the configuration so that it does not interfere?

Use %domain% as variable in the templates so it will always create a new socket…

I use as you advised me
image

The problem persists

You probally need manuly delete the existing socket file first

  1. i cleared all php sokets for these 2 configurations.
  2. i fire them initially on the default PHP-8_0 configuration.
  3. check both sites work but throw an error
  4. i switch both sites to their configurations:
    PHP-8_0_platform-uat.tpl
    PHP-8_0_platform.tpl
    One page works the other has error 500
    PHP-8.1 does not work
    Error dump
    "==> platform.openmind4zero.com.error.log <==
    [Fri Aug 18 13:46:18.631549 2023] [proxy:error] [pid 3627785] (111)Connection refused: AH02454: FCGI: attempt to connect to Unix domain socket /run/php/php8.0-fpm-platform.openmind4zero.com.sock (*:80) failed
    [Fri Aug 18 13:46:18.631631 2023] [proxy_fcgi:error] [pid 3627785] [client 95.49.14.34:0] AH01079: failed to make connection to backend: httpd-UDS

==> platform.openmind4zero.com.log <==
95.49.14.34 - - [18/Aug/2023:13:46:18 +0200] “GET / HTTP/1.0” 503 3492 “-” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/115.0.0.0 Safari/537.36"”

image

In my opinion, there is a bug somewhere in hesti related to running PHP sokets

I na pewno mam rację, Patrz:
image

You should try to create the templates with the right syntax.

PHP-8.0_platform-uat.tpl should be platform_uat-PHP-8_0.tpl
PHP-8.0_platform.tpl should be platform-PHP-8_0.tpl

Edit: I typed it wrong, it’s 8_0.tpl instead of 8.0.tpl as I wrote the first time.

In listen directive use this:
listen = /run/php/php%backend_version%-fpm-%domain%.sock

Remove the previous sockets. Assign the right templates to your sites and rebuild them.

2 Likes

Your explanation was very helpful but due to haste there are errors in it I will correct them maybe someone will find it useful.
To create a valid copy of the PHP-FPM template for HestiaCP.

Correct example:
string_string-PHP-8_0.tpl

Thank you very much for your help!
@eris @sahsanu

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.