Subject: Re: disklabel cylinder off
To: None <port-alpha@netbsd.org>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: port-alpha
Date: 03/06/2000 12:54:00
> seems like the disklabel that netbsd thinks and what was on there or
> even the actual spec don't agree:

> disk: ST19171W
> bytes/sector: 512
> sectors/track: 168
> tracks/cylinder: 20
> sectors/cylinder: 3360
> cylinders: 5268
> total sectors: 17783112

> Here is from Seagate:

>                             ST-19171W

>        FORMATTED CAPACITY (MB) __________________9100

Disk manufacturers routinely quote capacities about 5% higher than
reality.  I don't quite understand why nobody has hit them with charges
of fraud, or at the very least misleading advertising....

>        AVERAGE SECTORS PER TRACK ________________168 rounded down

This matches the disklabel output above.

>        TRACKS ___________________________________105,480
>        CYLINDERS ________________________________5,274 user
>        HEADS ______PHYSICAL______________________20

The heads number matches what disklabel reported.  I don't know what
happened to the "missing" six cylinders; however, the disk better knows
what its reality is than separate doco does.  If it really bugs you,
contact Seagate and ask why the drive is reporting six cylinders fewer
than the documentation says.  (If the drive is an OEM-rebadged drive,
that could explain it; I have several ST51080Ns with SGI firmware, and
they are about 2% smaller than the one "normal" ST51080N I have.  I've
considered asking SGI if the stock firmware is available, to get that
2% back...the rebadged drives show <SGI, SEAGATE ST51080N, 0950> at
boot time, whereas the "real" ST51080N is <SEAGATE, ST51080N, 0958>.
In my case, though, it's the sec/trk number that differs, not the
cylinder count.)

If you're concerned about 5268*20*168 being less than 17783112 (which
it is, by about 0.47%), this is because the sectors/track value is not
constant across the disk, as hinted by the "AVERAGE" and "rounded down"
notes in Seagate's doco.

There is no geometry you can put in the disklabel that will be correct
for more than one notch of the disk.  Whether you want to bother trying
is, I suppose, up to you.  The host is supposed to be able to ask the
drive where its notch boundaries are, though I know of no tool that can
generate the appropriate SCSI commands (and for all I know they may not
even work, never having tried them).  Unless you put filesystem
boundaries at notch boundaries, though, it matters little.

Since the reasons for having the filesystem care about disk geometry
are less and less valid anyway these days, it's not clear to me that
it's worth bothering about.  Personally, I label my disks with nhead=32
nsect=64, which conveniently gives me 1M "cylinders".  (SCSI disks,
that is; the one IDE drive I have I don't dare mess with the geometry
settings on.)

					der Mouse

			       mouse@rodents.montreal.qc.ca
		     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B