Results 1 to 5 of 5
-
09-21-2011, 11:36 AM #1Disabled
- Join Date
- Jun 2001
- Posts
- 383
How to clear tmp / resize tmpDSK on CentOS
I've got a 2GB partition on my server which is running CentOS 64. There are a couple of problems I'm running into, as the disk is now 90% full.
tmpwatch 12 /tmp -- this doesn't do anything, unfortunately. I'm not sure what will clear out more space nor whether any of this is going to make any difference in the long run.
So let's talk about increasing the size of tmpDSK to, let's say 3GB or 4GB, which is rather huge but I think will solve all issues. I can't seem to follow the directions without having problems of commands not working, for example, the following.
- http://adamstechblog.com/2009/11/03/...ion-on-cpanel/
- https://support.crucialp.com/index.p...kbarticleid=36
I'd appreciate it if someone could help me with the process with CentOS 64 as it seems to be a relatively routine task that is just not so easy to accomplish. Like much in Linux, it takes a time investment and there isn't a point and click to get this done easily.
PS - it would also help to describe specifically the best way to back up the tmp directory, which I don't think was necessary the last time but you never know. Just saying "back up" didn't quite help as there seem to be many options. Many thanks for any assistance.
-
09-21-2011, 03:27 PM #2Aspiring Evangelist
- Join Date
- Aug 2003
- Posts
- 376
Can you post the output of the commands you ran so that we can see what's failing?
-
09-21-2011, 05:27 PM #3Web Hosting Master
- Join Date
- Dec 2005
- Posts
- 3,110
You shouldn't need a /tmp partition that large. If you need to increase it you are going to have the same issue again in future.
Do you have any caching going on like eaccellerator or xcache? I suspect it may be caching data into /tmp which is what is taking up all of your space.
Relocate it and you won't come across this again. It's also worth setting up a cron to flush out the cache now and again, or tweak the configuration of your caching agent so it limits how long files are cached for before they get refreshed or dropped.
-
09-21-2011, 09:47 PM #4Aspiring Evangelist
- Join Date
- Aug 2003
- Posts
- 376
Just a quick note: If the OP is a host and is using mod_fcgid for PHP, moving the eaccelerator cache dir might not be so smart. In those circumstances, /tmp is more secure, as it will be mounted noexec.
-
09-22-2011, 04:31 PM #5Junior Guru Wannabe
- Join Date
- Dec 2004
- Posts
- 39
It seems you are using cPanel. By default, it create a 500MB tmp partition. It's too small sometimes. I had increased the tmp partition on many servers by following this instruction.
(Sorry, I can't post link)
thecpaneladmin.com/increasing-size-of-tmpdsk-tmp
On centos, the command "Unmount /tmp" should be "Umount /tmp"Last edited by garconcn; 09-22-2011 at 04:34 PM.
Similar Threads
-
how to clear tmp directory ?
By ransome in forum Hosting Security and TechnologyReplies: 11Last Post: 03-21-2011, 12:17 PM -
Disk /usr/tmpDSK (/tmp) <-- cause?
By TitanJeff in forum Web HostingReplies: 4Last Post: 09-18-2010, 10:49 PM -
How Do I Resize /tmp?
By x264-BB in forum Hosting Security and TechnologyReplies: 5Last Post: 10-08-2009, 08:46 AM -
How to clear /tmp files?
By treck33 in forum Hosting Security and TechnologyReplies: 6Last Post: 09-07-2009, 11:22 AM -
How to restart server and clear tmp?
By kgp43 in forum Hosting Security and TechnologyReplies: 8Last Post: 01-13-2006, 07:22 AM