ERROR: Error in Log_event::read_log_event()
[root@xxxdb0402 tmp]# mysqlbinlog mysql-bin.004271 > 4.log
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
[root@xxxdb0402 tmp]# grep 'rding' 4.log > rd4.log
[root@xxxdb0402 tmp]# ll rd4.log
-rw-r--r-- 1 root root 0 Sep 3 17:50 rd4.log
空的,第四個(gè)日志沒(méi)有錄入操作
奇怪報(bào)錯(cuò)了,google之,3種方案
1 寫(xiě)全路徑
[root@xxxdb0402 tmp]# /opt/mysql/product/5.5.25a/bin/mysqlbinlog mysql-bin.004271 > 4.log
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
[root@xxxdb0402 tmp]# whereis mysqlbinlog
mysqlbinlog: /usr/bin/mysqlbinlog
[root@xxxdb0402 tmp]# /usr/bin/mysqlbinlog mysql-bin.004271 > 4.log
/usr/bin/mysqlbinlog: Character set '#45' is not a compiled character set and is not specified in the '/usr/share/mysql/charsets/Index.xml' file
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
2 加-f強(qiáng)制解析
[root@xxxdb0402 tmp]# mysqlbinlog -f mysql-bin.004271 > 4.log
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
3 這個(gè)copy過(guò)來(lái)的日志的時(shí)候,db正往日志里面寫(xiě)數(shù)據(jù)呢,從新copy下binlog到/tmp下。
那就重新copy一次binlog,再解析
[root@xxxdb0402 tmp]# cp /mysqldata/data/mysql-bin.004271 /tmp/
cp: overwrite `/tmp/mysql-bin.004271'? y
[root@xxxdb0402 tmp]# /opt/mysql/product/5.5.25a/bin/mysqlbinlog mysql-bin.004271 > 4.log
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
3種方案都報(bào)一樣的錯(cuò)誤。Mysql版本5.5.25a。linux環(huán)境centos6.0
這個(gè)問(wèn)題如何搞定,比較詭異?
朋友建議直接在mysql的數(shù)據(jù)目錄之下用mysqlbinlog試下
[root@xxxdb0402 data]# /opt/mysql/product/5.5.25a/bin/mysqlbinlog -f mysql-bin.004271 > 4.log
ERROR: Error in Log_event::read_log_event(): 'read error', data_len: 438, event_type: 2
結(jié)果還是一樣的報(bào)錯(cuò)。
相關(guān)文章
MySQL查詢重復(fù)數(shù)據(jù)(刪除重復(fù)數(shù)據(jù)保留id最小的一條為唯一數(shù)據(jù))
查重是我們?cè)诠ぷ髦薪?jīng)常會(huì)遇到的一個(gè)需求,下面這篇文章主要給大家介紹了關(guān)于MySQL查詢重復(fù)數(shù)據(jù)(刪除重復(fù)數(shù)據(jù)保留id最小的一條為唯一數(shù)據(jù))的相關(guān)資料,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面來(lái)一起學(xué)習(xí)學(xué)習(xí)吧2019-03-03MySql中 is Null段判斷無(wú)效和IFNULL()失效的解決方案
這篇文章主要介紹了MySql中 is Null段判斷無(wú)效和IFNULL()失效的解決方案,具有很好的參考價(jià)值,希望對(duì)大家有所幫助。如有錯(cuò)誤或未考慮完全的地方,望不吝賜教2021-06-06mysql制作外鍵出現(xiàn)duplicate?key?name錯(cuò)誤問(wèn)題及解決
這篇文章主要介紹了mysql制作外鍵出現(xiàn)duplicate?key?name錯(cuò)誤問(wèn)題及解決方案,具有很好的參考價(jià)值,希望對(duì)大家有所幫助。如有錯(cuò)誤或未考慮完全的地方,望不吝賜教2023-02-02MySQL數(shù)據(jù)庫(kù)之?dāng)?shù)據(jù)表操作
這篇文章主要介紹了MySQL數(shù)據(jù)庫(kù)之?dāng)?shù)據(jù)表操作,文章基于MySQL數(shù)據(jù)庫(kù)的相關(guān)資料展開(kāi)詳細(xì)的數(shù)據(jù)表操作的詳情,具有一定的參考價(jià)值,需要的小伙伴可以參考一下2022-05-05分析一條sql的性能的標(biāo)準(zhǔn)總結(jié)
在本篇文章里小編給各位分享了關(guān)于分析一條sql的性能的相關(guān)知識(shí)點(diǎn)總結(jié)內(nèi)容,有興趣的朋友們學(xué)習(xí)下。2019-07-07MySQL8.0.21安裝步驟及出現(xiàn)問(wèn)題解決方案
這篇文章主要介紹了MySQL8.0.21安裝步驟及出現(xiàn)問(wèn)題解決方案,本文通過(guò)圖文并茂的形式給大家介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2020-12-12