LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Hard drive size? (http://www.linuxquestions.org/questions/linux-newbie-8/hard-drive-size-86812/)

tgardner 08-28-2003 09:20 PM

Hard drive size?
 
Is there a linux command to will tell the size (capacity) of a drive?

MasterC 08-28-2003 09:26 PM

df -h

It will need to be mounted, otherwise you can:
fdisk -l

To display the cylinders and such...

Other options might be to check the BIOS, it usually reports the size in there.

Cool

Selos 08-28-2003 09:28 PM

could he use du / -bh | more too?

i tried it just before and because of the access denied i think you have to type this as root

MasterC 08-28-2003 09:31 PM

That doesn't really provide general information on the entire drive though, that lists how much each folder holds, but it's a good command nonetheless ;)

df is for the entire mounted partition, du is for directories.

And as a side note:
more is not as good as less. Less is a more versatile text reader, IMHO..

Cool

Selos 08-28-2003 09:46 PM

Quote:

Originally posted by MasterC
but it's a good command nonetheless ;)

yep, your signature holds some very interesting links but i did not finish the commands page yet :)


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