Bug #75203 Misleading error when binlog name contains 4 byte utf8 on chaning to table
Submitted: 13 Dec 2014 14:45 Modified: 15 Dec 2014 11:40
Reporter: Daniël van Eeden (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Replication Severity:S3 (Non-critical)
Version:5.7.5-m15 OS:Any
Assigned to: CPU Architecture:Any
Tags: character set, regression, relaylog

[13 Dec 2014 14:45] Daniël van Eeden
Description:
It is possible to set a binlog name on the master with 4 byte utf8 characters.

This also works with mysqlbinlog, replication, etc.

But it fails if you try to set master_info_repository=TABLE or relay_log_info_repository=TABLE

mysql> set global master_info_repository='TABLE';
ERROR 1742 (HY000): Data for column 'Master_log_name' too long
mysql> set global relay_log_info_repository='TABLE';
ERROR 1742 (HY000): Data for column 'Master_log_name' too long

From the error log:
014-12-13T14:31:42.800146Z 1 [ERROR] Error changing the type of master info's repository: Error transfering information.
2014-12-13T14:32:06.408929Z 1 [ERROR] Error changing the type of relay log info's repository: Error transfering information.

The message is wrong as the text is not too long, it's in a unsupported character set.

Related: Bug #50226

How to repeat:
Set log_bin on the master to a name with 4 byte UTF-8 characters (like U+1F385 FATHER CHRISTMAS)

Then setup replication and try to change the repositories to TABLE.

Suggested fix:
I don't think there is a good use case for 4 byte UTF-8 in binlog names, so this is not a feature request.

Replace the error:
ERROR 1742 (HY000): Data for column 'Master_log_name' too long or is in a unsupported character encoding.

Or create a new error:
ERROR 1234 (HY000): Data for column 'Master_log_name' is in a unsupported character encoding.
[15 Dec 2014 11:40] MySQL Verification Team
Hello Daniël,

Thank you for the report.

Thanks,
Umesh
[15 Dec 2014 11:44] MySQL Verification Team
test results

Attachment: 75203.txt (text/plain), 2.40 KiB.