I've begun slowly migrating websites on this WHM 106.0.14 server from PHP 7.4 to PHP 8.1 since PHP 7 has now fully reached end of life. PHP 8.1 was installed via EasyApache 4.
I'm running into a weird issue that I've never had to deal with in over 20 years of using PHP on various servers and I suspect there's additional configuration in WHM (probably in httpd.conf or php.ini, not sure yet) that needs to be done before PHP 8.1 can be used "normally".
I made a new PHP file with only the following content in it (sorry, I tried to format the code, but when I click on the CODE button in the editor toolbar, it pops up cpanel.net list of forums for some reason)
<?
session_start();
die('OK');
?>
And then when I request this file in a web browser, the script hangs and never finishes loading (it does not output "OK" or anything else). There is no error_log file either. I left it hanging like that for 5 minutes and it never stops "loading". In WHM the CPU usage for that script goes in the roof to near 100% in seconds.
I went to take a look in /var/cpanel/php/sessions/ea-php81 and I can see 7 bytes session files in there so I know PHP creates them, it looks good.
I'm kind of stumped. Is there anything that needs to be tweaked in WHM anywhere for PHP 8.1 to correctly execute the session_start() function? Never had any problem with previous PHP releases...
I'm running into a weird issue that I've never had to deal with in over 20 years of using PHP on various servers and I suspect there's additional configuration in WHM (probably in httpd.conf or php.ini, not sure yet) that needs to be done before PHP 8.1 can be used "normally".
I made a new PHP file with only the following content in it (sorry, I tried to format the code, but when I click on the CODE button in the editor toolbar, it pops up cpanel.net list of forums for some reason)
<?
session_start();
die('OK');
?>
And then when I request this file in a web browser, the script hangs and never finishes loading (it does not output "OK" or anything else). There is no error_log file either. I left it hanging like that for 5 minutes and it never stops "loading". In WHM the CPU usage for that script goes in the roof to near 100% in seconds.
I went to take a look in /var/cpanel/php/sessions/ea-php81 and I can see 7 bytes session files in there so I know PHP creates them, it looks good.
I'm kind of stumped. Is there anything that needs to be tweaked in WHM anywhere for PHP 8.1 to correctly execute the session_start() function? Never had any problem with previous PHP releases...