NetBSD-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: RAIDframe and alignment on 4K-sector disks?



jdbaker%mylinuxisp.com@localhost ("John D. Baker") writes:

>According to "raidctl(8)", in the "Performance tuning" section:

>     Since the size of a `large IO' is often (currently) only 32K or 64K, on a
>     5-drive RAID 5 set it may be desirable to select a SectPerSU value of 16
>     blocks (8K) or 32 blocks (16K).  Since there are 4 data sectors per
>     stripe, the maximum data per stripe is 64 blocks (32K) or 128 blocks
>     (64K).  Again, empirical measurement will provide the best indicators of
>     which values will yield better performance.

>Which would seem to indicate "SectPerSU" refers to 512-byte sectors
>across all components (less parity).  Mind you, this was written before
>the advent of disks with 4K physical sectors, so the recommendations
>may need to be adjusted.  Also adjust for 3-disk RAID-5 rather than
>5-disk RAID-5 as described above.

RAID-5 3 disks   2 * 32K = 64k maxphys 
RAID-5 5 disks   4 * 16K = 64k maxphys 

for the said maxphys=32k case (currently true for Xen), it's only
half that.

RAID-5 3 disks   2 * 16K = 32k maxphys 
RAID-5 5 disks   4 *  8K = 32k maxphys 

>The above recommendation would seem to suggest making frag=stripe so
>that a full file system block (assuming -b 64k, or MAXPHYS) will occupy
>multiple stripes.

The recommendation for filesystem follows on the man page

     The parameters used for the file system are also critical to good
     performance.  For newfs(8), for example, increasing the block size to 32K
     or 64K may improve performance dramatically.  As well, changing the
     cylinders-per-group parameter from 16 to 32 or higher is often not only
     necessary for larger file systems, but may also have positive performance
     implications.

It says that the filesystem blocks should be aligned to the stripe size
(not stripe unit size). It doesn't talk about fragments.

There are two choices for fragments.

1. fragment == block to avoid read-modify-write cases even for fragments
2. fragment == block/8 for best space efficiency with minor performance
   degradation.


Greetings,
-- 
-- 
                                Michael van Elst
Internet: mlelstv%serpens.de@localhost
                                "A potential Snark may lurk in every tree."


Home | Main Index | Thread Index | Old Index