Welcome to Linux Forums!

With a comprehensive Linux Forum, information on various types of Linux software and many Linux Reviews articles, we have all the knowledge you need a click away, or accessible via our knowledgeable members.

Linux Forum ArticlesLinux ForumsLinux Forum DownloadsLinux Hosts
Home|Register|FAQ|Member List|Calendar|Unanswered Posts|Forum Rules|Today's Posts|Advanced Search|
SEARCH FOR IN
Go Back   Linux Forums > GNU Linux Zone > Servers
Reload this Page Drive Warning: /dev/sda2 (/var) is 82% full
Linux Forums
Linux Forums
Welcome To The Linux Forums!
Welcome to Linux Forums. We pride ourselves in being one of the largest Linux communities on the web, we encourage you to REGISTER on our forums and participate in the community. There are over 150,000 members ready to answer your questions. JOINING US today will allow you to make new posts, get support, send messages to other members and submit downloads to our downloads directory and many other great features!

Servers Anything server related, Apache, MySQL, Samba, server security, sendmail, exim, etc

Reply
 
Thread Tools Display Modes
Old 04-30-2008   #1 (permalink)
Talker
Just Joined!
 
Join Date: Apr 2008
Posts: 6
Drive Warning: /dev/sda2 (/var) is 82% full

Hi,


Can someone tell me what i should be doing in this case?
cPanel sent this notifcation..
Drive Warning: /dev/sda2 (/var) is 82% full

/var is 10GB and 82% is used up.
Here is the "du -sh *" for the var directory.
Code:
12K     account
32K     aquota.user
533M    cache
497M    cpanel
16K     crash
28K     db
28K     empty
16K     ftp
5.3G    lib
8.0K    local
36K     lock
622M    log
16K     lost+found
4.0K    mail
1.8M    named
155M    netenberg
8.0K    nis
8.0K    opt
4.0K    portsentry
8.0K    preserve
84K     profiles
20K     quota.user
780K    run
593M    spool
3.2M    tmp
8.0K    tux
15M     www
24K     yp
I guess i should be cleaning up the dir, however im not sure where and how to begin. Can someone please guide me what i should do?
Talker is offline   Reply With Quote
Old 04-30-2008   #2 (permalink)
devils casper
Ghost
 
devils casper's Avatar
 
Join Date: Jun 2006
Location: Chandigarh, INDIA
Posts: 18,057
Hi and Welcome !

Which distro are you using?
__________________
New Users: Read This First
If you woke up breathing, Congratulations! You get another chance.

devils casper is offline   Reply With Quote
Old 04-30-2008   #3 (permalink)
jledhead
Linux Engineer
 
jledhead's Avatar
 
Join Date: Oct 2004
Location: North Carolina
Posts: 778
this command was an awesome fine for me

Code:
du -k /foldername | sort -n | tail -10
finds the 10 largest folder and sorts it by size. it looks like you already have the largest offenders though:
cpanel, log, lib, and spool.

so you could start with log and see if your logs are rotating properly or just rotating out until the drive fills up. spool, do you store mail on this server, I mean do you pop or mostly webmail (so it stays on the server)
cpanel (no idea)
lib, looks like you have lots of goodies installed. maybe my command above substituting /var/lib for the foldername will tell you the biggest offenders
jledhead is offline   Reply With Quote
Old 04-30-2008   #4 (permalink)
Talker
Just Joined!
 
Join Date: Apr 2008
Posts: 6
Thanks jleadhead.

Ok....

Here are the results from
du -k /var/lib | sort -n | tail -10

Code:
62684   /var/lib/rpm
73756   /var/lib/Pegasus
132584  /var/lib/mysql/youclass_market
212888  /var/lib/mysql/fastnet_plst1
212968  /var/lib/mysql/ikarachi_ibrd1
216736  /var/lib/mysql/xresults_plst1
460844  /var/lib/mysql/traffix_mt
703472  /var/lib/mysql/imsn_imsn
5316160 /var/lib/mysql
5468052 /var/lib

I guess they are all Mysql databases ?? or are these databases using the disk temporarily?

Would it be safe to delete anything here?

Talker.
Talker is offline   Reply With Quote
Old 04-30-2008   #5 (permalink)
devils casper
Ghost
 
devils casper's Avatar
 
Join Date: Jun 2006
Location: Chandigarh, INDIA
Posts: 18,057
Quote:
Originally Posted by Talker View Post
Thanks jleadhead.

What do i have to do to reduce the DU ?
Is there any way to clean up the pop or logs as you mentioned earlier?
We can't help you unless you tell us which distro are you using.
__________________
New Users: Read This First
If you woke up breathing, Congratulations! You get another chance.

devils casper is offline   Reply With Quote
Old 04-30-2008   #6 (permalink)
Talker
Just Joined!
 
Join Date: Apr 2008
Posts: 6
Quote:
Originally Posted by devils casper View Post
We can't help you unless you tell us which distro are you using.
How can i get the distro specifically?




Here are the results from
du -k /var/lib | sort -n | tail -10

Code:
62684   /var/lib/rpm
73756   /var/lib/Pegasus
132584  /var/lib/mysql/youclass_market
212888  /var/lib/mysql/fastnet_plst1
212968  /var/lib/mysql/ikarachi_ibrd1
216736  /var/lib/mysql/xresults_plst1
460844  /var/lib/mysql/traffix_mt
703472  /var/lib/mysql/imsn_imsn
5316160 /var/lib/mysql
5468052 /var/lib

I guess they are all Mysql databases ?? or are these databases using the disk temporarily?

Would it be safe to delete anything here?

Talker.
Talker is offline   Reply With Quote
Old 04-30-2008   #7 (permalink)
devils casper
Ghost
 
devils casper's Avatar
 
Join Date: Jun 2006
Location: Chandigarh, INDIA
Posts: 18,057
Execute this
Code:
cat /etc/*release
cat /etc/*version
Post output here.
__________________
New Users: Read This First
If you woke up breathing, Congratulations! You get another chance.

devils casper is offline   Reply With Quote
Old 04-30-2008   #8 (permalink)
Talker
Just Joined!
 
Join Date: Apr 2008
Posts: 6
Quote:
Originally Posted by devils casper View Post
Execute this
Code:
cat /etc/*release
cat /etc/*version
Post output here.
CentOS release 4.6 (Final)
Talker is offline   Reply With Quote
Old 04-30-2008   #9 (permalink)
devils casper
Ghost
 
devils casper's Avatar
 
Join Date: Jun 2006
Location: Chandigarh, INDIA
Posts: 18,057
Okk ! Clean Cache files first.
Code:
su -
yum clean all
/var has library files and you should not delete those.
Remove log files if you want.
__________________
New Users: Read This First
If you woke up breathing, Congratulations! You get another chance.

devils casper is offline   Reply With Quote
Old 05-01-2008   #10 (permalink)
Talker
Just Joined!
 
Join Date: Apr 2008
Posts: 6
Quote:
Originally Posted by devils casper View Post
Okk ! Clean Cache files first.
Code:
su -
yum clean all
/var has library files and you should not delete those.
Remove log files if you want.
Thanks.. that dropped the usage down to 72%...
I dont think the log files are using much space. Anything else recommended?
Talker is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




All times are GMT. The time now is 02:08 AM.




© 2000 - 2008 - All Rights Reserved - Property of  MAS Media

Content Relevant URLs by vBSEO 3.0.0