MySQL Server Disk Usage at 100%

TLDR Problem: Oversized log file consumed all remaining space, causing service anomalies Cause: MySQL was configured with mysql-general-log enabled, without scheduled cleanup Investigation Method: Checked MySQL settings and disk space usage Solution: Set up scheduled cleanup using logrotate Scenario The MySQL Slave in the production environment regularly generates analysis reports and emails them to relevant personnel. We received a notification that reports hadn’t been received for some time. Upon logging into the host to attempt manual sending, it failed due to insufficient space. ...

2024-10-25 · 3 min · 544 words · Jun Chen