File system blocks alignment

Alexander Motin mav at FreeBSD.org
Wed Jan 6 11:12:51 UTC 2010


Dag-Erling Smørgrav wrote:
> Pieter de Goeje <pieter at degoeje.nl> writes:
>> Poul-Henning Kamp <phk at phk.freebsd.dk> writes:
>>> Ideally, newfs/UFS should do a quick test to look for any obvious
>>> boundaries, and DTRT, a nice little task for somebody :-)
>> A search for the offset for which newfs (or a simpler test) runs
>> fastest?  Interesting idea :-)
> 
> Or just default to 4 kB or even 8 kB, which has zero performance impact
> (either way) for disks with 512 B sectors.

AFAIK it is what latest Windows'es do, just with bigger value. While it
is usually good, I am not sure it is a perfect solution. These WDC HDDs
with installed "XP compatibility" jumper artificially shift addresses,
adding some offset between logical and physical sectors to fit legacy 63
sectors partition offset. Such case should be detected and handled. The
only problem is that these drives doesn't report this info now. :(

-- 
Alexander Motin


More information about the freebsd-current mailing list