PHPMyAdmin and roundcube do not work after fresh installation (debian10,apache,php_fpm)

Discussion in 'Installation/Configuration' started by ruppel, Nov 29, 2020.

  1. ruppel

    ruppel New Member

    Hi,
    I know this problem occured several times, but after hours (better days) of reading different posts and solutions without a solution for me,... it seems I have to create a new thread in here.
    It's the problem, that while using php_fpm with multiple php versions, the installed roundcube and the phpmyadmin only show the source code, but do not get interpreted by php.
    My server is a debian 10 system with apache as web server.
    I do the installation using ansible scripts which mixes up different tutorials from howtoforge and from the book "Rootserver unter Debian/GNU Linux". The ansible scripts are in github.com under /ruppel/myserver (by now I'm not allowed to post links...)
    Attached you will find the htf_report.
    Thanks a lot for the great tutorials and for a little help (in advance),
    Ruppel
     

    Attached Files:

    Last edited: Nov 29, 2020
  2. ruppel

    ruppel New Member

    OK, another day of searching and trying,... and now it works.
    I also need to install the libapache2-mod-php<version> packages. This fixed the problem.
     
  3. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    You can/should uninstall mod_php, then enable the config for ph-fpm (a2enconf php7.3-fpm, I believe).
     
  4. ruppel

    ruppel New Member

    At first my scripts didn't install the libapache2-mod-php<version> packages. Result was, that php-fpm was running, but no roundcube and no phpmyadmin.
    Now my scripts install the libapache2-mod-php<version> packages and roundcube and phpmyadmin work like a charm. Also the php-fpm is working which i checked using phpinfo.
    Current development is here: github.com/ruppel/myserver
     
  5. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

  6. ruppel

    ruppel New Member

    Hmm, I thought I have done everything according to tutorial "How to install PHP 5.6 and 7.0 - 7.4 as PHP-FPM & FastCGI for ISPConfig 3.1 with apt on Debian 8 to 10" in php-multiple-version-installed/tasks/main.yml.
    There was nothing about enabling a config for apache...
    And in tutorial "The Perfect Server - Debian 10 (Buster) with Apache, BIND, Dovecot, PureFTPD and ISPConfig 3.1" I also can't find something like that.

    So I only have to 'a2enconf php7.3-fpm' because this should be the default, or do this for every single php version?
     
  7. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    Correct, don't enable config for every version, only the system default version.
     
  8. ruppel

    ruppel New Member

    Allright, it works, thanks a lot!
    So, why isn't that documented in the tutorials I mentioned above? It would have saved a few days of research...
     
  9. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    Checking the current debian 10 guide, it installs mod_php, which works as you noted. Your script uninstalled it, but didn't enable anything else as a default php interpreter, hence your problem. Nowadays you want to ditch mod_php as it requires mpm_prefork, so you can't use http/2 with it; plus it's a less secure (breaching mod_php gains access to the entire apache web server; breaching php-fpm gains access to only the php daemon).
     
    ruppel likes this.

Share This Page