frantisek holop wrote:
> hi there,
> 
> please compare the following for my external usb disk:
> 
> amaaq> sudo fdisk sd0
> Disk: sd0       geometry: 60801/255/63 [976768065 Sectors]
> Offset: 0       Signature: 0xAA55
>          Starting       Ending       LBA Info:
>  #: id    C   H  S -    C   H  S [       start:      size   ]
> ------------------------------------------------------------------------
>  0: 07    0   1  1 - 16317 254 63 [          63:   262148607 ] HPFS/QNX/AUX
>  1: 0C 16318   0  1 - 32635 254 63 [   262148670:   262148670 ] Win95 FAT32L
>  2: 83 32636   0  1 - 60800 254 63 [   524297340:   452470725 ] Linux files*
>  3: 00    0   0  0 -    0   0  0 [           0:           0 ] unused
> 
> 
> and the dmesg when plugged in:
> 
> umass0 at uhub3 port 4 configuration 1 interface 0
> umass0: Western Digital External HDD, rev 2.00/0.00, addr 2
> umass0: using SCSI over Bulk-Only
> scsibus1 at umass0: 2 targets
> sd0 at scsibus1 targ 1 lun 0: <WD, 5000AAJS Externa, 101a> SCSI2 0/direct 
> fixed
> sd0: 476940MB, 476940 cyl, 64 head, 32 sec, 512 bytes/sec, 976773168 sec total
> 
> 
> the cylinders, heads, sectors and the number of total sectors do not match.
> what does this mean?

It means translation is stupid, but we keep doing it. :)

60801 x 255 x 63 = 976768065
476940 x 64 x 32 = 976773120 which is actually 48 sectors shy of what
the dmesg reports.

fdisk (and the partition system it supports) is basically cylinder
oriented, so we keep talking about cylinders, even though not only has
it all been completely bogus for the last many years, but a lot of
devices now aren't even rotating...  But by nature and the way they
are handled, you can't have "fractional cylinders".

In reality, you have the number of sectors reported by dmesg, but you
can use the number reported by fdisk.  So, there are 5103 sectors you
can't use, and at half K each, that's about 2.5M of lost space on your
488,386,584k drive.  Ouch. :)

Now, before you accuse me of wasting space without caring, I do wish
to point out that the first computer I worked with with disk storage
had 90K floppy disks and 64K RAM.  I was thrilled to upgrade to a 640k
floppy disk system on the first "big" machine I owned, and when I
later installed hard disks on it, they were only twice as big as the
amount we are wasting here (5M).  In my basement is a PDP-11/23 that
can supposedly (just barely) run an early Unix on its 14" 5M drives.

So yes, it hurts to lose that much space, but they keep telling me to
get over it.

:)

Nick.

Reply via email to