RAID 0 is called striping because it splits (or “stripes”) data evenly across multiple disks. This is done to increase performance and capacity, but it comes at the cost of redundancy. Let’s take a deeper look at why striping is an appropriate name for this RAID level.
What is RAID 0?
RAID 0 is a type of RAID (Redundant Array of Independent Disks) that provides improved performance by distributing data across multiple disks. But unlike other RAID levels, RAID 0 does not provide any redundancy or fault tolerance.
In a RAID 0 array, data is split evenly across two or more disks in chunks called “stripes.” These stripes are then interleaved in order across the disks. This allows for concurrent disk access, which improves overall speed.
For example, in a 2-disk RAID 0 array, the first stripe would be written to disk 0, the second stripe to disk 1, the third stripe to disk 0 again, and so on. This spreads the data evenly over both disks.
Why is it called striping?
RAID 0 is called striping because of the way it stripes data across multiple disks. Each stripe is a portion of the full dataset that gets written sequentially across the disks in the array.
This stripes the data in an interleaved fashion across the disks. The visual pattern of the data layout resembles stripes, hence the name “disk striping” or simply “striping.”
Characteristics of striping
Some key characteristics of disk striping in RAID 0 include:
- Data is divided into stripes of equal size
- Stripes are distributed in order across the disks in the array
- Data is interleaved seamlessly across the disks
- Similar to spreading paint smoothly with a paint roller
This organized striping enables parallel access to the multiple disks, improving performance compared to a single disk.
Analogy of striping data
A analogy can help explain why the term striping is appropriate:
Imagine a RAID 0 array is like a group of painters working together to paint a wall. Each painter has their own paint roller and section of wall to work on. As they paint, they each move vertically down their sections in sync.
From a distance, the painted strips combine into solid, evenly coated stripes across the wall. No single painter has the full picture – the data is striped across each of their rollers.
This is analogous to how RAID 0 stripes data across multiple disks for performance.
Advantages of data striping
Striping data across multiple disks has several advantages compared to a single disk:
- Increased throughput – spreading data over multiple disks allows for concurrent access. The combined disk bandwidth is utilized.
- Faster access – multiple disks can read/write data simultaneously for faster I/O
- Larger capacity – total storage capacity is the sum of all disks in the array
By striping data evenly across multiple disks, RAID 0 makes full use of the combined storage resources in the array.
Disadvantages of data striping
Striping alone does not provide any fault tolerance. Key drawbacks include:
- No redundancy – since data is spread over disks, loss of one disk leads to total data loss
- Lower reliability – probability of array failure is much higher than a single disk
- No parity or mirroring – striping only focuses on performance, not redundancy
While striping improves speed, it comes at the cost of increased risk of catastrophic data loss if a drive fails.
When to use RAID 0 striping
Due to the tradeoffs, RAID 0 works best in certain scenarios:
- Applications where speed is crucial and redundancy is less important
- Large data sets like multimedia files that need high throughput
- Non-critical data where backups provide redundancy
- Temporary storage where data loss is low risk
The supercharged performance of RAID 0 makes it suitable for servers streaming high-bandwidth media files, fast scratch disks, and other use cases where availability and fault tolerance are secondary concerns.
Alternatives to RAID 0 striping
If redundancy and reliability are preferred over raw performance, other RAID levels are recommended instead:
- RAID 1 – Disk mirroring for fault tolerance
- RAID 5 – Block-level striping with distributed parity
- RAID 6 – Block-level striping with dual parity
- RAID 10 – Striping over mirrored disks for both speed and redundancy
These alternate RAID levels provide different tradeoffs between speed, capacity, and reliability depending on application requirements.
In summary, RAID 0 stripes data evenly across multiple disks to improve performance. This interleaved striping enables concurrent access for faster I/O. But it comes at the cost of redundancy.
The term “striping” perfectly captures the essence of how RAID 0 works – spreading data like stripes across disks. The visual parallel to painted stripes makes it easy to understand the motivation behind both the name and the technique.
While striping improves speed, it is unsuitable if reliability is paramount. The choice of RAID level involves balancing performance and fault tolerance for the application. But for workloads tolerant to outages, RAID 0 striping can provide a fast boost in throughput and capacity by spreading data evenly across disks.
|RAID 0 Advantages||RAID 0 Disadvantages|
|Increased throughput||No redundancy|
|Faster access||Lower reliability|
|Larger capacity||No parity or mirroring|
How RAID 0 striping works
Now that we’ve covered why it’s called striping, let’s look at how RAID 0 implements striping across disks:
- Data is divided into blocks called stripes that are evenly sized
- The stripes are written sequentially across the disks, with the first stripe on the first disk, second stripe on the second disk, and so on
- When the last disk is reached, the next stripe starts again at the first disk
- This continues until all data is striped evenly across the disks
The stripe size is configurable but is often set at 64KB or 128KB for optimal performance. The exact layout of the stripes depends on the number of disks in the array.
For example, here is how a RAID 0 array with 3 disks would stripe data:
|Stripe 1||Stripe 2||Stripe 3|
|Disk 1||Disk 2||Disk 3|
|Stripe 4||Stripe 5||Stripe 6|
The stripes are allocated in round-robin fashion for load balancing across disks. This balances out the workload evenly for optimal performance.
Reading data from a RAID 0 array
When data needs to be read, the file system looks up the stripe locations across the disks. The data can then be read in parallel from all disks for faster access.
For example, if stripes 1, 3, and 5 comprised a single file’s data, they could be read concurrently from all 3 disks together, improving performance.
Writing data to a RAID 0 array
New data is written in vacant stripes across the disks in circular order. This achieves uniform distribution for load balancing. Writes are also performed in parallel.
Free space is always maintained on each disk for new allocations. This prevents one disk from filling up disproportionately.
Implementing RAID 0 striping
RAID 0 can be implemented in hardware with a dedicated RAID controller, or in software via the operating system. Here are some ways to setup striping:
- Motherboard BIOS RAID – configure striping in the system BIOS settings
- Hardware RAID card – plug disks into a compatible controller card
- Operating system RAID – use software RAID built into Windows, Linux, etc
- Third-party RAID software – standalone applications like Storage Spaces, ZFS, MDADM, etc
The process involves:
- Selecting compatible disks of appropriate size
- Configuring the striping parameters (stripe size, disks used, etc)
- Initializing the RAID 0 array across the disks
- Formatting the array with a file system (NTFS, EXT4, XFS, etc)
Once the RAID 0 array is configured, the operating system can access it like any other disk volume. The striping and distribution of data across the disks is managed transparently in the background.
Expanding capacity in a RAID 0 array
To increase the storage capacity, additional disks can be added to the array. The data will start striping across the new disks in an interleaved manner.
However, existing data in the array will not automatically redistribute. Redistribution can be manually initiated if required.
Performance differences of RAID 0
The exact performance improvement from RAID 0 depends on the specific workload. Here are some general observations:
- Sequential access sees the full combined bandwidth of all disks
- Random access sees less improvement due to disk head movement
- Small writes see huge gains as they can be spread out over disks
- Large writes see relatively smaller gains as they cannot be parallelized as much
- Read performance improves linearly as load is balanced across more disks
- Write performance has diminishing returns as the disk heads become bottlenecked
In general, striping helps intensive workloads involving heavy bandwidth usage like multimedia editing, scientific computing, and data analytics. Databases can also benefit for fast writes.
Here is an example benchmark comparing the performance of a single disk vs a 2-disk RAID 0 array:
|Operation||Single Disk||2-Disk RAID 0|
|Sequential read||180 MB/s||360 MB/s|
|Sequential write||170 MB/s||340 MB/s|
|Random read||0.5 ms||0.4 ms|
|Random write||0.9 ms||0.5 ms|
For sequential transfers, bandwidth scales almost linearly. But random access gains are more modest due to mechanical limitations.
RAID 0 use cases
Here are some common use cases taking advantage of RAID 0 striping for performance:
Media editing & graphics workstations
RAID 0 enables smooth simultaneous capture/playback of uncompressed video. Large media files and project data can be striped for high speed access.
Quick number crunching of trading data requires fast I/O. Striping across flash drives can provide low latency for algorithmic trading systems.
Parallel striped access helps accelerate research simulations and data analysis pipelines in science/engineering.
Busy databases can spread tables over RAID 0 for faster queries. However, redundancy should also be considered.
Hypervisors can store virtual machine images on striped arrays to improve performance for guest VMs.
Striping game files provides faster loading. Some high end gaming PCs use multiple SSDs in RAID 0 config for extra speed.
In summary, RAID 0 stripes data across multiple disks in an interleaved layout to achieve parallel access for improved performance:
- Disk striping spreads data evenly similar to stripes of paint
- Concurrent access allows leveraging the combined bandwidth of disks
- Works best for throughput-intensive workloads that need speed
- Provides no redundancy, so backups are still required
- Fastest RAID level but increased risk of data loss if a drive fails
When selecting a RAID level, there is always a tradeoff between performance, capacity, and fault tolerance. RAID 0 focuses exclusively on performance via striping at the cost of redundancy.
For non-critical data where speed is the priority, RAID 0 striping can deliver a significant boost in bandwidth. But for reliability, other RAID levels are recommended instead.