Digital Marketing

The InnoDB shutdown mode innodb_fast_shutdown in MySQL

The InnoDB shutdown mode: innodb_fast_shutdown

  • If the value is 0, InnoDB does a slow shutdown, a full purge and an insert buffer merge before shutting down. 
  • If the value is 1 (the default), InnoDB skips these operations at shutdown, a process known as a fast shutdown. 
  • If the value is 2, InnoDB flushes its logs and shuts down cold, as if MySQL had crashed; no committed transactions are lost, but the crash recovery operation makes the next startup take longer.


The slow shutdown can take minutes, or even hours in extreme cases where substantial amounts of data are still buffered. Use the slow shutdown technique before upgrading or downgrading between MySQL major releases, so that all data files are fully prepared in case the upgrade process updates the file format.

Use innodb_fast_shutdown=2 in emergency or troubleshooting situations, to get the absolute fastest shutdown if data is at risk of corruption.

Comments

Popular posts from this blog

Make online money from the Internet