PHP Extensions and ionCube
CorePanel ships a fixed set of PHP versions and extensions, declared by the
corepanel-php package. It covers what a normal PHP site needs, and it is the same set on
every CorePanel server — see Server Maintenance for how that package
reaches your host.
Some software needs more than that set. The common case is commercially encoded PHP: WHMCS, licensing systems and many paid scripts ship their source encrypted with ionCube and refuse to run without the ionCube Loader. This page covers that, and adding any other extension.
What is installed
Section titled “What is installed”To see the extension set the panel manages:
rpm -q --requires corepanel-phpAnd the extensions actually loaded by one PHP version:
php84 -m # or php83, php82, php74CorePanel does not manage php.ini or the php.d directory. It writes one file per
account under /etc/opt/remi/php<version>/php-fpm.d/<username>.conf and nothing else, so
anything you add to php.d is yours and survives updates.
Installing the ionCube Loader
Section titled “Installing the ionCube Loader”The Loader is packaged in the Remi repository, which CorePanel already enables during installation. There is nothing to download from ionCube’s website and nothing to compile:
dnf install php84-php-ioncube-loadersystemctl restart php84-php-fpmRepeat for every version you want to cover — the package name always follows the
php<version>-php-ioncube-loader pattern:
dnf install php83-php-ioncube-loader php82-php-ioncube-loader php74-php-ioncube-loadersystemctl restart php83-php-fpm php82-php-fpm php74-php-fpmVerify it loaded:
php84 -vThe output gains a line naming the ionCube PHP Loader. If it does not appear, the
restart is usually what is missing — a zend_extension is read when the PHP process
starts, so a running FPM master keeps serving without it.
What the package puts on disk
Section titled “What the package puts on disk”Two files per PHP version, and that is the whole installation:
| Path | What it is |
|---|---|
/etc/opt/remi/php84/php.d/01-ioncube_loader.ini | The zend_extension line that loads it |
/opt/remi/php84/root/usr/lib64/php/modules/ioncube_loader.so | The Loader itself |
The 01- prefix matters and is why the packaged version is worth using: ionCube has to be
loaded before OPcache, and the numbering guarantees that ordering. A hand-installed
Loader dropped into php.ini is the usual cause of “it is installed but PHP does not see
it”.
Because the .ini lives in the version’s shared php.d, one install covers both the
web pools and the command line — so encoded software also runs from
cron jobs and from SSH, with no extra step.
It applies to a whole PHP version
Section titled “It applies to a whole PHP version”The Loader is enabled per PHP version, not per account. Installing it for PHP 8.4 enables it for every account running PHP 8.4.
This is a property of PHP itself, not a CorePanel limitation: a zend_extension is loaded
when the interpreter starts, and an FPM pool can only override php.ini settings, not
load an engine extension. There is no per-account switch to build on top of that.
In practice it costs nothing. The Loader is inert for accounts with no encoded files — it adds a small amount of memory per PHP process and does not change how ordinary PHP runs.
Keeping it after updates
Section titled “Keeping it after updates”dnf update keeps the Loader current along with everything else, and CorePanel never
removes it — an update only touches files the panel owns.
One case does need you: when CorePanel adds a new PHP version, the Loader for that
version is not pulled in automatically, because it is not part of the corepanel-php
dependency set. If you start creating accounts on a newly added version, install its
Loader package too.
Adding any other extension
Section titled “Adding any other extension”The same pattern covers the rest of the Remi catalogue — the package name is
php<version>-php-<extension>:
dnf install php84-php-pecl-imagick php84-php-soapsystemctl restart php84-php-fpmTwo things worth knowing before you do:
- Install it for each version you need. The packages are independent per version;
php84-php-soapdoes nothing for an account on PHP 8.3. - A wrong name only warns.
dnf installprints No match for argument and exits successfully, so a typo looks like a successful install. Confirm withphp84 -mrather than trusting the transaction.
If an extension is not in Remi at all, prefer a pecl build over editing php.ini by
hand, and always drop the resulting .ini in the version’s php.d directory so ordering
and updates keep working the way they do for everything else.