1,show variables like '%log_bin%';
2. show master logs;
3. show master status;
4.查看操作的时间端的数据
mysqlbinlog --no-defaults --start-datetime="2021.02.03 16:00:00" --stop-datetime="2021.02.03 16:50:00" "/var/lib/mysql/binlog.000047" > 0203.sql
5.数据修改的过程 # 简单的一条一条恢复
#210203 16:13:29 server id 1 end_log_pos 543184060 CRC32 0x82f72cd1 Update_rows: table id 98 flags: STMT_END_F ### UPDATE `develop_v1_db`.`userinfos` ### WHERE ### @1=0 ### @2='others' ### @3='92ef8326414872919d00e48450b37d6c' ### @4='867ed24f542d34e1011dd78f8deee001' ### @5='2040-12-04 19:36:32' ### @6='2020-12-08 15:16:22' ### @7='2020-12-09 19:36:32' ### @8='wanyuanguiyi' ### @9='不要选我' ### SET ### @1=0 ### @2='Daniel' ### @3='9030821cfea073e81717c02a2607f1a8' ### @4='867ed24f542d34e1011dd78f8deee001' ### @5='2040-12-04 19:36:32' ### @6='2020-12-08 15:16:22' ### @7='2021-02-03 16:13:29' ### @8='wanyuanguiyi' ### @9='孙文'
6.尝试批量操作