Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 07-09-2003, 10:14 AM   #1
Registered: Dec 2001
Location: Scotland
Distribution: Slackware 9.1/13.37/14/14.2 RH 6.2/7/EL6.5 SuSE 8.2/11.1
Posts: 478

Rep: Reputation: 30
du alternative

Is there an alternative to using the du command to find out what disk/folder space is being used?

I find that using the du command takes forever, and that is only with 30Gb or so...

Old 07-09-2003, 11:59 AM   #2
LQ Guru
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 252Reputation: 252Reputation: 252
df -h to check in human readable format each partition, etc.

You know with the du command, you can specify a particular directory, which I believe is its main purpose. If you just want a partition output, use the df command.
Old 07-09-2003, 12:25 PM   #3
Registered: Nov 2002
Location: Central VA
Distribution: Ubuntu/Debian
Posts: 228

Rep: Reputation: 32
du -h --max-depth=X

That will display the sizes in human readable form. It will also only report X levels of depth. For example running du in my /etc path yields...
[root@localhost etc]# du -h --max-depth=1
72K     ./profile.d
12K     ./rpm
324K    ./sysconfig
48K     ./security
24K     ./skel
32K     ./X11
4.0K    ./opt
24K     ./ssl
4.0K    ./xinetd.d
8.0K    ./default
32K     ./ppp
24K     ./iproute2
52K     ./pam.d
288K    ./rc.d
44K     ./logrotate.d
20K     ./cron.daily
4.0K    ./alternatives
240K    ./makedev.d
128K    ./ssh
4.0K    ./cron.hourly
4.0K    ./cron.monthly
12K     ./cron.weekly
4.0K    ./cron.d
4.0K    ./sasl
16K     ./urpmi
220K    ./httpd
112K    ./hotplug
8.0K    ./t1lib
20K     ./devfs
88K     ./dynamic
76K     ./samba
192K    ./postfix
44K     ./openldap
20K     ./apt
892K    ./webmin
24K     ./dhcpc
4.3M    .
Old 07-09-2003, 11:28 PM   #4
Registered: May 2003
Location: S.W. Ohio
Distribution: Ubuntu, OS X
Posts: 760

Rep: Reputation: 30
du -h /home/twilli will display home dirctory and associated subdirectories. This is a long output, but not as much as the whole hardrive. Just replace twilli with your name.


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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Terragen Alternative AMMullan Linux - Software 1 09-07-2006 03:25 AM
Ghost alternative linuxmandrake Linux - Software 1 06-19-2005 09:12 PM
IE alternative jkassemi Linux - Software 12 04-11-2005 11:35 PM
alternative distro devojo Linux - Newbie 1 04-07-2005 06:55 PM
No Alternative to MS? nuka_t General 6 01-14-2005 01:32 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:05 AM.

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