Extremely poor write performance in software RAID 5

modern cpus can do parity calc just fine.

more likely, writing to raid 5 requires read-modify-write of a stripe to ensure the data is consistent unless the write is “full stripe”. that’s the cause of parity raid write slowdown, not the cpu.

if your stripe sizes and block sizes don’t line up then doing writes will need a huge amount of read (and write) for small writes. i.e. poor tuning will contribute to performance issues but parity raid has some inherent performance quirks.

reads don’t have that problem.

e,g, stripe size of 64k, a 4k write requires 64k read and 64k write to the baking store. it could be much worse than that. e.g. if your raid controller is using 512b sector size on 4k sector drives on top of that, or the ssd is doing wear levelling in the background too.

ZFS and other proprietary raid types (e.g. netapp RAID-DP) circumvent that somewhat by only doing full stripe writes. maybe look up raid write amplification for more info.

2 Likes