这里会显示出您选择的修订版和当前版本之间的差别。
| 两侧同时换到之前的修订记录 前一修订版 后一修订版 | 前一修订版 | ||
| zh:notes:install_mysql [2022/06/05 15:26] pzczxs [Testing MySQL 8 Installation] | zh:notes:install_mysql [2023/07/30 17:38] (当前版本) pzczxs [Remove binlog files] | ||
|---|---|---|---|
| 行 57: | 行 57: | ||
| </code> | </code> | ||
| + | conf: | ||
| + | <code bash> | ||
| + | [mysqld] | ||
| + | datadir=/var/lib/mysql | ||
| + | socket=/var/lib/mysql/mysql.sock | ||
| + | log-error=/var/log/mysql/mysqld.log | ||
| + | pid-file=/run/mysqld/mysqld.pid | ||
| + | </code> | ||
| + | ===== Firewall Configuration ===== | ||
| + | [[:zh:notes:centos_mysql_remote|MySQL Remote Access]] | ||
| + | |||
| + | ===== Remove binlog files ===== | ||
| + | The location of binlog files can be shown by using the following commands.  | ||
| + | <code bash> | ||
| + | > mysql -uroot -p | ||
| + | > show binary logs; | ||
| + | </code> | ||
| + | |||
| + | The binlog files can be removed by using the following commands.  | ||
| + | <code bash> | ||
| + | > RESET MASTER; // remove all binlog files. | ||
| + | > PURGE MASTER LOGS to "binlog.000100"; // remove all binlog files before "binlog.000100" | ||
| + | > PURGE MASTER LOGS BEFORE "2023-07-28 22:00:00"; // remove all binlog files before 2023-07-28 22:00:00 | ||
| + | </code> | ||
| + | |||
| + | ~~DISCUSSION:closed~~ | ||