Wednesday, November 26, 2014

Linux,Netapp luns-- Disk Alignment

In these days, I m working with Netapp Luns. 
While walking through my document archive; I have found a disk alignment approach , which can be implemented when using Netapp Luns in Linux ext3/ext4 filesystems. I want to share it with you.

Using fdisk 's expert mode in Linux , we define the disk geometry for mapped luns;

For example:

fdisk /dev/mapper/NetAppU1150g

We use "x" to go into the expert mode and set the head , sector and cylinder sizes as follows;

cylinder= (The size of disk in bytes)/512/256/56

Then we return to the normal mode and create our new partition with the default inputs.
Then we use "w" to save and exit.

Extra info:

Host file system need to be aligned with a Storage Lun, in order to achieve best performance.
This can be accomplished specifying the correct starting sector or logical block address (LBA) for the partition, and filesystem should be configured to use the same or multiple of the Storage block size..

On Linux , you can configure a partition and filesystem using fdisk (x option)

Alignment is important, and should be considered for Storage IO performance.Otherwise, you can end up with the following;

Misaligned filesystem and LUN:

It is almost equal -> doing 2 Storage IO for 1 OS IO..

No comments :

Post a Comment