MDEV-4827 mysqldump --dump-slave=2 --master-data=2 doesn't record both
Recording both is useful on a replication relay when the backup can be used to replace the server, or ack as a new replica to the server. If an option=2, commented is selected, allow the alternate option to exist. This still disables --dump-slave=1 --master-data=1 as having the a CHANGE MASTER TO and START SLAVE on different positions would be confusing and dangerious to the try to execute the output. The previous behaviour of silently disabling --master-data occurs in this case. The commented code related to --dump-slave/--master-data is greatly expanded for human consumption. A redundant opt_slave_data= 0 was removed from get_opts. If --dump-slave=1 or 2, then the only possible value of --master-data is a valid one. Re-order to preference gtid based replication. Based of code from Elena Stepanova. Review by: Brandon Nesterenko and Anel Husakovic
Showing
Please register or sign in to comment