mod_gzip tmp folder problem

abubin

Well-Known Member
Dec 7, 2004
401
3
168
Hi,

I have configure mod_gzip to run properly but yesterday I encountered a problem where apache service was down. Cpanel was unable to restart the service because of the gzip directory getting deleted.

Following the mod_gzip howto, I had mod_gzip's temp folder stored in /tmp/gzip. The problem was that gzip was deleted which puzzled me. Is there a cronjob running somewhere that clears the tmp folder? Or will tmp get cleared everytime there's a restart?

Any of you guys having similar problem? What's your solution? putting a cronjob on creating the gzip folder everytime reboot?

Thanks in advance.
 

chirpy

Well-Known Member
Verifed Vendor
Jun 15, 2002
13,437
33
473
Go on, have a guess
You should never ever create direcories or files in /tmp that are affected by being deleted. That's why it's called a tmp directory. Yes, there's a cron job that usually calls tmpwatch that cleans up the tmp directory. If you want to specify a tmp directory, specify /tmp at the top level, not in a sub dir.

Is there a particular reason that you're enabling mod_gzip?
 

sh4ka

Well-Known Member
May 12, 2005
444
0
166
Uruguay
cPanel Access Level
DataCenter Provider
abubin said:
Hi,
Any of you guys having similar problem? What's your solution? putting a cronjob on creating the gzip folder everytime reboot?

Thanks in advance.

Yeap, same happened to me.. once by mistake I checked mod_gzip at apache recompiling from WHM and then my tmp partition was full, apache down.. and there were a rare archives that were been generated by mod_gzip, I just recompile withouth it and no more problems :)
 

abubin

Well-Known Member
Dec 7, 2004
401
3
168
chirpy said:
You should never ever create direcories or files in /tmp that are affected by being deleted. That's why it's called a tmp directory. Yes, there's a cron job that usually calls tmpwatch that cleans up the tmp directory. If you want to specify a tmp directory, specify /tmp at the top level, not in a sub dir.

Is there a particular reason that you're enabling mod_gzip?
creating that gzip folder under tmp was shown on most of the mod_gzip howto. It is supposed to let us keep track of mod_gzip's temp file usage. Anyway, after implementing mod_gzip, I do see my sites loading up much faster. I will move mod_gzip's temp folder to tmp instead to solve the problem.

Thanks for the advice.
 
Last edited: