When trying to install 4.0 beta 1 on both a Raspberry pi 3 running buster and also a Fedora 23
installation on a separate machine I get the following error as soon as I try to open the site using the extracted files from https://github.com/joomla/joomla-cms/releases/download/4.0.0-beta/Joomla_4.0.0-beta1-Beta-Full_Package.tar.bz2.
Oops! An Error Occurred
The server returned a "500 Whoops, looks like something went wrong.".
Something is broken. Please let us know what you were doing when this error occurred. We will fix it as soon as possible. Sorry for any inconvenience caused.
@joecurtis Please make sure your PHP meets the technical requirements https://downloads.joomla.org/technical-requirements and has a sufficient max_execution_time and memory_limit.
P.S. ... and the updated requirements for Joomla 4 you can find here: https://docs.joomla.org/Potential_backward_compatibility_issues_in_Joomla_4.
@richard67 that's not a Joomla error. Probably a misconfigured Apache/Nginx - PHP/PHP-FPM
@dgrammatiko Agree. Just wanted to point to a few docs, maybe some php module is missing. Will give it a bit time and then close it.
maybe some php module is missing.
IIRC we did spend some time to get the initial checks right, eg even a PHP4 will echo some nice html instead of some cryptic text. If there are cases that the current code isn't covering then there should be an effort to get some code for those.
Anyways this one here is not a case that Joomla can handle, eg if you're running php-fpm and the socket is not found I think you get this 500 error by Apache/Nginx/IIS. Joomla never executed a single line in this case neither there is something that can do about it.
Anyways my 2p
@joecurtis please do a simple check: remove the Joomla content.
Add a single index.php with content
<?php
echo phpinfo();
Try to access your site. Do you see the PHP version + other PHP info?
If not you need to fix your Apache/NginX/PHP
IRC we did spend some time to get the initial checks right
@dgrammatiko Right. How could I forget that?
I have Joomla 3.9.19 running successfully on another RPI under NGINX with the same parameter set up.
All permissions are set to 777 ( temporarily ) and my PHP test program reports as follows
Does PHP work?
Yes, it does. Your server has PHP Version 7.3.14-1~deb10u1
Current GD status:
GD support: YES
GD Version: 2.2.5
FreeType Support: yes
FreeType Linkage: with freetype
GIF Read Support: yes
GIF Create Support: yes
JPEG Support: yes
PNG Support: yes
WBMP Support: yes
XPM Support: yes
XBM Support: yes
WebP Support: yes
BMP Support: yes
JIS-mapped Japanese Font Support: no
@joecurtis and you subdomain that you try to load Joomla 4 echo's correctly the PHP info?
That's weird. I will try this on the weekend on a raspberry
this is joomla error, I mean the error comes from joomla global exception handler,
to see full stack trace need to enable a debug mode or set error_reaporting to maximum in configuration.php,
but I do not know how to do it for installation :)
Yes. The PHP info is also listed on my test program I just didn't bother to reproduce it.
Interestingly I have joomla 3.x sites running on my fedora machine which operates under apache2. Its just the Joomla 4.0 installation that is giving the trouble.
hmhm, try add this at end of installation/includes/framework.php
$errorHandler->setExceptionHandler(
[
new \Symfony\Component\ErrorHandler\ErrorHandler(null, true),
'renderException'
]
);
this should enable full stack trace instead of Oops! An Error Occurred
To enable debug mode in the installation
edit the file localise.xml
located in the \installation
folder and change
<debug>0</debug>
to
<debug>1</debug>
Tried that and the result is:-
Error
Call to undefined function simplexml_load_file()
in /var/www/blackwood/libraries/src/Language/LanguageHelper.php (line 682)
{
throw new \RuntimeException('File not found or not readable');
}
// Try to load the file
$xml = simplexml_load_file($path);
if (!$xml)
{
return;
}
There appears to be a number of locations with a similar problem
To enable debug mode in the installation
edit the filelocalise.xml
located in the\installation
folder and change
<debug>0</debug>
to
<debug>1</debug>
Thanks @brianteeman ... I hope I'll not forget it until I need it next time.
If that's the case then this is foobar:
joomla-cms/installation/src/Model/ChecksModel.php
Lines 77 to 82 in 5380899
@dgrammatiko Maybe it needs to be "\simplexml_load_file" instead of "simplexml_load_file"?
@joecurtis What happens if you change following line
https://github.com/joomla/joomla-cms/blob/4.0-dev/libraries/src/Language/LanguageHelper.php#L682
from
$xml = simplexml_load_file($path);
to
$xml = \simplexml_load_file($path);
?
same result.
Symfony\Component\ErrorHandler\Error\ UndefinedFunctionError
in /var/www/blackwood/libraries/src/Language/LanguageHelper.php (line 682)
{
throw new \RuntimeException('File not found or not readable');
}
// Try to load the file
$xml = \simplexml_load_file($path);
if (!$xml)
{
return;
}
To enable debug mode in the installation
edit the file localise.xml located in the \installation folder and change
Nope.
This concerns only debug language
Call to undefined function simplexml_load_file()
that sounds like you do not have php-xml extension
that sounds like you do not have php-xml extension
@Fedik read my comment above: #29425 (comment)
Probably something is not correct there, this should raise a warning not crash hard.
@Fedik I didn't have php-xml but have now installed it and also remove the \ from simplexml_load_file. That appears to remove that error but it goes on to the next one
Symfony\Component\ErrorHandler\Error\FatalError: Compile Error: require(): Failed opening required '/var/www/blackwood/administrator/cache/autoload_psr4.php' (include_path='.:/usr/share/php') at /var/www/blackwood/libraries/namespacemap.php:93
@dgrammatiko maybe there incorrect extension name, or that code just ignored somehow
@joecurtis that maybe something with read/write access, hard to say.
The file cache/autoload_psr4.php will be generated if not exists
@joecurtis (Magic Quotes GPC, MB String Overload = off)
(Zlib Compression Support, XML Support, INI Parser Support, JSON Support, MB Language = Default)
All these needs to be installed. Maybe a few more, these are from the J3.x requirements https://downloads.joomla.org/technical-requirements
or that code just ignored somehow
That's what I was trying to point out. This code should fail the installation gracefully not with cryptic messages...
Title |
|
As I have Installed and am running Joomla 3.x on both the RPI and Fedora platforms and the technical-requirements only cover 3.x then I would have thought that the necessary extensions were present or not as required. I will, however, check and retry,
After debugging I found the installer require php-xml
extension to be available to start, so ChecksModel.php even cannot start if XML not available.
This because of InstallerApplication tries to detect a language
joomla-cms/installation/src/Application/InstallationApplication.php
Lines 459 to 462 in 4faf8af
It looks like we should check for php-xml
availability on boot up.
@wilsonge any idea?
Status | New | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2020-12-20 14:40:40 |
Closed_By | ⇒ | Quy |
@joecurtis take a look at this ticket, it may help: #29424
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/29425.