Hello, I am experiencing a problem with ISPConfig panel. That's my fault. I am here to ask to you how can I change the PHP version used to parse the panel's code. *** The story *** Today I did Code: apt update apt upgrade I noticed that PHP 8.0.1 was installed on the system. My websites are working but the panel died. I tried to switch the system-wide PHP version by using Code: update-alternatives --config php But nothing happened. I also tried to add a custom handler on the /usr/local/ispconfig/interface/web/.htaccess Code: RewriteEngine On Action php-cgi /usr/bin/php7.3 # THIS ONE # AddHandler php-cgi .php # OR # AddHandler application/x-httpd-php .php But the panel still uses PHP 8.0.1. Can you help me to figure out how solve this problem? Code: ##### SERVER ##### IP-address (as per hostname): ***.***.***.*** [WARN] could not determine server's ip address by ifconfig [INFO] OS version is Ubuntu 18.04.5 LTS [INFO] ISPConfig is installed. ##### ISPCONFIG ##### ISPConfig version is 3.2.2 ##### VERSION CHECK ##### [INFO] php (cli) version is 7.4.14 [INFO] I found the following web server(s): Apache 2 (PID 13861) [INFO] I found the following mail server(s): Unknown process (smtpd) (PID 2162) [INFO] I found the following pop3 server(s): Dovecot (PID 25250) [INFO] I found the following imap server(s): Dovecot (PID 25250) [INFO] I found the following ftp server(s): PureFTP (PID 25512)
Hi till, thanks for your quick reply. Unfortunately this is not working. Please, have a look there: Code: [email protected]***:/usr/share# update-alternatives --config php-cgi There are 6 choices for the alternative php-cgi (providing /usr/bin/php-cgi). Selection Path Priority Status ------------------------------------------------------------ 0 /usr/bin/php-cgi.default 100 auto mode 1 /usr/bin/php-cgi.default 100 manual mode 2 /usr/bin/php-cgi5.6 56 manual mode 3 /usr/bin/php-cgi7.2 72 manual mode 4 /usr/bin/php-cgi7.3 73 manual mode * 5 /usr/bin/php-cgi7.4 74 manual mode 6 /usr/bin/php-cgi8.0 80 manual mode Press <enter> to keep the current choice[*], or type selection number: 5 You have new mail in /var/mail/root [email protected]***:/usr/share# update-alternatives --config php There are 8 choices for the alternative php (providing /usr/bin/php). Selection Path Priority Status ------------------------------------------------------------ 0 /usr/bin/php7.4 74 auto mode 1 /usr/bin/php.default 10 manual mode 2 /usr/bin/php5.6 56 manual mode 3 /usr/bin/php7.0 70 manual mode 4 /usr/bin/php7.1 71 manual mode 5 /usr/bin/php7.2 72 manual mode 6 /usr/bin/php7.3 73 manual mode * 7 /usr/bin/php7.4 74 manual mode 8 /usr/bin/php8.0 5 manual mode Press <enter> to keep the current choice[*], or type selection number: 7 [email protected]***:/usr/share# service php7.4-fpm restart [email protected]***:/usr/share# php -v PHP 7.4.14 (cli) (built: Jan 13 2021 08:04:06) ( NTS ) Copyright (c) The PHP Group Zend Engine v3.4.0, Copyright (c) Zend Technologies with Zend OPcache v7.4.14, Copyright (c), by Zend Technologies
I use script with monit to monitor such changes and I shared it in here: https://www.howtoforge.com/community/threads/monitor-os-default-php-and-restore-if-changed.83288/