Can I just delete mysql localhost.log file
I built a system 5 years ago. These years, localhost.log in client mysql database has been accumulated to 160G. Can I just delete t开发者_Python百科his log? MySQL version is 4.0.20.
Yes. IIRC, you want to use the following procedure:
- Rename the log using
mv
orren
depending on the platform. - Use
mysqladmin flush-logs
. This should create a newlocalhost.log
- Delete the old log that you renamed.
This procedure let's you delete the log without restarting the MySQL process.
精彩评论