The issue seems to be that the debian startscript for MariaDB server runs mysql_upgrade *without* specifying --skip-write-binlog. As a result, although the slow-query log and the general log are disabled by mysql_system_tables_fix.sql, these SET statements are not replicated to the slave, so, when the slave tries to run the ALTER TABLE slow_query or ALTER TABLE general_log, it runs up against the log still being enabled.
The correct solution seems to be to modify debian/addtiions/debian-start, changing:
MYUPGRADE="/usr/bin/mysql_upgrade --defaults-extra-file=/etc/mysql/debian.cnf"
to
MYUPGRADE="/usr/bin/mysql_upgrade --defaults-extra-file=/etc/mysql/debian.cnf --skip-write-binlog"
The issue seems to be that the debian startscript for MariaDB server runs mysql_upgrade *without* specifying --skip- write-binlog. As a result, although the slow-query log and the general log are disabled by mysql_system_ tables_ fix.sql, these SET statements are not replicated to the slave, so, when the slave tries to run the ALTER TABLE slow_query or ALTER TABLE general_log, it runs up against the log still being enabled.
The correct solution seems to be to modify debian/ addtiions/ debian- start, changing: "/usr/bin/ mysql_upgrade --defaults- extra-file= /etc/mysql/ debian. cnf" "/usr/bin/ mysql_upgrade --defaults- extra-file= /etc/mysql/ debian. cnf --skip- write-binlog"
MYUPGRADE=
to
MYUPGRADE=