<div dir="ltr">Hi Mike,<br><br>thanks a lot 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">
<div class="">
> 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>
> 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>
> - 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>What is the chunk size used for these RAID6 devices?<br>
Say it is 256K, you have 10 data devices, so the full stripe would be<br>
2560K.<br></blockquote><div><br></div><div>Actually chunk size is 256KB (in a near future we will try 1MB as we are managing large files but actually we want to keep the current configuration of 256KB)<br></div><div><br>
</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Which version of lvm2 and kernel are you using?  Newer versions support<br>
a striped LV stripesize that is not a power-of-2.<br></blockquote><div><br>Current LVM2 version is  lvm2-2.02.100-8.el6.x86_64<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="">
> >From the O.S. side we see:<br>
><br>
> [root@stgpool01 ~]# fdisk -l /dev/sda /dev/sdb /dev/sdc<br>
><br>
> Disk /dev/sda: 40000.0 GB, 39999997214720 bytes<br>
> 255 heads, 63 sectors/track, 4863055 cylinders<br>
> Units = cylinders of 16065 * 512 = 8225280 bytes<br>
> Sector size (logical/physical): 512 bytes / 4096 bytes<br>
> I/O size (minimum/optimal): 4096 bytes / 4096 bytes<br>
> Disk identifier: 0x00000000<br>
><br>
> Disk /dev/sdb: 40000.0 GB, 39999997214720 bytes<br>
> 255 heads, 63 sectors/track, 4863055 cylinders<br>
> Units = cylinders of 16065 * 512 = 8225280 bytes<br>
> Sector size (logical/physical): 512 bytes / 4096 bytes<br>
> I/O size (minimum/optimal): 4096 bytes / 4096 bytes<br>
> Disk identifier: 0x00000000<br>
><br>
> Disk /dev/sdc: 40000.0 GB, 39999997214720 bytes<br>
> 255 heads, 63 sectors/track, 4863055 cylinders<br>
> Units = cylinders of 16065 * 512 = 8225280 bytes<br>
> Sector size (logical/physical): 512 bytes / 4096 bytes<br>
> I/O size (minimum/optimal): 4096 bytes / 4096 bytes<br>
> Disk identifier: 0x00000000<br>
><br>
> The idea is to aggregate the above devices and show only 1 storage space.<br>
> 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>I'd imagine you'd want the stripesize of this striped LV to match the<br>
underlying RAID6 stripesize no?  So 2560K, e.g. -i 3 -I 2560<br>
<br>
That makes for a very large full stripe through...<br></blockquote><div><br></div><div> Hence for a RAID6 with 256KB of stripe size "I" should be 2560. Does it mean that the "I" parameter is stripesize*number_of_data_disks? I mean, if I have 16 data disks in a RAID6 and 1MB of stripe size, which should be the "I" value?<br>
<br>On the other hand, yes, 2560 is a large full stripe but we are mostly managing large files (hundred MBs and few GB), so I guess this is ok. Is possible to check the minimum recommended file size for a configuration like this? I would like to know it because we also have few storage pools (less than 3% of the total) we a small file profile and I would like to fit the disk configuration to its workload type.<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>
> And here is my first question: How can I check if the storage and the LV<br>
> are correctly aligned?<br>
><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>
> So my second question is, are the above 'su' and 'sw' parameters correct on<br>
> the current LV configuration? If not, which values should I have and why?<br>
> AFAIK su is the stripe size configured in the controller side, but in this<br>
> case we have a LV. Also, sw is the number of data disks in a RAID, but<br>
> again, we have a LV with 3 stripes, and I am not sure if the number of data<br>
> disks should be 30 instead.<br>
<br>
</div>Newer versions of mkfs.xfs _should_ pick up the hints exposed (as<br>
minimum_io_size and optimal_io_size) by the striped LV.<br>
<br>
But if not you definitely don't want to be trying to pierce through the<br>
striped LV config to establish settings of the underlying RAID6.  Each<br>
layer in the stack should respect the layer beneath it.  So, if the<br>
striped LV is configured how you'd like, you should only concern<br>
yourself with the limits that have been established for the topmost<br>
striped LV that you're layering XFS on.<br>
</blockquote></div><br>Current XFS package has the version xfsprogs-3.1.1-14.el6.x86_64 and comes with Scientific Linux 6. Then, how should I manage the XFS 'su' and 'sw' parameters from the LVM2 configuration in order to ensure disk alignment in order to have best performance? <br>
<br></div><div class="gmail_extra">Once again, thanks a lot for you help,<br></div><div class="gmail_extra">-- <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>