RESET SLAVE

Use this MySQL statement within or after the RESET MASTER statement that sets the binary logging index back to 1.

Syntax

Below is the syntax for this command. Text within square brackets (i.e, [ and ] ) are optional. Choices are separated by bars (i.e, | ). Ellipses preceded by a comma indicates a repeating pattern. Ellipses before or after syntax are used to highlight a relevant except from the larger syntax. Text displayed in italic letters represent text that should be replaced with the specific names related to the database (e.g., column with the name of the column).

RESET SLAVE

Explanation

Use this MySQL statement within or after the RESET MASTER statement that sets the binary logging index back to 1 on a server running replication. This MySQL statement will also delete the master.info file, the relay-log.info file, and all of the relay log files on the slave server. It will delete the relay log files regardless of whether the SQL thread has finish executing its contents. A new .info file will be created with the default, start-up values.

Examples

You can run the MASTER and SLAVE options together in a comma-separated list like so:

RESET MASTER, SLAVE;

This is a recommended method for ensuring consistency on MySQL servers running replication.