PHP Warning: PHP Startup: Unable to load dynamic library 'intl'

Started by Starburst, June 28, 2025, 11:40:09 PM

Previous topic - Next topic

Starburst

You know it's usually bad when I ask a question.

Getting the error:
QuotePHP Warning:  PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl: cannot open shared object file: No such file or directory), /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

Intl is now built-in to PHP, tried building PHP even without the extension, and am still getting the error, which is weird.

Anyone have any thoughts?

@cyberspace

overseer

This is for the built-in CWP PHP (7.2 that is labeled 7.1)?
I have these files for intl (different dating than the version yours is calling):
/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20170718/intl.so
/usr/local/src/intl-3.0.0/.libs/intl.so
/usr/local/src/intl-3.0.0/modules/intl.so

Starburst

This is on AL9, which I believe has CWP PHP 7.4.
But the paths show 7.1.

Only location that had the intl.so in was:
Quote/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20170718/intl.so

Copied it over to:
/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902

Both:
Quote/usr/local/src/intl-3.0.0/.libs/
/usr/local/src/intl-3.0.0/modules/
where empty.

Trying to rebuild PHP now.

Only server to be having this problem.
And it only showed when updating RoundCube to 1.5.11.

You run a PHP module check with php -m, and it lists intl.
php -v doesn't show any errors either.


Starburst

When you run php -m, it shows the module installed, as does dnf.  ???

overseer

And for sure you're testing the CWP PHP (7.2 or 7.4), not your default CLI PHP (mine is 8.2)?
[root@srv]# /usr/local/cwp/php71/bin/php --version
PHP 7.2.30 (cli) (built: Apr 29 2020 02:29:42) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    with the ionCube PHP Loader + ionCube24 v13.0.2, Copyright (c) 2002-2023, by ionCube Ltd.
[root@srv]# /usr/local/cwp/php71/bin/php -m
[PHP Modules]
...
[b]intl[/b]
ionCube Loader
...

[Zend Modules]
the ionCube PHP Loader + ionCube24

Starburst

# /usr/local/cwp/php71/bin/php --version

QuotePHP Warning:  PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl: cannot open shared object file: No such file or directory), /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so (libicui18n.so.60: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP 7.4.33 (cli) (built: Apr 26 2023 00:00:00) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with the ionCube PHP Loader + ionCube24 v13.0.2, Copyright (c) 2002-2023, by ionCube Ltd.





# /usr/local/cwp/php71/bin/php -m

QuotePHP Warning:  PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl: cannot open shared object file: No such file or directory), /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so (libicui18n.so.60: cannot open shared object file: No such file or directory)) in Unknown on line 0
[PHP Modules]
...
intl
ionCube Loader
...

[Zend Modules]
the ionCube PHP Loader + ionCube24

overseer

In /usr/local/cwp/php71/php.ini, is the intl extension commented out?
;extension=intl
Uncomment, and/or set a hardcoded path
extension=
/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20170718/intl.so

Starburst

Yea, it was, now getting:

# /usr/local/cwp/php71/bin/php --version

QuotePHP Warning:  PHP Startup: Unable to load dynamic library '/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so' (tried: /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so (libicui18n.so.60: cannot open shared object file: No such file or directory), /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902//usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so.so (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902//usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library 'intl' (tried: /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl (/usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl: cannot open shared object file: No such file or directory), /usr/local/cwp/php71/lib/php/extensions/no-debug-non-zts-20190902/intl.so (libicui18n.so.60: cannot open shared object file: No such file or directory)) in Unknown on line 0
PHP 7.4.33 (cli) (built: Apr 26 2023 00:00:00) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with the ionCube PHP Loader + ionCube24 v13.0.2, Copyright (c) 2002-2023, by ionCube Ltd.

Tried both ways, same errors.
This makes no sense, all the AL9 servers are behaving.

And why is is trying to load a disable extension...

Netino

It is claiming about 'libicui18n.so.60' shared object file.
This is a too old library, and seems not available in any package to AL9, that uses GLIBC_2.34.

I think you will need to compile and install libicu 60.3 manually.

overseer

And you applied Sandeep's fix on that system?
dnf update ca-certificates -y
rpm -ivh https://github.com/mysterydata/md-disk/raw/main/libicu69-69.1-4.el8.x86_64.rpm
curl -s -L https://www.alphagnu.com/upload/tmp/el8/cwp_rc_fix_el8.sh | bash

Starburst

Yup, and for EL9 it is:

Package libicu-67.1-9.el9.x86_64 is already installed.
Package libicu-devel-67.1-9.el9.x86_64 is already installed.

It's weird it's only 1 this server, which doesn't matter to much, it doesn't have clients on it. It's a mirror.

NFT

Quote from: Starburst on July 05, 2025, 02:15:36 PM
Yup, and for EL9 it is:

Package libicu-67.1-9.el9.x86_64 is already installed.
Package libicu-devel-67.1-9.el9.x86_64 is already installed.

It's weird it's only 1 this server, which doesn't matter to much, it doesn't have clients on it. It's a mirror.

I know this are an old tread, but had the same issue, and reason was /usr/local/cwp/php71/php.d/intl.ini was readded
I also had an intl.ini.disabled
in this file the line "extension=intl" existed
I just removed the file /usr/local/cwp/php71/php.d/intl.ini and warning went away

overseer

Try this:
rm /usr/local/cwp/php71/php.d/intl.ini
touch /usr/local/cwp/php71/php.d/intl.ini
chatrr +i /usr/local/cwp/php71/php.d/intl.ini