Symptoms
-
Error loading module while running PHP script:
PHP Warning: Module '<module_name>' already loaded in Unknown on line 0
Cause
A PHP Module is enabled several times in one of the php.ini
files.
Resolution
-
Connect to the server via SSH
-
Check the
.ini
files of the PHP handler and find duplicates (replace<module_name>
with the actual module name from the error):For the PHP version provided by the OS vendor:
# grep -iR '<module_name>' /etc/php/
For PHP X.X version shipped with Plesk, e.g. 8.2:
# grep -iR '<module_name>' /opt/plesk/php/X.X/etc/
For custom php.ini file for the domain:
# grep -iR '<module_name>' /var/www/vhosts/system/example.com/conf/etc/
-
Comment or remove the duplicated directive line using the text editor