- ps -ef|grep mysql 查找mysql -  - 
mysqlbinlog --base64-output=decode-rows --database=asset --start-datetime=“2022-09-29 09:30:00” --stop-datetime=“2022-09-29 09:36:00” -vv /data/mysql/3306/log/binlog/mysql-bin.000434 | more
mysqlbinlog --base64-output=decode-rows --database=asset --start-datetime=“2022-09-29 09:30:00” --stop-datetime=“2022-09-29 09:36:00” -vv /data/mysql/3306/log/binlog/mysql-bin.000434 > xxx.txt
使用行号匹配语法sed -n ‘/### UPDATE xxx.xxx /,/COMMIT/p’ xxx.txt >> b.txt
sed -n ‘54158,844483p’ xxx.txt >> b.txt
cat b.txt | sed -n ‘/###/p’ | sed ‘s/### //g;s//*./,/g;s/DELETE FROM/INSERT INTO/g;s/WHERE/SELECT/g;’ | sed -r ;s/(;23.),/1;/g’ | sed ‘s/;[0-9][0-9]=//g’ | sed ‘s/;[1-9]=//g’ > source.sql