Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 7 of 7
  1. #1
    Member
    Join Date
    May 2002
    Posts
    249

    Default /tmp full! Load 3.50+! Apache down!

    Hello,

    The wierdest thing happened today.. Suddently I noticed all sites on this server were down. I checked the status page in WHM and it showes that the server load was on 3.50+ and that /tmp was 100% full. I did a 'ls -al' in /tmp and this is part of what I got.. http://www.antinetscape.org/temp/tmp_full01.gif

    What are those files? What program created those? Anyone know? As soon as I deleted all files in /tmp that started with &_&, the problem was solved. Sites were working and load went back down to normal.

  2. #2
    Member
    Join Date
    May 2002
    Posts
    152

    Default I would check my Apache logs

    If nobody owns the files, and nobody would normally have write permission in /tmp, I'd be concerned that you have a script going wild. Maybe grep through your httpd logs for &wrk&? And do the same for any other logs whose daemons run as nobody.

    And yell with what you find - this might be something we all need to keep an eye out for.

    - Jason
    Ecoutez! Ltd.
    www.ecoutez.com
    Our new Theme: www.MaxPanel.com

  3. #3
    Member
    Join Date
    May 2002
    Posts
    249

    Default

    The /tmp directory is available for everyone to write in. Apache uses it, PHP users it for sessions, uploads, etc..

  4. #4
    Member rpmws's Avatar
    Join Date
    Aug 2001
    Location
    back woods of NC, USA
    Posts
    1,858

    Default

    Often what happens is a script loops and th eoutput just continues to grow and grow which makes mod_gzip make a wrk file that grows and grows as well. Since it issn't apache that is down but mod_gzip busy here is what you need to do.

    go in /tmp

    rm * -f

    Go in WHM restart Apache.

    Do your best to find the user that crashed it. Often they will run a script and nothing comes back on the screen. He or she knows who he is on your server.
    Just keeping my "eye" on things....
    R. Paul Mathews
    RPMWS - diehard cPanel Nutcase

  5. #5
    Member
    Join Date
    May 2002
    Posts
    249

    Default

    That's true. I checked the mod_gzip configuration on the server and noticed there is no min/max limit, so now I've added these lines to it:

    mod_gzip_minimum_file_size 1024
    mod_gzip_maximum_file_size 20971520
    mod_gzip_maximum_inmem_size 2097152

    First line sets the minimum file size that is compressed to 1 KiloByte.
    Second line set the maximum file size that is compressed to 20 MegaBytes (maybe a little too high, but still a lot lower than 1 GB what do you think?).
    Third line sets the maximum in-memory file size compression to 2 MegaBytes.

    Good configuration for a shared server?

  6. #6
    Member
    Join Date
    Aug 2001
    Posts
    707

    Default

    You can also create a directory in a non-busy disk partition for *.wrk files. You need to inform apache about this:

    mod_gzip_temp_dir /home/gzip --& restart apache

    Then a cron job in /etc/crontab removes any instances of exponentially growing *.wrk files:

    0-58/2 * * * * root touch /home/gzip/tmp56.wrk
    1-59/2 * * * * root rm /home/gzip/*.wrk

    The first line will create a dummy file every 2 minutes in the temp directory. The second line makes sure any *.wrk files are removed with the same frequency.

    Just ensure the dummy file creation and the file removal times don't overlap as in the example.

  7. #7
    Member
    Join Date
    Feb 2003
    Posts
    191

    Default

    Originally posted by moronhead
    Just ensure the dummy file creation and the file removal times don't overlap as in the example.
    Sorry to be a dummy, but why do you need to create the dummy file? And would it work just as well to have a cron job delete .wrk files every 2 minutes from /tmp?
    Last edited by HostIt; 02-25-2004 at 06:25 PM.

Similar Threads & Tags
Similar threads

  1. /tmp full
    By constantine in forum Optimization
    Replies: 6
    Last Post: 10-01-2010, 12:21 AM
  2. /TMP is getting full
    By jasgot in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 02-25-2008, 09:45 PM
  3. /tmp is full, but not!
    By tutt in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 09-24-2006, 10:13 AM
  4. /tmp full again :(
    By azooz25 in forum New User Questions
    Replies: 1
    Last Post: 05-06-2005, 11:29 AM
  5. Replies: 0
    Last Post: 06-30-2003, 01:58 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube