(Solution) Unknown collation: utf8mb4_0900_ai_ci

After doing a bit of research, I found that the MySQL server running on the destination is an older version than the source server.

It came down to making a small adjustment to the backup file to fix this.

I edited the database backup file in a text editor and replaced "utf8mb4_0900_ai_ci" with "utf8mb4_general_ci" and "CHARSET=utf8mb4" with "CHARSET=utf8". Linux users can use the sed command to replace text in files directly.

sed -i 's/utf8mb4_0900_ai_ci/utf8_general_ci/g' backup.sql
sed -i 's/utf8_general_ci/utf8mb4_general_ci/g' backup.sql

After the changes above, the database was restored successfully!

Before it was a ticket. Now it's a prompt.

Does your Drupal leak?

Tell me what you are working on and what worries you. I'll reply personally and, if I'm not the right person, I'll tell you too.