FLUSH
Stai visualizzando una vecchia versione di questo article. Visualizza
la versione più recente.
Sintassi
FLUSH [NO_WRITE_TO_BINLOG | LOCAL] opzione [, opzione] ...
Spiegazione
L'istruzione FLUSH
pulisce o ricarica varie cache interne utilizzate da MariaDB. Per eseguire FLUSH
, occorre disporre del privilegio RELOAD
. Si veda GRANT
.
L'istruzione RESET
è simile a FLUSH
. Si veda
RESET
.
Le opzioni di FLUSH sono le seguenti:
Opzione | Spiegazione |
---|---|
CLIENT_STATISTICS | Reset client statistics (see 'show client_statistics'). |
DES_KEY_FILE | Reloads the DES key file (Specified with the --des-key-file startup option). |
HOSTS | Flush the hostname cache (used for converting ip to host names) |
INDEX_STATISTICS | Reset index statistics (see 'show index_statistics'). |
LOGS | Close and reopen all logs. Causes binary logs to rotate. |
MASTER | Depricated option, use RESET MASTER instead. |
PRIVILEGES | Reload all privileges from the privilege tables in the 'mysql' database. |
QUERY CACHE | Defragment the query cache to better utilize its memory. If you want to reset the query cache, you can do it with RESET QUERY CACHE. |
SLAVE | Depricated option, use RESET SLAVE instead. |
SLOW QUERY LOGS | Close and reopen the slow query log (but not other logs) |
STATUS | Resets all status variables that can be reset to 0 |
TABLE | Close all open tables. |
TABLES WITH READ LOCK | Closes all open tables. New tables are only allowed to be opened with read locks until an UNLOCK TABLES is given. |
TABLES WITH READ LOCK AND DISABLE CHECKPOINT | As TABLES WITH READ LOCK but also disable all checkpoint writes by transactional table engines. This is usefull when doing a disk snapshot of all tables. |
TABLE_STATISTICS | Reset table statistics (see 'show table_statistics'). |
USER_RESOURCES | Resets all per hour user resources. This enables client that has exchausted their resources to connect again. |
USER_STATISTICS | Reset user statistics (see 'show user_statistics'). |
You can also use the mysqladmin
client to flush things. Use mysqladmin --help
to examine what flush commands it supports.
Commenti
Sto caricando i commenti......
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.