Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

/var/lib/mysql question

Discussion in 'General Discussion' started by butch, Feb 22, 2004.

  1. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    156
    Hello,

    In my /var/lib/mysql directory, there are tons of HOSTNAME-bin.001, 002, 003, etc.

    Each one of these files are around 1GB and I have almost 40 of them. Is it safe to remove these files? If so, what are their purposes?

    Thanks!
     
  2. bamasbest

    bamasbest Well-Known Member

    Joined:
    Jan 10, 2004
    Messages:
    531
    Likes Received:
    0
    Trophy Points:
    166
    These are the MySql binary logfiles. You can easily delete them by logging into mysql via ssh:

    mysql -u root -p

    at the password prompt enter the mysql root password.

    then at the mysql prompt, type:

    RESET MASTER

    mysql>RESET MASTER
     
  3. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    156
    THanks.

    Now the question is why were they there? And why were each one 1GB big?

    Thanks in advance!
     
  4. bamasbest

    bamasbest Well-Known Member

    Joined:
    Jan 10, 2004
    Messages:
    531
    Likes Received:
    0
    Trophy Points:
    166
    Firstly, don't forget the colon (;) after the mysql command

    mysql> RESET MASTER;

    Secondly, the answer as to why can be found here:
    http://www.mysql.com/doc/en/Binary_log.html
     
  5. butch

    butch Active Member

    Joined:
    Jun 23, 2003
    Messages:
    42
    Likes Received:
    0
    Trophy Points:
    156
    Thanks for the info!
     
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice