Last_IO_Error: Got fatal error 1236 from master when reading data from binary log: 'The slave is connecting using CHANGE MASTER TO MASTER_AUTO_POSITION = 1, but the master has purged binary logs containing GTIDs that the slave requires.'
Replicationしてて、SlaveをRestoreしたら、こんなエラーで、Slave_IOが止まってる。
そんなときは、MasterのGTID_EXECUTEDを、SlaveのGTID_PURGEDに手動で設定してやればいい、らしい。
設定する値は
master> show global variables like 'GTID_EXECUTED';
で取得できる。
けど、こいつはEmptyのときしか設定できないので、いったんリセットする。
slave> reset master;
slave> set global GTID_PURGED="%GTID_EXECUTED of Master%";
slave> start slave io_thread;
で、Masterを再設定して、レプリケーションを再開させればOKらしい。