how to force PhpMyAdmin to run under php 7.4

Discussion in 'Installation/Configuration' started by seopower, Jul 23, 2021.

  1. seopower

    seopower New Member

    I have followed all instructions to install and configure ( All went well.

    But I have installed additional PHP version 5.6 FPM, which is working fine when I switch between php version. But phpmyadmin stopped working and was showing error 500. Upon running phpinfo() from index.php of phpmyadmin I found that it using PHP 5.6 instead of default PHP 7.4.

    Now how to force phpmyadmin to use PHP 7.4 instead of PHP 5.6?
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Probably you accidentially installed mod_php as php 5.6 too. Install the correct mod_php package again as websites in ISPConfig don't use mod_php anyway, so installing mod_php as PHP 5.6 makes no sense in terms of being able to switch PHP versions in ISPConfig. For PHP version switching, you just need php-cgi and php-fpm as 5.6 version.
  3. seopower

    seopower New Member

    Thanks for reply... but now I have removed libapache2-mod-php and libapache2-mod-php7.4, then rebooted machine but still under phpmyadmin it show PHP 5.6

    I tried to install phpmyadmin 5.1 and that shows Currently installed version is:

    Please help
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    You should not remove libapache2-mod-php7.4. Please go trough the tutorial you linked above again and take care to install all modules as described in the guide.
  5. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    a2dismod mpm_prefork
    a2enmod mpm_event http2
    a2enconf php7.4-fpm
  6. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    Note if you're uninstalling, or at least disabling, mod_php, these are fine (and also add "a2disconf php5.6-fpm" for good measure); if you are going to use mod_php (it is not needed for phpmyadmin, or anything else that I'm aware of), you cannot change away from mpm_prefork to mpm_event, and you can't use http2.
  7. janvl

    janvl Member

  8. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    I am not using this method but I think another way of doing it is to create website for phpmyadmin and use the UI to change to whatever php versions installed as options on your server (of course up to whatever php version phpmyadmin supports).

Share This Page