Patent ID: 7231412

Claim:
A method for storing blocks of data in a RAID array, said RAID array comprising a plurality of storage devices, the method comprising: write allocating storage space in said RAID array for blocks of data to be stored in said RAID array by recording write allocated storage space, said storage space comprising storage blocks in said plurality of storage devices, wherein said write allocating includes: selecting a block of data that is to be stored in said RAID array for which storage space has not yet been allocated; determining whether said block of data is in a different file or in a different read ahead segment from a preceding block of data for which storage space in a first storage device of said plurality of storage devices in said RAID array has been write allocated; selecting storage space in a second storage device of said plurality of storage devices in said RAID array if said block of data is in a different file or is in a different read ahead segment from said preceding block, and selecting storage space in said first storage device if said block of data is not in a different file or in a different read ahead segment from said preceding block; assigning a write allocated storage block in said storage space to said block of data by associating an indicator of said write allocated storage block with said block of data; adding said block of data to a list of writable blocks of data for said storage device; determining whether all blocks of data to be stored in said RAID array have been processed, and repeating said selecting, said assigning and said adding if all of said blocks of data to be stored in said RAID array have not been processed; and writing all unwritten blocks of data in said list of writable blocks of data to storage space allocated for said blocks of data if all of said blocks of data to be stored in said RAID array have been processed.