View previous topic :: View next topic |
Author |
Message |
Nazgulled Guru
Joined: 04 Aug 2005 Posts: 485
|
Posted: Sun Dec 02, 2007 4:16 am Post subject: [SOLVED]How do I check the space used by all files/folders? |
|
|
I know this is such a trivial question but I don't know how to do it and google shows me different commands. I want to know what is the best command to show me how much space is being used by all files/folders in my Gentoo system. I need a value as accurate as possible but I don't which command should I use to do that.
Please advise...
Last edited by Nazgulled on Sun Dec 02, 2007 3:09 pm; edited 1 time in total |
|
Back to top |
|
|
OmSai l33t
Joined: 30 Sep 2007 Posts: 605 Location: Manchester, CT, USA
|
Posted: Sun Dec 02, 2007 4:31 am Post subject: |
|
|
If you don't find a command in google you can reverse find searching the concept it deals with apropos.
That command searches through the 1-line man (manual) descriptions.
Quote: | $ apropos disk
Tie::File (3pm) - Access the lines of a disk file via a Perl array
cfdisk (8) - Curses based disk partition table manipulator for Linux
df (1) - report file system disk space usage
df (1p) - report free disk space
edd_id (8) - udev callout to identify BIOS disk drives via EDD
fd (4) - floppy disk device
fdformat (8) - Low-level formats a floppy disk
fdisk (8) - Partition table manipulator for Linux
git-count-objects (1) - Count unpacked number of objects and their disk consumption
hd (4) - MFM/IDE hard disk devices
hdparm (8) - get/set hard disk parameters
initrd (4) - boot loader initialized RAM disk
mkboot (8) - makes a bootdisk
partx (8) - telling the kernel about presence and numbering of on-disk partitions
quotactl (2) - manipulate disk quota
ram (4) - ram disk device
rdev (8) - query/set image root device, RAM disk size, or video mode
sd (4) - Driver for SCSI Disk Drives
setfdprm (8) - sets user-provided floppy disk parameters
sfdisk (8) - Partition table manipulator for Linux
sync (2) - commit buffer cache to disk
sync (8) - synchronize data on disk with memory
sync_file_range (2) - sync a file segment with disk
xspirograph (6) - simulates the rotation of a disk inside a circular rim
|
|
|
Back to top |
|
|
Nazgulled Guru
Joined: 04 Aug 2005 Posts: 485
|
Posted: Sun Dec 02, 2007 12:55 pm Post subject: |
|
|
Thanks.
By the way the "apropos disk" says: "disk: nothing appropriate" :S |
|
Back to top |
|
|
format_c n00b
Joined: 16 Jul 2004 Posts: 45 Location: Germany/Hessen/Bad Koenig
|
|
Back to top |
|
|
Nazgulled Guru
Joined: 04 Aug 2005 Posts: 485
|
Posted: Sun Dec 02, 2007 1:17 pm Post subject: |
|
|
that takes a bit longer but also works...
What if I want to see which folder is the largest in the root? |
|
Back to top |
|
|
format_c n00b
Joined: 16 Jul 2004 Posts: 45 Location: Germany/Hessen/Bad Koenig
|
|
Back to top |
|
|
Nazgulled Guru
Joined: 04 Aug 2005 Posts: 485
|
Posted: Sun Dec 02, 2007 3:08 pm Post subject: |
|
|
Nevermind, there's a tool exactly for that on GNOME. |
|
Back to top |
|
|
georgir n00b
Joined: 29 Nov 2007 Posts: 9
|
Posted: Mon Dec 03, 2007 1:05 pm Post subject: |
|
|
format_c wrote: | Do not exactly know but would guess
Code: |
find / -maxdepth 1 -type d -print0 | xargs -0 du -s | sort -rn
|
!NOT TESTET!
Cheers | wow... just wow
Code: | du -s /* | sort -rn |
dude, think gloves. |
|
Back to top |
|
|
swimmer Veteran
Joined: 15 Jul 2002 Posts: 1330 Location: Netherlands
|
Posted: Mon Dec 03, 2007 5:33 pm Post subject: |
|
|
There is a very nice console program which does precisely that: sys-fs/ncdu
HTH
swimmer |
|
Back to top |
|
|
tarpman Veteran
Joined: 04 Nov 2004 Posts: 1083 Location: Victoria, BC, Canada
|
Posted: Mon Dec 03, 2007 6:43 pm Post subject: |
|
|
Nazgulled wrote: | By the way the "apropos disk" says: "disk: nothing appropriate" :S |
Try running makewhatis(8). _________________ Saving the world, one kilobyte at a time. |
|
Back to top |
|
|
format_c n00b
Joined: 16 Jul 2004 Posts: 45 Location: Germany/Hessen/Bad Koenig
|
Posted: Wed Dec 12, 2007 10:07 am Post subject: |
|
|
georgir wrote: | format_c wrote: | Do not exactly know but would guess
Code: |
find / -maxdepth 1 -type d -print0 | xargs -0 du -s | sort -rn
|
!NOT TESTET!
Cheers | wow... just wow
Code: | du -s /* | sort -rn |
dude, think gloves. |
Know about your version.
But doesn't match exactly requirements:
Nazgulled wrote: | that takes a bit longer but also works...
What if I want to see which folder is the largest in the root? |
_________________ Board - PerlCommunity.de
Links - PerlCommunity.de
Wiki - PerlCommunity.de |
|
Back to top |
|
|
|