Support

Akeeba Backup for Joomla!

#36115 Corrupt DB tables in J4

Posted in ‘Akeeba Backup for Joomla!’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Akeeba Backup version
n/a

seagul30

Hi,

I upgraded a site from J3.10 to J4.0.4

I installed Akeeba 9.0.8 and removed the old version 8 for J3.

Now I get the error "Oops! Your Akeeba Backup database tables are corrupt." (see attachment) when I try to access Akeeba. I tried to solve it with the database maintenance as describe but it does not update anything.

I select Akeeba Backup and click "Update structure" but nothing happens (see second attachment) only the message "There are tables not up to date!"

I tried to install Akeeba on top again, but it does not solve the problem.

How can I solve this?

Thanks

Sigrid

Β 

Β 

seagul30

Could you please remove the other two attachments in the original posts?

Thanks

Sigrid

nicholas
Akeeba Staff
Manager

Attachments are private; only the person filing the ticket and our support staff see them. Otherwise it'd be outright impossible to have public tickets, given the nature of our software :)

The error message you sent me (β€œOops! Your Akeeba Backup database tables are corrupt...”) only shows when Akeeba Backup encounters a fatal error while trying to load data from the #__akeebabackup_profiles table.

I am wondering if what you see happens because you are working on a site locally on Windows or macOS and the site has an uppercase character in its database table name prefix, or if the table is genuinely corrupt (as in: MySQL can no longer read the table). Neither issue would be fixed by Joomla's database fix page. That page only addresses a minimum of table row changes and missing tables.

Try uninstalling Akeeba Backup. Make sure the #__akeebabackup_profiles table is removed. The reinstall it.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

nicholas
Akeeba Staff
Manager

Hello Sigrid,

Harald emailed me that his transparent translation extension was involved in this. I have created a workaround based on the information he gave me, without having a copy to test it myself.

Could you please install the dev release from https://www.akeeba.com/download/developer-releases/akeebabackuppro-dev/rev8c25d86.html and tell me if that fixes the problem you have on your site?

If you give me a positive test I will include this change in Akeeba Backup 9.0.9.

Thank you in advance!

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

seagul30

Hi Nicholas,

yes, I will test and let you know by tomorrow.

I did not know you would be involved too, I thought it was only Harald's extensions.

Because the backup itself worked.
Thanks

Sigrid

nicholas
Akeeba Staff
Manager

The problem has to do with Akeeba Backup trying to figure out how to reuse Joomla's database connection object with its own wrapper. Since Harald's extension overrides the default mysqli driver with something that does not have β€œmysqli” in its name we cannot find a suitable driver. This triggers an error condition which is picked up by the initialisation code and reports an error.

The backup works either because it runs on CLI (where Harald's extension does not kick in) or because of a fail–over in the backup code which tries to create a new connection using the Global Configuration information when reusing Joomla's connection is not possible.

The fix I applied does a more involved detection of the database connection type in Joomla's database driver object. If the name does not match any known core Joomla driver we start checking the object inheritance hierarchy by object type β€” most third party drivers will extend a core Joomla database driver. If we still can't figure it out we check the class names in the class hierarchy and try to divine the database connection type. We were doing that in Joomla 3 / Akeeba Backup 8 to some extent but we had not ported that to Joomla 4 / Akeeba Backup 9 because we were not aware of any third party drivers. Now that we are it was easy adapting and improving our old code.

Harald says it works but I'd like another test from you β€” since you have a positively affected real world site β€” to be extra sure that we really did get it right with this fix.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

seagul30

Hi,

I just did a backup and restored on another server.

After the restoration I got the error in FE and BE:
0 Class 'Joomla\Plugin\Quickicon\AkeebaBackup\Extension\AkeebaBackup' not found

I deactivated the plugin in the database. Then I could access a little bit broken - but working - backend, reinstalled Akeeba Backup (https://www.akeeba.com/download/developer-releases/akeebabackuppro-dev/rev8c25d86.html from yesterday) and now the website works.

I did not change anything in the akeeba configuration before backing up.

Shall I test something else?

nicholas
Akeeba Staff
Manager

When you get an error like that delete the administrator/cache/autoload_psr4.php file and reload the page. This file is regenerated automatically by the XML manifest information of all installed extensions.

Also note that the backup and restoration have not changed in the version I sent you. The only change was the detection of the database driver.

Please redo the restoration and delete the aforementioned file. Make sure that the plugins/quickicon/akeebabackup/akeebabackup.xml file exists after restoring. That's all there is to it.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

seagul30

Thanks for your reply and effort!!!

I just deleted that file and reloaded --> it was rebuilt.

Is it really necessary to redo the restoration? The client is workings since two hours in that database...

Or is it sufficient to just TEST another restoration and check for the plugins/quickicon/akeebabackup/akeebabackup.xml. If that works, then everything is okay also in the Live-installation?

Β 

Β 

nicholas
Akeeba Staff
Manager

You don't need to redo the restoration on this server. Just test another restoration on a different server (local server works great for that) to make sure the file is there. If it's there then the problem post–restoration wasn't related to the restoration, it was just Joomla doing its own silly thing when you restored on top of an existing Joomla 4 site.

If you confirm it was the latter case I will add a small change in the restoration script to delete that file automatically so this issue doesn't happen again for you or anyone else..

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

seagul30

Hi,

sorry, for the late reply.

I did test the backup and the .xml file is in the correct place as written by you.

Best regards

SIgrid

nicholas
Akeeba Staff
Manager

Thank you very much for the update!

Have a great day :)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

System Task
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.

Support Information

Working hours: Typically we work Monday to Friday, 9am to 7pm Cyprus timezone (EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets, but we cannot respond to them, outside of our working hours.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!

Summer vacations: Our support will be closed for replies and new tickets from August 6th to August 21st, 2022 due to summer vacations.