Author Topic: PHP-FPM 8.4/8.5 mbstring missing  (Read 131 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
PHP-FPM 8.4/8.5 mbstring missing
« on: August 18, 2026, 07:12:42 AM »
Hello,

I found an issue with PHP-FPM 8.4 and 8.5 on CWP Pro running AlmaLinux 8.

I have the same problem on two different VPS servers.

In PHP-FPM Selector, mbstring is enabled, but after compiling PHP 8.4/8.5 the extension is not available.

The PHP configure command also does not contain:

Code: [Select]
--enable-mbstring

Looking at the CWP mbstring script:

Code: [Select]
/usr/local/cwpsrv/htdocs/resources/conf/el8/php-fpm_selector/external_modules/8.5/mbstring.sh

https://github.com/mysterydata/md-disk/raw/main/el8-php85/mbstring.so

The build log shows:

Code: [Select]
--2026-08-18 03:52:27--  https://github.com/mysterydata/md-disk/raw/main/el8-php85/mbstring.so
HTTP request sent, awaiting response... 404 Not Found
ERROR 404: Not Found.

chmod: cannot access '/opt/alt/php-fpm85/usr/lib/php/extensions/no-debug-non-zts-20250925/mbstring.so': No such file or directory

ERROR: Missing extension file /opt/alt/php-fpm85/usr/lib/php/extensions/no-debug-non-zts-20250925/mbstring.so

PHP-FPM 8.3 on the same servers works correctly.

It looks like PHP 8.4 and 8.5 on EL8 are compiled without mbstring, and CWP then tries to install a precompiled mbstring.so, but the configured download URL no longer exists.

Could you please confirm if this is a known issue and whether the build configuration will be updated to compile mbstring directly with --enable-mbstring instead of relying on the missing external mbstring.so?

Thank you.

Offline
*
Re: PHP-FPM 8.4/8.5 mbstring missing
« Reply #1 on: August 18, 2026, 07:18:38 AM »
I also found older CWP forum threads showing mbstring build problems with PHP 8.3 on EL8, where disabling mbstring was suggested as a workaround.

The current external mbstring.so mechanism may be related to that older build issue.

Offline
*****
Re: PHP-FPM 8.4/8.5 mbstring missing
« Reply #2 on: August 18, 2026, 11:38:39 AM »
Just looked, https://github.com/mysterydata/md-disk/blob/main/el8-php83/mbstring.so is valid, but your screenshot does show wget.

Goto
Code: [Select]
/opt/alt/php-fpm85/usr/lib/php/extensions/no-debug-non-zts-20250925/
and then run:
Code: [Select]
wget https://github.com/mysterydata/md-disk/blob/main/el8-php83/mbstring.so
And it will download the missing .so file for mbstring.so

Offline
*
Re: PHP-FPM 8.4/8.5 mbstring missing
« Reply #3 on: August 18, 2026, 12:12:59 PM »
Thanks, Starburst. I tested the PHP 8.3 mbstring.so with PHP 8.5 as you suggested.

PHP 8.5 rejects it with:

Code: [Select]
Warning: PHP Startup: mbstring: Unable to initialize module

Module compiled with module API=20230831
PHP compiled with module API=20250925
These options need to match

So the PHP 8.3 mbstring.so is not compatible with PHP 8.5.

It seems PHP 8.5 needs a mbstring.so compiled specifically for API 20250925, or the PHP 8.5 build should include --enable-mbstring directly.

Offline
*****
Re: PHP-FPM 8.4/8.5 mbstring missing
« Reply #4 on: August 18, 2026, 02:33:13 PM »
I apologize, I thought you needed it for 8.3.
Yea, it wouldn't work for 8.5

Looks like a bug in PHP 8.5.
Found a post from aaPanel with the same error:
https://github.com/aaPanel/aaPanel/issues/287

Is the module installed?
dnf install php-mbstring

And then check/update your php.ini for
Quote
extension=mbstring.so

Then restart your web server (Apache or Nginx)

--

You also can try installing the PHP mbstring package, which contains mbstring.so, below is the latest stable release.

For AL9
Code: [Select]
dnf install https://dl.starburst.help/PHP/Misc/php-mbstring-8.5.9-1.module_php.8.5.el9.remi.x86_64.rpm
or for AL8:
Code: [Select]
dnf install https://dl.starburst.help/PHP/Misc/php-mbstring-8.5.9-1.module_php.8.5.el8.remi.x86_64.rpm
« Last Edit: August 18, 2026, 02:43:23 PM by Starburst »

Offline
*
Re: PHP-FPM 8.4/8.5 mbstring missing
« Reply #5 on: August 18, 2026, 03:43:34 PM »
Thanks, Starburst.

I extracted the PHP 8.5.9 mbstring.so from the Remi RPM without installing the RPM itself, copied only the module to the CWP PHP 8.5 extension directory, and created mbstring.ini.

I tested it through PHP-FPM and mbstring is now working correctly with PHP 8.5.9.

So this workaround solved the issue for me.

Hopefully this can be fixed in a future CWP update so PHP 8.4/8.5 can provide mbstring normally through the selector.