Linux Ask!

Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.

Jan 012010

MySQL binary log files take all of my disk space


If you have enabled binary log in your MySQL server, most likely you are using the replication feature. You don't need to keep the binary log forever, so in the my.cnf, add the line

expire_logs_days = 10

So your MySQL server (master) would keep at most binary log for 10 days. (Notes: you might need to adjust this value, make sure your MySQL slave is able to catch up the updates within 10 days)

However, if you are not using replication, you can consider disable the binary log, e.g. edit the my.cnf, comment out the "log-bin"

# log-bin

 Leave a Reply



You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>