PHP FPM Isolated Socket- Monitoring

anas_xrt

Verified User
Joined
Aug 5, 2017
Messages
34
Location
TH
Hi everyone,

With DirectAdmin version 1.690, the new Isolated PHP-FPM mode was introduced. I find this feature very useful — it makes managing PHP per user and applying resource limits much easier.

However, I’ve run into a problem. I have two servers running with Isolated PHP-FPM enabled. On one of them, around 00:30 at midnight when DirectAdmin’s cron job executes, all my PHP-FPM isolated sockets suddenly disappear. This has happened for two nights in a row. I’m not yet certain if the DirectAdmin cron task is the cause.

I checked /var/log/messages to investigate, but so far I haven’t found any clear reason. The only way I’ve been able to quickly recover is by restarting the server, which restores the sockets in /var/run/php-fpm and brings all websites back online.

To help monitor this issue, I created a script:
👉 PHP-FPM Isolated Socket Monitor -- https://github.com/Anasxrt/PHP-FPM-Isolated-Socket-Monitor

The script is designed to alert me if sockets disappear so I can check immediately. While I’m still searching for the root cause, perhaps this script could be useful to others facing the same issue.

Documentation reference:
DirectAdmin Docs – Per-user Isolated PHP-FPM for Jailed Environments -- https://docs.directadmin.com/webser...user-isolated-php-fpm-for-jailed-environments

Has anyone else experienced this problem? Any insights would be appreciated.
 
@zEitEr I actually looked, here is detail I open ticket to DA support, still look for responses.

Hi, I have reviewed all custom templates and confirmed they are valid. On another server running AlmaLinux 9.7 with the same template, everything works without issue. In DirectAdmin, I have already set `isolate_fpm=1`. However, when I run `da build rewrite_confs` and check the user directory (e.g., `/usr/local/directadmin/data/users/abcdef), the file `nginx_php.conf` is generated as empty. This file should normally contain the template output. I have tested both custom and standard DirectAdmin templates, but the result is the same—an empty `nginx_php.conf` in the user’s template directory. While monitoring `rewrite_confs` under `/usr/local/directadmin/dataskq d2000`, I can see that `php1_select=1` is recognized by DirectAdmin.
 
Back
Top