Support

Site Restoration

#36892 Database restoration error

Posted in ‘Site restoration’
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

PHP version
n/a
CMS Type
Other
CMS Version
n/a
Backup Tool Version
n/a
Kickstart version
n/a

Latest post by nicholas on Tuesday, 05 April 2022 13:40 CDT

ottosuperstudio

Hello, 

I'm developing a website on domainB (https://pre.ottosuperstudio.com/adventureland) using WordPress, and wanted to transfer the website to domainA (https://adventureland-borno.eu/) where the live site will be.

I did the backups for both sites using akeeba. Used the kickstart files to restore the website on the live website domain, but when I get to the database part an error come out, I don't know what the problem is, so I wanted to ask you if you know why this happens.

I'll look forward to hearing back from you.

Federica

nicholas
Akeeba Staff
Manager

You may have to uncheck the “Allow UTE8MB4 auto-detection” option as one of your plugins seem to be incompatible with this feature which was added to WordPress in early 2017 (well over five years ago now).

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!

ottosuperstudio

I've received this error message

nicholas
Akeeba Staff
Manager

Also check the “Use REPLACE instead of INSERT” option.

As per the documentation: ‘Use REPLACE instead of INSERT may be required if you keep getting MySQL errors about rows already existing in your tables.’

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!

ottosuperstudio

Another error message

nicholas
Akeeba Staff
Manager

Did you check both the “Allow UTE8MB4 auto-detection” and the “Use REPLACE instead of INSERT” options?

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!

ottosuperstudio

I unchecked the “Allow UTE8MB4 auto-detection” option and checked the “Use REPLACE instead of INSERT” option, as you said in the previous messages

nicholas
Akeeba Staff
Manager

No, you misunderstood me. I said ‘also check‘ meaning check that in addition to the previous one.

So, to clarify: please check both the “Allow UTE8MB4 auto-detection” and the “Use REPLACE instead of INSERT” options.

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!

ottosuperstudio

I got the same massage, this is a screenshot of the options that I checked

nicholas
Akeeba Staff
Manager

Can you please send me a link to download your backup archive? I will try to restore it locally to understand what is going on.

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!

ottosuperstudio

This is the backup file

https://we.tl/t-h0YknpweI6

Let me know if you need anything else, thank you.

Federica

ottosuperstudio

https://we.tl/t-PX1BK8DJOs

nicholas
Akeeba Staff
Manager

I have tried both links you sent me with Microsoft Edge and Google Chrome (fully updated) on Windows 11. Unfortunately, they both get stuck on "We're nearly ready..." with the Download button greyed out, not letting me download the file.

Can you please use a different file transfer service?

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!

ottosuperstudio

Sorry, I don't know why it happended

here is a new link https://buonstudio.box.com/s/bn0uwi6zbpc8299fkyh4fn65wxmqq3tr

nicholas
Akeeba Staff
Manager

Thank you for this link, it worked for me.

So, I have good news and bad news for you.

The good news is that I was able to restore your site on Windows, Linux and macOS just fine, using the default options without changing any of the settings in the Restore Database page.

The bad news is that the most likely cause of your problem is that your local server is using an outdated version of MySQL (5.7 or earlier) whereas the server you backed up from is using a modern version of MySQL (8.0).

The best way to resolve this issue is updating your local server to a new version which includes a modern version of MySQL. Newer versions of MySQL do not have the 767 byte limit for all keys on the table which is what you are hitting.

The other alternative is to force ANGIE to downgrade all your UTF8MB4 (4-byte UTF-8) to UTF8 (3-byte UTF-8). The problem with that is that you might lose something, namely any four byte Unicode characters such as Emoji. This data will be unrecoverable, so if you later back up the local site and try to restore it on your server these characters will be lost forever. If you understand this and you are fine with it modify the default Database Restoration settings as follows:

- Use REPLACE instead of INSERT: check

- Force UTF-8 collation on tables: check

- Allow UTF8MB4 auto-detection: uncheck (clear)

This tells the restoration script to pretend that UTF8MB4 is not a thing and try to forcibly downgrade everything to the older, 3-byte UTF8 encoding. Also note that while this works in most cases, it may not work always. If you still get an error you have no alternative other than upgrading your local server environment.

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!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

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!