LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Where is my disk space? (https://www.linuxquestions.org/questions/linux-general-1/where-is-my-disk-space-539969/)

librano 03-23-2007 12:57 PM

Where is my disk space?
 
Hi all!

I am not a newbie... more an average Linux user. But there is one thing that has me pretty much stumped for an explanation. I can't account for where all my disk space is. I have an Acer Aspire laptop with a 40Gbyte hard drive. Here is my partitioning scheme:

/dev/hda1 = 384.37MB Linux Swap
/dev/hda2 = 32.23GB ReiserFS w/ Ubuntu Linux
/dev/hda3 = 4.66GB ReiserFS w/ Linux Mint (Testing partition)

This adds up to 37.27GB which leaves 2.73GB gone in thin air. Gparted does not show any unused space. I understand that the manufacturers probably exagerated with the 40GB spec... but still 2.73GB!

And it doesn't end there. Gparted shows that hda2, my Ubuntu partition has 4.43GB free space with 27.79GB used. this adds up to the 32.23GB for hda2. But when I run Nautilus as root (sudo), select all files and folders in "/" , and get their Properties to see exactly how much space *everything* occupies... I get contents totaling 25.4GB! :scratch: (with some contents unreadable... i don't know what root can't read but...)

So that's another 2.39GB vanished... plus the 2.73.. makes 5.12GB! That's more than 12% of my hard drive! What's going on here? How can I reclaim my hard disk space?

Thanks in advance.

lib.

jay73 03-23-2007 01:13 PM

No, I think that's correct. As a rule of thumb, you should deduct 7% from the volume as indicated by the manufacturer. 40GB - 7% = 37.2GB.

In addition, you tend to lose more space by formatting. File systems such as ext3 (reiser, too, I guess) reserve about 5-7% for root tasks; that is space which can't be used for anything else.

moxieman99 03-23-2007 01:18 PM

Quote:

Originally Posted by librano
Hi all!

I am not a newbie... more an average Linux user. But there is one thing that has me pretty much stumped for an explanation. I can't account for where all my disk space is. I have an Acer Aspire laptop with a 40Gbyte hard drive. Here is my partitioning scheme:

/dev/hda1 = 384.37MB Linux Swap
/dev/hda2 = 32.23GB ReiserFS w/ Ubuntu Linux
/dev/hda3 = 4.66GB ReiserFS w/ Linux Mint (Testing partition)

This adds up to 37.27GB which leaves 2.73GB gone in thin air. Gparted does not show any unused space. I understand that the manufacturers probably exagerated with the 40GB spec... but still 2.73GB!

And it doesn't end there. Gparted shows that hda2, my Ubuntu partition has 4.43GB free space with 27.79GB used. this adds up to the 32.23GB for hda2. But when I run Nautilus as root (sudo), select all files and folders in "/" , and get their Properties to see exactly how much space *everything* occupies... I get contents totaling 25.4GB! :scratch: (with some contents unreadable... i don't know what root can't read but...)

So that's another 2.39GB vanished... plus the 2.73.. makes 5.12GB! That's more than 12% of my hard drive! What's going on here? How can I reclaim my hard disk space?

Thanks in advance.

lib.

------------------
Every file system creates overhead -- space taken up in order to lay out the structure of the file system itself. Your overhead loss is about right for ReiserFS from what I've been told.

NTFS (Windows) takes five to ten percent of each partition, FAT likewise, ditto EXT2 and 3.

A big part of the reason is that journaled file systems (NTFS, EXT3)take up space for the journal.

My boot partition set up under Mandriva Free 2006 was set by me at 50 megabytes. Overhead takes 5 meg (10 percent) right off the bat, and my free space percentages bear that out.

SkipDaddy 03-23-2007 01:44 PM

It's all in the semantics ...
 
This all boils down to, as most things do, our federal government. Somewhere, a while ago, they decided to change what a MB or a GB was, to make things 'easier' for everyone to understand in advertising and what not.

No longer was a KB 1024 Bytes, it is 1000 Bytes. No longer was a MB 1048576 bytes, it is 1000000 Bytes. And lo and behind, lo longer is a GB equal to 1,073,741,824 bytes, it is now just simply 1,000,000,000 Bytes.

So: Take the "40GB" advertised drive size (40,000,000,000 Bytes), divide it by a true GB, and you get...37.25 GB. I think that pretty much solves the mystery of the missing disk space.

Glad they made it "easier" for all of us. :)

librano 03-23-2007 05:34 PM

thanks for the replies... journalised file system... win some, lose some i guess... and as for the 40,000,000,000 bytes... what a rip off, don't you think...

dracolich 03-24-2007 08:57 AM

And it gets worse when you look at larger drives. I recently bought a 160GB drive and split it into two 80GB FAT32 partition. After formatting, while the partitions are still empty, I ran df -h on each and the result was 0KB used and 75GB free.

Hmm... 75x2=150, but I bought 160. Wait a sec - 150x1048576=1.57GB. Too bad I didn't get 160x1048576=1.67GB. Good thing I stopped believing every dotted i and crossed t of advertisements. I've known for a long time that they play games with numbers.

I can't complain too much. I got it on sale for $50 with instant savings. Actually, the SATA version was on sale, but I picked up the PATA version. Lucky for me OfficeMax employees don't know the difference. When it rang up full price I said "It's in the ad for $50". She looked it up and got the manager, who also checked the ad, to do the override.

pixellany 03-24-2007 09:22 AM

Quote:

Originally Posted by librano
thanks for the replies... journalised file system... win some, lose some i guess... and as for the 40,000,000,000 bytes... what a rip off, don't you think...

Not if everyone is using the same definitions....

AFAIK, all drives are spec'ed the same way--thus allowing fair comparisons.

pixellany 03-24-2007 09:30 AM

Quote:

Originally Posted by SkipDaddy
This all boils down to, as most things do, our federal government. Somewhere, a while ago, they decided to change what a MB or a GB was, to make things 'easier' for everyone to understand in advertising and what not.

I think it is more than any one government. There are international standards for units and such and "giga" is defined as 1 billion------"kilo" is 1000, etc.

The only group who EVER thought that kilo meant 1024 was the computer crowd. Remember, this is the same bunch that thinks Windows is an operating system.....;)


All times are GMT -5. The time now is 09:48 PM.