Link to home
Start Free TrialLog in
Avatar of burnsj2
burnsj2

asked on

What is an optimal raid stripe size and ext3 stride size for a raid 1 disk array?

We operate a web photo server (Dell 1950 w/ md1000 and PERC5/E card)  The OS is Centos5 x64  

The photo server is apache.  Photos are stored on a raid1 disk array that does 90% reads, 10% writes.
Each photo has 3 sizes - thumbnail 6-8K, medium 16K-25, large 40K-100K.  Thumbnails are accessed far more frequently than other types.

There really 3 questions What is an ideal strip size for the raid array.  What ext3 stride size should be used to format the array for it to be optomized to the stripe size.

Finally, is there a linux disk bench mark tool that can disable all disk, controller and OS level caching and then randomly read files from the disk and give out put times?

Avatar of kkrans
kkrans
Flag of Sweden image

Use smaller stripe size if you want to save some space.
Use larger stripe size if you want to increase performance but you will waste some space

Your files are kind of small with only 10% of writes. I would go with 16k or 32k stripe size to get a good balance of power and economy.
Avatar of burnsj2
burnsj2

ASKER

Thanks, that helps some, can you expand on the ext3 block size and ext3 stride sizes and how they relate to the RAID stripe size.

According to the centos site http://wiki.centos.org/HowTos/Disk_Optimization that relationship is pretty important for performance, and complex.

For a 16k stripe what would the optimal ext block and  ext3 stride sizes be?
Beware, what the link above referrs to as stripe size is what most manufacturers refer to as stripe width and what they refer to as chunk size is what manufacturers refer to as stripe size.
Ya, Andy... I was a little confused after that link.

I would use smaller chunks as stripe sizes but that "format thing" is new to me :-)

Avatar of burnsj2

ASKER

I'm glad I'm not the only one confused by this.   The PERC Card reports this for my virtual disk.
Controller PERC 5/E Adapter (Not Available)
ID                  : 0
Status              : Ok
Name                : ext00
State               : Ready
Progress            : Not Applicable
Layout              : RAID-1
Size                : 136.13 GB (146163105792 bytes)
Device Name         : /dev/sdb
Type                : SAS
Read Policy         : Adaptive Read Ahead
Write Policy        : Write Back
Cache Policy        : Not Applicable
Stripe Element Size : 16 KB

With a stripe element size of 16 KB  What block and stride should I set during the Ext3 format?


How much memory does the server have?  How many unique file reads do you have?  How much memory is typically used for file cache (amount reported as "cached" in top)?

Linux caches as many files in memory as possible.  Although read performance is important, if you have enough memory and you do not have a lot of unique reads, its not  that important.

I have seen systems with 2GB of RAM and they were using 1.5GB for file cache.  Based on your files sizes that is a lot of files that you would read once from disk and never read again.  The more RAM the more files you can cache, the less you need to do real I/O.
Avatar of burnsj2

ASKER

It has 2GB of RAM, the OS is only using about 256MB so the rest is available for file cache.  We can add ram as needed, but right now I'm trying to make sure I configure my RAID arrays optimally.  The arrray of photos is 200GB and growing daily.  Ram caching alone will never be a sufficient solution.
Avatar of burnsj2

ASKER

additionally there are 4 million photos each with 3 versions (thumbnail, medium and large)  so the total number of files is around 12 million
ASKER CERTIFIED SOLUTION
Avatar of Member_2_231077
Member_2_231077

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial