Documentation Home
MySQL 8.0 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 47.2Mb
PDF (A4) - 47.3Mb
PDF (RPM) - 42.8Mb
HTML Download (TGZ) - 10.9Mb
HTML Download (Zip) - 10.9Mb
HTML Download (RPM) - 9.4Mb
Man Pages (TGZ) - 230.0Kb
Man Pages (Zip) - 335.5Kb
Info (Gzip) - 4.2Mb
Info (Zip) - 4.2Mb
Excerpts from this Manual

13.7.8.6 RESET Statement

RESET reset_option [, reset_option] ...

reset_option: {
    MASTER
  | SLAVE
}

The RESET statement is used to clear the state of various server operations. You must have the RELOAD privilege to execute RESET.

For information about the RESET PERSIST statement that removes persisted global system variables, see Section 13.7.8.7, “RESET PERSIST Statement”.

RESET acts as a stronger version of the FLUSH statement. See Section 13.7.8.3, “FLUSH Statement”.

The RESET statement causes an implicit commit. See Section 13.3.3, “Statements That Cause an Implicit Commit”.

The following list describes the permitted RESET statement reset_option values:

  • RESET MASTER

    Deletes all binary logs listed in the index file, resets the binary log index file to be empty, and creates a new binary log file.

  • RESET SLAVE

    Makes the slave forget its replication position in the master binary logs. Also resets the relay log by deleting any existing relay log files and beginning a new one.