Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The MySQL DB service is generating dumps using a generated config file. That config file does not include a default character set, causing it to usually default to utf8
or what ever happens to be the compile-time default. Because of this, Unicode characters in the supplementary character set (beyond U+FFFF) will be lost when the database is dumped. This is critical, because not only causes it the backups to be not usable, it furthermore also causes any migration to make the sites lose the supplementary characters since a migration uses DB dump+restore.
Comment | File | Size | Author |
---|---|---|---|
#2 | provision-mysqldumputf8mb4-3160565-1.patch | 433 bytes | sseidel |
Comments
Comment #2
sseidel CreditAttribution: sseidel as a volunteer commentedComment #3
sseidel CreditAttribution: sseidel as a volunteer commentedComment #4
martin_qI have not tested this but I have looked over the patch. It seems sane to me. A couple of probably very minor suggestions, which may not even be anything anyone cares about:
Does it need an 'identical' comparison or would
if ($this->server->utf8mb4_is_supported)
be sufficient?The original string doesn't contain
\n
but instead literal ends-of-lines, so does this patch introduce unnecessary inconsistency?Comment #6
helmo CreditAttribution: helmo as a volunteer and at Initfour websolutions commentedThanks, committed ... with @martin_q's remarks.
PS: an alternative/workaround is to add that to the global mysql config in the [mysqldump] section.