Question

How can we make one database restore date to date, like "sunday to wednesday" but from one binlog file?

Thanks,
Pedro

Was it helpful?

Solution

You can use mysqlbinlog. To specify start and end dates, use the --start-datetime and --stop-datetime arguments; they are documented on the mysqlbinlog page in the MySQL Manual.

OTHER TIPS

You need to first restore your last full backup which was before the point you want to restore to. Then replay the binlogs from that point (The backup should probably have been created containing the binlog position - if not you'll have to try to work it out) up to the point you want to restore to.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top