Point-in-time recovery—that is,
recovery of data changes made since a given point in
time—is performed after restoring a full backup that
returns the server to its state when the backup was made.
Performing point-in-time recovery of MySQL Cluster tables with
MySQL Cluster and MySQL Cluster Replication can be accomplished
using a native
NDB data backup
(taken by issuing
CREATE BACKUP in the
ndb_mgm client) and restoring the
ndb_binlog_index table (from a dump made
To perform point-in-time recovery of MySQL Cluster, it is necessary to follow the steps shown here:
At some later point, prior to restoring the cluster, make a
backup of the
table. It is probably simplest to use
mysqldump for this task. Also back up the
binary log files at this time.
This backup should be updated regularly—perhaps even hourly—depending on your needs.
(Catastrophic failure or error occurs.)
Locate the last known good backup.
MySQL Cluster Disk Data tablespace and log files are not
must delete these manually.
Execute ndb_restore, restoring all data.
You must include the
when you run ndb_restore, so that the
ndb_apply_status table is populated
Section 17.4.19, “ndb_restore — Restore a MySQL Cluster Backup”, for
ndb_binlog_index table from
the output of mysqldump and restore the
binary log files from backup, if necessary.
Find the epoch applied most recently—that is, the
epoch column value in the
ndb_apply_status table—as the user
SELECT @LATEST_EPOCH:=MAX(epoch) FROM mysql.ndb_apply_status;
Find the latest binary log file
@FIRST_FILE) and position
Position column value) within this file
that correspond to
@LATEST_EPOCH in the
SELECT Position, @FIRST_FILE:=File FROM mysql.ndb_binlog_index WHERE epoch > @LATEST_EPOCH ORDER BY epoch ASC LIMIT 1;
Using mysqlbinlog, replay the binary log events from the given file and position up to the point of the failure. (See Section 4.6.7, “mysqlbinlog — Utility for Processing Binary Log Files”.)
See also Section 7.5, “Point-in-Time (Incremental) Recovery Using the Binary Log”, for more information about the binary log, replication, and incremental recovery.
Copyright © 1997, 2014, Oracle and/or its affiliates. All rights reserved. Legal Notices