Now let’s see the numbers we have with four-disk arrays in the WriteThrough mode:

To compare the speeds of the RAID arrays in different caching modes, we fill the table with ratios of the controller’s speed in the WB mode to its speed in the WT mode. A higher number indicates higher efficiency of WB caching in this mode. If the number is below 1 (marked with red), WB caching is harmful. If the number is above 1 (marked with blue), WB caching brings a performance gain. If you see “1.0”, then WB and WT caching modes are equally useful.

As you see, you can only reduce the speed of the RAID array by enabling WT caching in the controller’s BIOS. We see no speed growth even in the Random Read mode (when there are no write requests at all), while in the Random Write mode the speed degenerates by a factor of six in some cases. Only the RAID5 array speeds up with WT caching at requests queue = 256, but such a long queue is highly improbable in real operation.
The results we got with different caching modes are better viewed as graphs. We drew three of them, for three queue depths (1, 16 and 256 requests).



The RAID0 is losing in speed as we switch the caching mode from WB to WT and increase the share of writes (the maximum loss amounts to 600%). As the number of requests in the queue grows, the gap between WriteBack and WriteThrough modes becomes smaller, but the advantages of WB caching are perfectly seen everywhere, save for the Random Read mode where there’re no write requests and, accordingly, there’s nothing to optimize!



