<div dir="ltr">Hi Stan, <br><br>thanks for your answer.<br><div class="gmail_extra"><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Everything begins and ends with the workload.<br>
<div class=""><br>
On 5/7/2014 7:43 AM, Marc Caubet wrote:<br>
> Hi all,<br>
><br>
> I am trying to setup a storage pool with correct disk alignment and I hope<br>
> somebody can help me to understand some unclear parts to me when<br>
> configuring XFS over LVM2.<br>
<br>
</div>I'll try.  But to be honest, after my first read of your post, a few<br>
things jump out as breaking traditional rules.<br>
<br>
The first thing you need to consider is your workload and the type of<br>
read/write patterns it will generate.  This document is unfinished, and<br>
unformatted, but reading what is there should be informative:<br>
<br>
<a href="http://www.hardwarefreak.com/xfs/storage-arch.txt" target="_blank">http://www.hardwarefreak.com/xfs/storage-arch.txt</a><br></blockquote><div><br></div><div>Basically we are moving a lot of data :) It means, parallel large files (GBs) are being written and read all the time. Basically we have a batch farm with 3,5k cores processing jobs that are constantly reading and writing to the storage pools (4PBs). Only few pools (~5% of the total) contain small files (and only small files).<br>
</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div class=""><br>
> Actually we have few storage pools with the following settings each:<br>
><br>
> - LSI Controller with 3xRAID6<br>
> - Each RAID6 is configured with 10 data disks + 2 for double-parity.<br>
> - Each disk has a capacity of 4TB, 512e and physical sector size of 4K.<br>
<br>
</div>512e drives may cause data loss.  See:<br>
<a href="http://docs.oracle.com/cd/E26502_01/html/E28978/gmkgj.html#gmlfz" target="_blank">http://docs.oracle.com/cd/E26502_01/html/E28978/gmkgj.html#gmlfz</a><br></blockquote><div><br></div><div>Haven't experienced this yet. But good to know thanks :)  On the other hand, we do not use zfs<br>
<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><br><div class="">
> - 3x(10+2) configuration was considered in order to gain best performance<br>
> and data safety (less disks per RAID less probability of data corruption)<br>
<br>
</div>RAID6 is the worst performer of all the RAID levels but gives the best<br>
resilience to multiple drive failure.  The reason for using fewer drives<br>
per array has less to do with probability of corruption, but<br>
<br>
1. Limiting RMW operations to as few drives as possible, especially for<br>
controllers that do full stripe scrubbing on RMW<br>
<br>
2.  Lowering bandwidth and time required to rebuild a dead drive, fewer<br>
drives tied up during a rebuild <br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div class=""><br>
> From the O.S. side we see:<br>
><br>
> [root@stgpool01 ~]# fdisk -l /dev/sda /dev/sdb /dev/sdc<br>
</div>...<br>
<br>
You omitted crucial information.  What is the stripe unit size of each<br>
RAID6?<br></blockquote><div><br></div><div>Actually the stripe size for each RAID6 is 256KB but we plan to increase some pools to 1MB for all their RAIDs. It will be in order to compare performance for pools containing large files and if this improves, we will apply it to the other systems in the future.<br>
</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">> The idea is to aggregate the above devices and show only 1 storage space.<br>
<div class="">
> We did as follows:<br>
><br>
> vgcreate dcvg_a /dev/sda /dev/sdb /dev/sdc<br>
> lvcreate -i 3 -I 4096 -n dcpool -l 100%FREE -v dcvg_a<br>
<br>
</div>You've told LVM that its stripe unit is 4MB, and thus the stripe width<br>
of each RAID6 is 4MB.  This is not possible with 10 data spindles.<br>
Again, show the RAID geometry from the LSI tools. <br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
When creating a nested stripe, the stripe unit of the outer stripe (LVM)<br>
must equal the stripe width of eachinner stripe (RAID6).<br></blockquote><div><br></div><div>Great. Hence, if the RAID6 stripe size is 256k then the LVM should be defined with 256k as well, isn't it? <br><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div class="">
> Hence, stripe of the 3 RAID6 in a LV.<br>
<br>
</div>Each RAID6 has ~1.3GB/s of throughput.  By striping the 3 arrays into a<br>
nested RAID60 this suggests you need single file throughput greater than<br>
1.3GB/s and that all files are very large.  If not, you'd be better off<br>
using a concatenation, and using md to accomplish that instead of LVM.<br>
<div class=""><br>
> And here is my first question: How can I check if the storage and the LV<br>
> are correctly aligned?<br>
<br>
</div>Answer is above.  But the more important question is whether your<br>
workload wants a stripe or a concatenation.<br>
<div class=""><br>
> On the other hand, I have formatted XFS as follows:<br>
><br>
> mkfs.xfs -d su=256k,sw=10 -l size=128m,lazy-count=1 /dev/dcvg_a/dcpool<br>
<br>
</div>This alignment is not correct.  XFS must be aligned to the LVM stripe<br>
geometry.  Here you apparently aligned XFS to the RAID6 geometry<br>
instead.  Why are you manually specifying a 128M log?  If you knew your<br>
workload that well, you would not have made these other mistakes.<br></blockquote><div><br></div><div>We receive several parallel writes all the time, and afaik filesystems with such write load benenfit from a larger log. 128M is the maximum log size.<br>
<br>So how XFS should be formatted then? As you specify, should be aligned with the LVM stripe, as we have a LV with 3 stripes then 256k*3 and sw=30? <br></div></div><br>Thanks a lot,<br>-- <br>Marc Caubet Serrabou<br>PIC (Port d'Informació Científica)<br>
Campus UAB, Edificio D<br>E-08193 Bellaterra, Barcelona<br>Tel: +34 93 581 33 22<br>Fax: +34 93 581 41 10<br><a href="http://www.pic.es" target="_blank">http://www.pic.es</a><br>Avis - Aviso - Legal Notice: <a href="http://www.ifae.es/legal.html" target="_blank">http://www.ifae.es/legal.html</a>
</div></div>