LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-11-2005, 10:17 AM   #1
kegwell
Member
 
Registered: Feb 2004
Distribution: Gentoo Linux
Posts: 46

Rep: Reputation: 15
Talking Disk Usage


Are there any apps out there that can tell me what files or directories are taking up the most space on my partitions? For example, lets say I have a server w/ a partition that normally sits around 75% used and one afternoon I get an alert from Nagios saying my disk is at 99%, or even worse 100%. Usually it is a log file that gets our of hand and fills of the disk. Are there any apps out there that can tell what file or directories are taking up several gigs ouf nowhere? I am aware of 'du', but I don't see any sort option. I suppose I could 'cd /; ls -R --sort=size > results.txt', but that does not seem to be a very efficient method. Any suggestions?
 
Old 05-11-2005, 10:41 AM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 256Reputation: 256Reputation: 256
Doing a ls on all files and directories would take forever and cause issues I would think.. first narrow down what directory is taking up the most space.. with either df or du on /

Then start doing your digging.. like say for instance /var is getting quite large in usage which is normal cause logs get stored there.. you could do a: du -h /var/log | sort -n

And that would sort the files and directories in order, smallest to largest, etc.
 
Old 05-11-2005, 10:59 AM   #3
kegwell
Member
 
Registered: Feb 2004
Distribution: Gentoo Linux
Posts: 46

Original Poster
Rep: Reputation: 15
Ahh...pipe to sort...that has potential ;-), thanks.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LQ disk usage student04 LQ Suggestions & Feedback 4 10-24-2004 09:35 PM
AS 2.1 disk usage buck2bcr Red Hat 4 03-23-2004 09:50 AM
101% disk usage on an empty disk tsiuser Linux - Software 3 01-28-2004 06:24 PM
Disk Usage LinuxTiro Linux - Newbie 6 09-03-2003 09:12 PM
Disk Usage dvong3 Linux - Software 2 06-13-2003 12:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration