mysql drop table恢复_MySQL drop database恢复(恢复方法同样适用MySQL drop table,delete,truncate table)...

昨天晚上接到一个网络服务请求,由于不小心点击了自己产品软件上面的清空数据功能(这个工具确实需要小心,在Oracle恢复案例中,也有xx企业erp该功能导致数据被删除请求恢复),导致MySQL数据库被直接drop database掉了,之前没有做任何备份,只是发生故障之后,他们立即封存现场,备份出来了ibdata1文件。接到请求之后,通过让其把ibdata1文件发给过来,通过MySQL recovery工具进行分析恢复,经过6个小时的处理,基本上实现核心数据0丢失.

解析ibdata1(innodb文件)

[root@localhost recovery_MySQL]# ./stream_parser -f /tmp/ibdata1

Opening file: /tmp/ibdata1

File information:

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

number of hard links: 1

user ID of owner: 0

group ID of owner: 0

device ID (if special file): 0

blocksize for filesystem I/O: 4096

number of blocks allocated: 36920

Opening file: /tmp/ibdata1

time of last access: 1440083236 Thu Aug 20 23:07:16 2015

File information:

time of last modification: 1440062236 Thu Aug 20 17:17:16 2015

time of last status change: 1440081904 Thu Aug 20 22:45:04 2015

ID of device containing file: 2055

inode number: 97257

protection: 100644 total size, in bytes: 18874368 (18.000 MiB)

(regular file)

number of hard links: 1

user ID of owner: 0

group ID of owner: 0

device ID (if special file): 0

blocksize for filesystem I/O: 4096

number of blocks allocated: 36920

Size to process: 18874368 (18.000 MiB)

Opening file: /tmp/ibdata1

File information:

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

number of hard links: 1

user ID of owner: 0

group ID of owner: 0

device ID (if special file): 0

blocksize for filesystem I/O: 4096

number of blocks allocated: 36920

time of last access: 1440083236 Thu Aug 20 23:07:16 2015

time of last modification: 1440062236 Thu Aug 20 17:17:16 2015

time of last status change: 1440081904 Thu Aug 20 22:45:04 2015

total size, in bytes: 18874368 (18.000 MiB)

Opening file: /tmp/ibdata1

File information:

Size to process: 18874368 (18.000 MiB)

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

time of last access: 1440083236 Thu Aug 20 23:07:16 2015

number of hard links: 1

user ID of owner: 0

time of last modification: 1440062236 Thu Aug 20 17:17:16 2015

group ID of owner: 0

time of last status change: 1440081904 Thu Aug 20 22:45:04 2015

device ID (if special file): 0

blocksize for filesystem I/O: 4096

number of blocks allocated: 36920

total size, in bytes: 18874368 (18.000 MiB)

Size to process: 18874368 (18.000 MiB)

Opening file: /tmp/ibdata1

File information:

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

number of hard links: 1

user ID of owner: 0

time of last access: 1440083236 Thu Aug 20 23:07:16 2015

group ID of owner: 0

device ID (if special file): 0

time of last modification: 1440062236 Thu Aug 20 17:17:16 2015

blocksize for filesystem I/O: 4096

time of last status change: 1440081904 Thu Aug 20 22:45:04 2015

number of blocks allocated: 36920

Opening file: /tmp/ibdata1

total size, in bytes: 18874368 (18.000 MiB)

File information:

Size to process: 18874368 (18.000 MiB)

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

number of hard links: 1

user ID of owner: 0

group ID of owner: 0

device ID (if special file): 0

time of last access: 1440083236 Thu Aug 20 23:07:16 2015

blocksize for filesystem I/O: 4096

time of last modification: 1440062236 Thu Aug 20 17:17:16 2015

number of blocks allocated: 36920

time of last status change: 1440081904 Thu Aug 20 22:45:04 2015

Opening file: /tmp/ibdata1

total size, in bytes: 18874368 (18.000 MiB)

File information:

Size to process: 18874368 (18.000 MiB)

ID of device containing file: 2055

inode number: 97257

protection: 100644 (regular file)

number of hard links: 1

user ID of owner: 0

group ID of owner: 0

device ID (if special file): 0

blocksize for fil

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值