Gentoo Archives: gentoo-user

From: Alan McKinnon <alan@××××××××××××××××.za>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] disk capacity mismatch
Date: Fri, 09 Feb 2007 09:17:38
Message-Id: 200702091109.23245.alan@linuxholdings.co.za
In Reply to: [gentoo-user] disk capacity mismatch by Michael Higgins
1 On Thursday 08 February 2007, Michael Higgins wrote:
2 > Hello, list --
3 >
4 >
5 > # df -h
6 > Filesystem Size Used Avail Use% Mounted on
7 > /dev/hda3 20G 12G 7.5G 61% /
8 > udev 236M 2.7M 233M 2% /dev
9 > shm 236M 0 236M 0% /dev/shm
10 > /dev/hda5 14G 13G 1.3G 91% /home/col/dump
11 > /dev/hda6 14G 12G 2.0G 86% /home/col/music
12 >
13 > lbg2 col # fdisk /dev/hda
14 >
15 > Command (m for help): p
16 >
17 > Disk /dev/hda: 80.0 GB, 80026361856 bytes
18 > 16 heads, 63 sectors/track, 155061 cylinders
19 > Units = cylinders of 1008 * 512 = 516096 bytes
20 >
21 > What did I do wrong? It looks like my 80 GB drive is more like 50 GB.
22 > How did I 'lose' the capacity?
23
24 No, read it again. It doesn't say 50GB.
25
26 It says (line 1) that you have an 80G disk comprising 155061 cylinders
27 (line 2), each of which are 516096 *bytes* long.
28
29 btw, lines 2 and 3 are bogus anyway, your drive doesn't look like that,
30 and no drive on the market has looked like that for more than 10 years
31 now. It actually means more something along the lines of
32
33 "Your disk is 80GB big, and to make your life easier you can consider it
34 to be made up of 155061 cylinders each 0.5M big. Other schemes exist
35 but in actual fact it's really just a long string of 156301488 sectors,
36 numbered sequentially, each one being 512 bytes long"
37
38 hth
39
40 alan
41
42
43 --
44 Optimists say the glass is half full,
45 Pessimists say the glass is half empty,
46 Developers say wtf is the glass twice as big as it needs to be?
47
48 Alan McKinnon
49 alan at linuxholdings dot co dot za
50 +27 82, double three seven, one nine three five
51 --
52 gentoo-user@g.o mailing list