Information Required
avatar rganey
rganey
25 Aug 2022

I have been attempting to resolve an issue with a fresh install of Joomla 4.2.0. In the admin UI under the Maintenance: Database the database does not appear. I became aware of this issue when I was attempting to update an earlier version of Joomla 4 to 4.2. The hosting company seems to be unable to resolve the issue or unwilling.

The install is hosted through cloud access and they set the site up, not me. In all my other installations I have not seen this issue. Any ideas as to what might be causing this issue. I am trying to resolve it before I pull the plug and shift to another host where I set everything up.
sagdb

avatar rganey rganey - open - 25 Aug 2022
avatar joomla-cms-bot joomla-cms-bot - change - 25 Aug 2022
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 25 Aug 2022
avatar N6REJ
N6REJ - comment - 25 Aug 2022

4.1.5 has the same issue
image


avatar richard67
richard67 - comment - 25 Aug 2022

@tecpromotion Could you advise here about checking the schemas table? I have to go to the office so I don’t have time before tonight.

avatar ssnobben
ssnobben - comment - 25 Aug 2022

"4.1.5 has the same issue" Ditto..

avatar Abernyte-Git
Abernyte-Git - comment - 25 Aug 2022

Can't replicate on J4.2.1 rc3
screen shot 2022-08-25 at 08 15 21


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/38594.
avatar chmst
chmst - comment - 25 Aug 2022

I cannot replicate on different sites.
@rganeyJ have you error-reporting on maximum and debug-mode "on"? Which PHP version?

avatar chmst chmst - change - 25 Aug 2022
Labels Added: Information Required
avatar chmst chmst - labeled - 25 Aug 2022
avatar richard67
richard67 - comment - 25 Aug 2022

I have heard about this problem mainly from people who have used a custom installer from their hosting provider. If @tecpromotion who also knows about these issues is not faster, I can provide tonight a database query for further investigation. Please be patient.

avatar brianteeman
brianteeman - comment - 25 Aug 2022

the problem occurs when there is no record in the #__schemas table and without this record its impossible to update joomla in the future

This will occur if the custom installer blindly assumes that everything is in the sql file - its not. This is NOT a problem from Joomla but it is a problem created by the custom installer.

As a super quick fix (and this is NOT the correct way but it works for you until @richard67 can review)

In the #__extensions table find the extension_id of "files_joomla"
image

Insert a record in the #__schemas table with the extension_id from above and 1 for the version_id

Now go back to the database page on your website. It will show the record and (because of the incorrect version) will say there is stuff to fix. Click on the update structure button and you're good to go.

avatar chmst chmst - change - 25 Aug 2022
Labels Removed: No Code Attached Yet
avatar chmst chmst - unlabeled - 25 Aug 2022
avatar brianteeman
brianteeman - comment - 25 Aug 2022

Tagging cloudaccess so they can fix their installer @jonathanCA @Pawel-Panek @DSniegu

avatar richard67
richard67 - comment - 25 Aug 2022

Please check the content of the #__schemas table in PhpMyAdmin and make a screenshot and post it here before you follow Brian’s good suggestion above so I can see if the record is completely missing or if it is there but with a wrong id.

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@richard67 I had seen this before with another host and their own custom installer which I helped to fix. They just took configuration.php-dist and ran the sql. That works to a point and thats why they didnt see any problem. But as we cvan see that of course creates problems

avatar richard67
richard67 - comment - 25 Aug 2022

Yes, I understood. Am thinking about working on a fix to make the database checker more resilient for this and making it possible to fix that with the “Update Structure” aka “Fix” button because that error keeps people from updating.

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@richard67 I wouldnt waste time on that. The host created the problem. Once aware they should fix it.

avatar tecpromotion
tecpromotion - comment - 25 Aug 2022

@brianteeman yes you are right with "The host created the problem" but if Richard finds a good solution, then we all benefit.
I know at least two hosters who could benefit from this. And maybe something will come back from them as well.

avatar Pawel-Panek
Pawel-Panek - comment - 25 Aug 2022

@brianteeman @richard67 is there any way we can run ConfigurationModel::setup() via Joomla CLI https://github.com/joomla/joomla-cms/blob/4.2-dev/installation/src/Model/ConfigurationModel.php#L49?

