Master强行重启后的同步故障
时间:2008-05-21 来源:r_a
从DB的ERROR日志:
080519 23:41:26 [ERROR] Slave I/O thread killed during or after a reconnect done to recover from failed read
080519 23:41:26 [ERROR] Slave I/O thread exiting, read up to log 'UE-us90-bin.000099', position 582469747
080519 23:41:26 [ERROR] Error reading relay log event: slave SQL thread was killed
080519 23:59:13 [Note] Slave I/O thread: connected to master '[email protected]:3306', replication started in log 'UE-us90-bin.000099' at position 582469747
080519 23:59:13 [Note] Slave SQL thread initialized, starting replication in log 'UE-us90-bin.000099' at position 582469747, relay log './UE-US11-relay-bin.000092' position: 496342737
080519 23:59:13 [ERROR] Slave: Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'update store_realm set goldnum = '0', ctoc_goldnum = '10427', preorder_goldnum = '0' where serverarea=8 and servername='Eonar' and faction=1', Error_code: 1053
080519 23:59:13 [ERROR] Error running query, slave SQL thread aborted. Fix the problem, and restart the slave SQL thread with "SLAVE START". We stopped at log 'UE-us90-bin.000099' position 582469747
照提示执行后,仍然出错为: 080520 0:00:17 [Note] Slave SQL thread initialized, starting replication in log 'UE-us90-bin.000099' at position 582469747, relay log './UE-US11-relay-bin.000092' position: 496342782
080520 0:00:17 [ERROR] Slave: Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'UPDATE `orders` SET `country` = 'us', `v_oid` = '2008-05-19-5358-10077936', `studio_id` = '217', `game_area` = 'æ— ', `game_server` = 'Shandris', `game_race` = 'Dwarf', `game_role` = 'Sinjr', `game_user` = '667max', `game_pass` = '9431759912648401132108010695585792 400080949836310016000',
080520 0:00:17 [ERROR] Error running query, slave SQL thread aborted. Fix the problem, and restart the slave SQL thread with "SLAVE START". We stopped at log 'UE-us90-bin.000099' position 582470130 检查主DB,发现每个记录后的error_code=1053,正常情况下为error_code=0. 判断可能是由强行关闭DB所致(server mysqld stop,因mysqladmin shutdown无效)。 # at 582469747
#080519 23:27:49 server id 11 log_pos 582469747 Query thread_id=48223301 exec_time=1262 error_code=1053
SET TIMESTAMP=1211264869;
update store_realm set goldnum = '0', ctoc_goldnum = '10427', preorder_goldnum = '0' where serverarea=8 and servername='Eonar' and faction=1;
# at 582469925
#080519 23:27:56 server id 11 log_pos 582469925 Query thread_id=48223649 exec_time=1255 error_code=1053
use gwmine;
SET TIMESTAMP=1211264876;
update osc_order_m a,osc_order_s b set b.OnlineAccountNO='616940702374726',b.PayType='google_checkout' where a.ID=b.OrderID and a.ID='470468' and a.OrderKey='001841659';
# at 582470130
#080519 23:28:09 server id 11 log_pos 582470130 Query thread_id=48223690 exec_time=1242 error_code=1053
use roster;
SET TIMESTAMP=1211264889;
UPDATE `orders` SET `country` = 'us', `v_oid` = '2008-05-19-5358-10077936', `studio_id` = '217', `game_area` = '无', `game_server` = 'Shandris', `game_race` = 'Dwarf', `game_role` = 'Sinjr', `game_user` = '667max', `game_pass` = '9431759912648401132108010695585792 400080949836310016000', `game_pin` = '', `protect_card` = '', `game_class` = 'Palalin', `price` = '11.00', `telphone` = '', `qq` = '', `msn` = '', `email` = '[email protected]', `card_money` = '0.00', `card_num` = '0', `is_recharge` = '0', `c_payment` = 'yes', `c_chargeback` = 'no', `a_payment` = 'no', `a_entrust` = 'yes', `s_gathering` = 'no', `s_inwork` = 'yes', `finish` = 'yes', `finish_confirm` = 'yes', `c_order_time` = '2008-05-19 12:18:13', `c_payment_time` = '2008-05-20 04:19:23', `c_chargeback_time` = '2000-00-00 00:00:00', `a_payment_time` = '2000-00-00 00:00:00', `s_gathering_time` = '0000-00-00 00:00:00', `finish_time` = '2008-05-20 14:24:23', `finish_confirm_time` = '2008-05-20 14:27:39', `game_new_pass` = '13320250958633983292810581589340009 10018214836622', `remark` = '', `a_send` = 'yes', `s_accept` = 'yes', `a_send_time` = '2008-05-20 03:55:32', `s_accept_time` = '0000-00-00 00:00:00', `charge_time` = '0000-00-00 00:00:00', `pl_start` = '37级', `pl_end` = '40级', `pl_time` = '1440', `pl_place` = '', `pl_c_require_stime` = '2008-05-19 16:00:00', `pl_s_require_stime` = '2008-05-19 16:00:00', `pl_s_require_etime` = '2008-05-20 16:00:00', `pl_s_evalation_level` = '1', `pl_s_evalation` = '0', `s_inwork_time` = '2008-05-20 04:53:41', `entrust_remark` = '无', `pl_type` = 'level', `pl_queue` = 'yes', `pl_s_time` = '24', `pl_c_require_etime` = '0000-00-00 00:00:00', `pl_s_price` = '75.00', `pl_s_foregift` = '0.00', `s_pledge` = 'yes', `s_pledge_time` = '2008-05-20 03:56:43', `a_entrust_time` = '2008-05-20 04:02:58', `isdelete` = '0', `timezoneoffset` = '-5', `dst` = '0', `customer_cookie` = 'b84b97f43ffe8db72e8eced569b78047', `customer_ip` = '71.249.21.81', `payment_type` = '4', `special_state` = '', `staff_name` = '张杰', `followName` = '', `other_payment` = '';
google搜到一个方案, http://bugs.mysql.com/bug.php?id=16559 在配置文件中加skip-slave-error=1053 (which can be used on
your slave but that is scary)
080519 23:41:26 [ERROR] Slave I/O thread exiting, read up to log 'UE-us90-bin.000099', position 582469747
080519 23:41:26 [ERROR] Error reading relay log event: slave SQL thread was killed
080519 23:59:13 [Note] Slave I/O thread: connected to master '[email protected]:3306', replication started in log 'UE-us90-bin.000099' at position 582469747
080519 23:59:13 [Note] Slave SQL thread initialized, starting replication in log 'UE-us90-bin.000099' at position 582469747, relay log './UE-US11-relay-bin.000092' position: 496342737
080519 23:59:13 [ERROR] Slave: Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'update store_realm set goldnum = '0', ctoc_goldnum = '10427', preorder_goldnum = '0' where serverarea=8 and servername='Eonar' and faction=1', Error_code: 1053
080519 23:59:13 [ERROR] Error running query, slave SQL thread aborted. Fix the problem, and restart the slave SQL thread with "SLAVE START". We stopped at log 'UE-us90-bin.000099' position 582469747
照提示执行后,仍然出错为: 080520 0:00:17 [Note] Slave SQL thread initialized, starting replication in log 'UE-us90-bin.000099' at position 582469747, relay log './UE-US11-relay-bin.000092' position: 496342782
080520 0:00:17 [ERROR] Slave: Query partially completed on the master (error on master: 1053) and was aborted. There is a chance that your master is inconsistent at this point. If you are sure that your master is ok, run this query manually on the slave and then restart the slave with SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; . Query: 'UPDATE `orders` SET `country` = 'us', `v_oid` = '2008-05-19-5358-10077936', `studio_id` = '217', `game_area` = 'æ— ', `game_server` = 'Shandris', `game_race` = 'Dwarf', `game_role` = 'Sinjr', `game_user` = '667max', `game_pass` = '9431759912648401132108010695585792 400080949836310016000',
080520 0:00:17 [ERROR] Error running query, slave SQL thread aborted. Fix the problem, and restart the slave SQL thread with "SLAVE START". We stopped at log 'UE-us90-bin.000099' position 582470130 检查主DB,发现每个记录后的error_code=1053,正常情况下为error_code=0. 判断可能是由强行关闭DB所致(server mysqld stop,因mysqladmin shutdown无效)。 # at 582469747
#080519 23:27:49 server id 11 log_pos 582469747 Query thread_id=48223301 exec_time=1262 error_code=1053
SET TIMESTAMP=1211264869;
update store_realm set goldnum = '0', ctoc_goldnum = '10427', preorder_goldnum = '0' where serverarea=8 and servername='Eonar' and faction=1;
# at 582469925
#080519 23:27:56 server id 11 log_pos 582469925 Query thread_id=48223649 exec_time=1255 error_code=1053
use gwmine;
SET TIMESTAMP=1211264876;
update osc_order_m a,osc_order_s b set b.OnlineAccountNO='616940702374726',b.PayType='google_checkout' where a.ID=b.OrderID and a.ID='470468' and a.OrderKey='001841659';
# at 582470130
#080519 23:28:09 server id 11 log_pos 582470130 Query thread_id=48223690 exec_time=1242 error_code=1053
use roster;
SET TIMESTAMP=1211264889;
UPDATE `orders` SET `country` = 'us', `v_oid` = '2008-05-19-5358-10077936', `studio_id` = '217', `game_area` = '无', `game_server` = 'Shandris', `game_race` = 'Dwarf', `game_role` = 'Sinjr', `game_user` = '667max', `game_pass` = '9431759912648401132108010695585792 400080949836310016000', `game_pin` = '', `protect_card` = '', `game_class` = 'Palalin', `price` = '11.00', `telphone` = '', `qq` = '', `msn` = '', `email` = '[email protected]', `card_money` = '0.00', `card_num` = '0', `is_recharge` = '0', `c_payment` = 'yes', `c_chargeback` = 'no', `a_payment` = 'no', `a_entrust` = 'yes', `s_gathering` = 'no', `s_inwork` = 'yes', `finish` = 'yes', `finish_confirm` = 'yes', `c_order_time` = '2008-05-19 12:18:13', `c_payment_time` = '2008-05-20 04:19:23', `c_chargeback_time` = '2000-00-00 00:00:00', `a_payment_time` = '2000-00-00 00:00:00', `s_gathering_time` = '0000-00-00 00:00:00', `finish_time` = '2008-05-20 14:24:23', `finish_confirm_time` = '2008-05-20 14:27:39', `game_new_pass` = '13320250958633983292810581589340009 10018214836622', `remark` = '', `a_send` = 'yes', `s_accept` = 'yes', `a_send_time` = '2008-05-20 03:55:32', `s_accept_time` = '0000-00-00 00:00:00', `charge_time` = '0000-00-00 00:00:00', `pl_start` = '37级', `pl_end` = '40级', `pl_time` = '1440', `pl_place` = '', `pl_c_require_stime` = '2008-05-19 16:00:00', `pl_s_require_stime` = '2008-05-19 16:00:00', `pl_s_require_etime` = '2008-05-20 16:00:00', `pl_s_evalation_level` = '1', `pl_s_evalation` = '0', `s_inwork_time` = '2008-05-20 04:53:41', `entrust_remark` = '无', `pl_type` = 'level', `pl_queue` = 'yes', `pl_s_time` = '24', `pl_c_require_etime` = '0000-00-00 00:00:00', `pl_s_price` = '75.00', `pl_s_foregift` = '0.00', `s_pledge` = 'yes', `s_pledge_time` = '2008-05-20 03:56:43', `a_entrust_time` = '2008-05-20 04:02:58', `isdelete` = '0', `timezoneoffset` = '-5', `dst` = '0', `customer_cookie` = 'b84b97f43ffe8db72e8eced569b78047', `customer_ip` = '71.249.21.81', `payment_type` = '4', `special_state` = '', `staff_name` = '张杰', `followName` = '', `other_payment` = '';
google搜到一个方案, http://bugs.mysql.com/bug.php?id=16559 在配置文件中加skip-slave-error=1053 (which can be used on
your slave but that is scary)
相关阅读 更多 +