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.

/tmp filling up when running repair on database

Discussion in 'General Discussion' started by encryption, Jul 29, 2007.

  1. encryption

    encryption Well-Known Member

    Joined:
    Jun 24, 2005
    Messages:
    72
    Likes Received:
    0
    Trophy Points:
    6
    Hello

    I have a client with a 1 gb MySQL DB and in the midst of running a repair on her database, the page just went blank (white) and the /tmp partition filled up, grinding a couple of other sites on server to a standstill.

    Problem is, when it timed out, it was fixing a table on her database which is now locked saying "in use" and I'm not sure I want to run another "repair" on it for the fear of affecting other clients or further ruining this table/database.

    Any guidance on how I can increase the size of the /tmp folder or what would be a potential fix.

    FYI when I click on the table in question, I see this error

    Will appreciate any help you can provide.
     
  2. outlaw web

    outlaw web Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    45
    Likes Received:
    0
    Trophy Points:
    6
    I would advise against trying to increase the size of the /temp partition.

    you'd be better to try deleting any or all unused files out of it to gain space.

    try this:

    cd /tmp | ls -la -S2 | more
    this will tell you what's eating up the space. the largest of which will be at the top.

    or

    cd /tmp
    ls -l

    Or, sort by size:
    ls -l | sort -n +4


    then it's a process of deleting the unnecessary files thst are clogging up your /temp folder.


    also the 1016 - Can't open file: 'post.MYI' (errno: 144) error will be caused most likely because the database user does not have write access to the /tmp directory on that server

    OWM
     
    #2 outlaw web, Jul 29, 2007
    Last edited: Jul 29, 2007
  3. encryption

    encryption Well-Known Member

    Joined:
    Jun 24, 2005
    Messages:
    72
    Likes Received:
    0
    Trophy Points:
    6
    Thanks for the response. The thing is the /tmp folder gets full trying to run the REPAIR command via phpmyadmin and goes back to being empty as soon as the process is terminated. Hence I asked if I could increase the size of the /tmp folder, maybe that would help executing the db REPAIR effectively.
     
  4. outlaw web

    outlaw web Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    45
    Likes Received:
    0
    Trophy Points:
    6
    #4 outlaw web, Jul 29, 2007
    Last edited: Jul 29, 2007
  5. encryption

    encryption Well-Known Member

    Joined:
    Jun 24, 2005
    Messages:
    72
    Likes Received:
    0
    Trophy Points:
    6
    Thanks for that chief, yea its a 1 gb database.
     
  6. outlaw web

    outlaw web Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    45
    Likes Received:
    0
    Trophy Points:
    6
    hmm....

    there is another option that would be more server friendly.

    get the client to download and repair the database locally on their pc....then re upload it once they've repaired it.

    OWM
     
  7. encryption

    encryption Well-Known Member

    Joined:
    Jun 24, 2005
    Messages:
    72
    Likes Received:
    0
    Trophy Points:
    6
    The screw up with that is the doing the repair the first time and getting the whitepage resulted in the posts table (which is about 750 mb) to get locked. phpmyadmin shows its "in use". So performing a backup results in getting a DB that's only 100 something MB.
     
  8. lloyd_tennison

    lloyd_tennison Well-Known Member

    Joined:
    Mar 12, 2004
    Messages:
    698
    Likes Received:
    1
    Trophy Points:
    18
    Just reassign the temp file for that session to a different partition when you are doing the repair.

    TMPDIR=/home/tmp; export TMPDIR ;

    Most people have lots of room in home.
     
Loading...

Share This Page