1、逻辑备份
mysqldump -h127.0.0.1 -uroot -p -P3307 --single-transaction --all-databases > mysql.dump
2、二级制日志备份
mysqlbinlog --no-defaults --start-datetime="2015-09-06 16:00:00" --stop-datetime="2015-09-06 16:10:00" /data0/mysql/binlogs/mysql-bin.000004 > mysql.binlog
转载于:https://blog.51cto.com/aaronsa/1741480