|
|||
|
How to reduce space in /usr partition?
Hi,
There is similar thread, but I can`t find any useful information in it, so I've opened another one. My /usr partition is filling up about 5% per day. Filesystem Size Used Avail Use% Mounted on /dev/sda3 9.7G 6.6G 2.7G 72% /usr The problem is that I have no idea where/which files are filling up. I've deleted ALL logs in /usr/local/apache/domlogs but it caused like 1% of space. Here are all files which exceed 20MB on /usr /usr/lib/locale/locale-archive: 54M /usr/bin/php: 20M /usr/lib64/xulrunner-1.9/libxul.so: 23M /usr/local/apache/modules/libphp5.so: 21M /usr/local/apache/logs/error_log: 26M /usr/local/apache/logs/access_log: 31M /usr/local/cpanel/cgi-sys/php5: 20M /usr/local/cpanel/cpanel: 31M /usr/local/cpanel/whostmgr/bin/whostmgr5: 28M /usr/local/cpanel/whostmgr/bin/whostmgr: 34M /usr/local/cpanel/whostmgr/bin/whostmgr2: 35M /usr/local/cpanel/whostmgr/bin/xml-api: 27M /usr/local/cpanel/bin/wwwacct: 21M /usr/local/bin/php: 20M As you can see, there is no any big file like log or something. I've also tried to set logs in rotation(WHM) but it didn`t help either.
Last edited by tedy; 10-25-2009 at 09:00 PM. |
|
|||
|
Hi..
Please try the command below. It will find for the files consuming much disk space. Quote:
|
|
||||
|
I suggest using "du" to gradually search deeper levels of directories within the "/usr" partition.
The following command could be used as a starting point: Code:
# du -ahx --max-depth=1 /usr Code:
# du -ahx --max-depth=1 /usr/local # du -ahx --max-depth=1 /usr/local/apache # du -ahx --max-depth=1 /usr/local/apache/logs # du -ahx --max-depth=1 /usr/local/cpanel/logs Code:
# man du
__________________
For hands-on assistance please reference our new support information page: Where should I go for support? cPResources: Support Options - Additional Support Options - Forums Search - Mailing Lists(Alt) - Documentation -- cPanelDon - Donald Holl, Technical Analyst, cPanel Technical Support |
|
|||
|
Hope this helps :
1. Restart the httpd service. This might free a little space some times. 2. Check for apache logs like error_log, access_log , suexec_log in /usr/local/apache/logs . These can either be cleared off or if you need the logs then you can take a zipped copy and keep it aside. 3. Same can be done for the files in cPanel logs (/usr/local/cpanel/logs) as well . 4. Domlogs – Get into the /usr/local/apache/domlogs/ directory. Run the following command :- # ls -al -SR | head -10 —> It will list 10 files in the decreasing order according to their size If the domlog file is too large for a domain then it is possible that awstats is not running . Check whether cpanellogd is running on the server using pstree . If not, restart it . Else, it is possible that awstats for only that particular domain is not updating. Get into the directory /usr/local/cpanel/base and check if any file as ‘awstats.domainname.com.conf’ exists. If yes , delete that file. Now, run /scripts/runweblogs for that user. It will update the awstats and automatically clear the domlogs file thereafter. Do not delete the domlogs file itself. 5. Remove old and unwanted backups of ‘apache’ that might have been taken long ago. Also, check for any other duplicate folders that can be removed safely. 6. Remove core files, if any . Normally, some core files (like core.1234) might be present in /usr/local/cpanel/whostmgr/docroot . Check for these and remove them.
__________________
InstaCarma Outsourced Web Hosting Technical Support and Server Management To visit out Blog , click here |
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Reduce disc space / mysql query | oldlock | cPanel Newbies | 1 | 06-05-2009 10:41 PM |
| How to reduce space in usr partition : killall -9 httpd | sebans | cPanel and WHM Optimization | 5 | 05-15-2009 08:47 AM |
| /usr partition full | danielco | cPanel and WHM Discussions | 3 | 07-26-2008 08:17 AM |
| My /usr partition is full - what do i do? | Dragons Master | cPanel and WHM Discussions | 7 | 07-24-2005 09:46 PM |
| resize partition /usr | powerflash | cPanel and WHM Discussions | 6 | 07-07-2005 03:45 AM |