The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Contents of /var/lib/mysql - Huge log files?

Discussion in 'General Discussion' started by muppsy007, Sep 9, 2009.

  1. muppsy007

    muppsy007 Member

    Joined:
    Dec 10, 2008
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Hi there,

    I've been searching for this high and low and can't find it either here or Google, which is surprising given I would have thought it were a common problem.

    Basically we have been have periodic issues where cPanel WHM would not load certain pages because /var/lib was full. We have a 2.5GB partition for this dir.

    What I have found is that there are some large files automatically appearing in var/lib/mysql in the format 0.000001, 0.000002 and so on. When I VI one of these files, It's not a text file of any sort, there appears to be formatting in there. But I can make out queries relating to client sites in there.

    So first question: What are these files?

    Next, are they needed and is there a way to turn them off. One of them is close to 600mb after 5 days.

    Cheers
    Aaron
     
  2. MattCurry

    MattCurry Well-Known Member

    Joined:
    Aug 18, 2009
    Messages:
    275
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Houston, Tx
    /var/lib/mysql

    Hello,

    You can remove them. They are logging binary files for MySQL and really useful if you do any replication.

    edit /etc/my.cnf

    # log-bin
    # server-id=1

    save close and stop mysql

    remove those bin files in /var/lib/mysql
    then restart mysql

    Please let me know if this wasn't the information you are looking for so we can get you fixed up.

    Thank you,
    Matthew Curry
    :D
     
  3. muppsy007

    muppsy007 Member

    Joined:
    Dec 10, 2008
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Hi Matthew,

    I take it you mean comment those lines out of my.cnf. However I do not have these lines in there. Here are the full contents of my.cnf:

    [mysqld]
    set-variable = max_connections=500
    safe-show-database
    log-bin = 0

    Do I still comment out the log-bin line?

    Cheers
    Aaron
     
  4. muppsy007

    muppsy007 Member

    Joined:
    Dec 10, 2008
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    BUMP.

    Does anyone know how to turn these off given the above contents of my.conf?

    Cheers
    Aaron
     
Loading...

Share This Page