The reason I'm asking is this procedure can change anytime and if we attempt to code it outside of Joomla it eventually become wrong again.

avatar richard67
richard67 - comment - 25 Aug 2022

if we attempt to code it outside of Joomla

@Pawel-Panek Why do you want to do that?

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@richard67 so that they can install joomla unattended

@Pawel-Panek probably not at the moment. @Hackwar is working on a cli installation script but no idea if/when that will be released.

The reason I'm asking is this procedure can change anytime and if we attempt to code it outside of Joomla it eventually become wrong again.

Not for me to tell you how to do your job but there is nothing new about this afaik.

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@brianteeman yes you are right with "The host created the problem" but if Richard finds a good solution, then we all benefit. I know at least two hosters who could benefit from this. And maybe something will come back from them as well.

actually we dont benefit at all. of course we can write some code to allow a user to fix this specific problem but who knows what other problems are created by installing joomla for a customer this way. As this is an easy to see error I would prefer it if we dont offer an easy way for a user to fix it and instead get the hosts to check their entire scripting

avatar Pawel-Panek
Pawel-Panek - comment - 25 Aug 2022

@richard67 yes, unattended install - this is what we need.

I'll reach out to @Hackwar to see how can we help. For the moment we will use the code from setup function.

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@Pawel-Panek you can see what he is working on here #38325

avatar rganey
rganey - comment - 25 Aug 2022

@brianteeman

the problem occurs when there is no record in the #__schemas table and without this record its impossible to update joomla in the future

This will occur if the custom installer blindly assumes that everything is in the sql file - its not. This is NOT a problem from Joomla but it is a problem created by the custom installer.

As a super quick fix (and this is NOT the correct way but it works for you until @richard67 can review)

In the #__extensions table find the extension_id of "files_joomla" image

Insert a record in the #__schemas table with the extension_id from above and 1 for the version_id

Now go back to the database page on your website. It will show the record and (because of the incorrect version) will say there is stuff to fix. Click on the update structure button and you're good to go.

This fixed one thing and brock another lol. By adding the record the system then properly allowed me to 'fix" the database. however now the admin and site template is not loading.

I am looking into that now, I am not a power user so it will be a bit. Thanks and it looks like it is associated with the autoinstaller they are using.
sagdb1

avatar brianteeman
brianteeman - comment - 25 Aug 2022

@rganey This is something that @Pawel-Panek at CloudAccess should help you fix. They broke it

avatar rganey
rganey - comment - 25 Aug 2022

@brianteeman thanks.

avatar N6REJ
N6REJ - comment - 25 Aug 2022

@richard67 I wouldnt waste time on that. The host created the problem. Once aware they should fix it.

thats not entirely true. My install is NOT a host install
Richard and I have been over mine once before.
image
image

avatar Pawel-Panek
Pawel-Panek - comment - 26 Aug 2022

@rganey I updated you over the ticket.

avatar brianteeman
brianteeman - comment - 26 Aug 2022

@N6REJ well it wont be the first time that you have had a messed up install

avatar brianteeman
brianteeman - comment - 26 Aug 2022

This can be closed now. The issue with cloudaccess is presumably resolved or in the process of being resolved and there is nothing more to do here.

avatar Quy Quy - change - 26 Aug 2022
Status New Closed
Closed_Date 0000-00-00 00:00:00 2022-08-26 12:56:11
Closed_By Quy
avatar Quy Quy - close - 26 Aug 2022
avatar N6REJ
N6REJ - comment - 26 Aug 2022

@N6REJ well it wont be the first time that you have had a messed up install

kiss off @brianteeman

So, because its "ME" agreeing with the issue, it can't possibly be a valid issue

avatar Pawel-Panek
Pawel-Panek - comment - 29 Aug 2022

@brianteeman @richard67 the site provisioning issue has been mitigated. We'd be better off with CLI installer but anyways it works now. The CLI improvement is in progress and that's great. We'll certainly use it once it goes to stable.

avatar richard67
richard67 - comment - 29 Aug 2022

@Pawel-Panek Thanks for the update.

Add a Comment

Login with GitHub to post a comment