Can you run NVME in RAID 0?

NVMe (Non-Volatile Memory Express) is a high-speed communication interface developed for solid state drives to maximize their performance capabilities. It allows SSDs to connect directly to the PCIe bus, bypassing the SATA bottlenecks that limit traditional SSDs. This enables extremely fast sequential read and write speeds, with top NVMe drives reaching over 7,000 MB/s.

RAID 0 (also called striping) is a configuration that splits data evenly across two or more disks. By distributing data across multiple drives, RAID 0 enables parallelization – multiple drives can read and write data simultaneously. This results in accelerated performance, as combined read/write speeds scale linearly with each additional drive added to the array.

Using NVMe and RAID 0 together offers additive performance benefits, as the raw throughput of NVMe SSDs is exponentially increased via the parallelization of RAID 0. Both technologies aim to remove storage bottlenecks and minimize latency. Their combined potential for incredible speeds is what makes NVMe RAID 0 an appealing option for certain use cases.

How NVMe Works

NVMe, which stands for Non-Volatile Memory Express, is a protocol for accessing high-speed storage media connected via PCI Express (PCIe). It was designed from the ground up to take advantage of low latency, parallel access to storage, in contrast to older protocols like SATA and SAS which were designed for HDDs.

Rather than going through a host bus adapter, NVMe storage drives connect directly to the CPU via PCIe lanes. This direct attached storage offers much higher bandwidth and lower latency. Each NVMe controller exposes multiple queues to the operating system, allowing for efficient, parallel access to data.

While SATA uses the AHCI command protocol which was designed for spinning hard drives, NVMe utilizes a streamlined command set optimized for SSDs. Commands are processed asynchronously and multiple commands can be processed simultaneously. This enables NVMe SSDs to fully utilize the parallelism provided by PCIe and the many NAND flash chips inside the drive.

Overall, the NVMe protocol takes advantage of the low latency and internal parallelism of SSDs connected via PCIe to deliver performance many times faster than SATA SSDs. The combination of streamlined software, parallel access, and fast interconnect results in ultra-fast storage perfect for demanding applications. (Source)

How RAID 0 Works

RAID 0, also known as disk striping, works by splitting data evenly across multiple drives in the array[1]. This is accomplished by dividing the data into blocks called stripes that get alternately written across the drives. For example, stripe 1 gets written to disk 1, stripe 2 to disk 2, stripe 3 to disk 1 again, and so on. By spreading data across multiple disks, RAID 0 improves overall speed and performance.

However, RAID 0 provides no redundancy. Because data is split amongst the drives with no duplication, if one drive fails, all data in the array will be lost. The more drives in the array, the higher the risk of failure. Therefore, RAID 0 is generally not recommended for critical storage needs. It’s mainly used in situations where maximum performance is needed and data backups already exist.

Combining NVMe and RAID 0

NVMe (Non-Volatile Memory Express) drives are designed to utilize the PCIe interface for much higher bandwidth and lower latency compared to traditional SATA SSDs. RAID 0 is a striping technique that splits data evenly across two or more drives. This allows reads and writes to be executed in parallel, providing improved performance.

When NVMe drives are combined in a RAID 0 array, their individual performance benefits are compounded, leading to significant gains for both sequential and random workloads. For example, two NVMe drives with sequential read speeds of 3,500 MB/s each could achieve over 7,000 MB/s in RAID 0. Similarly, random read/write IOPS can scale nearly linearly with each drive added.

According to benchmarks by Eteknix, a two drive NVMe RAID 0 array saw sequential read/write performance improvements of 83% and 75% respectively compared to a single drive. Random read/write IOPS improved by 80% and 74%. So combining top performing NVMe drives in RAID 0 can provide substantial cumulative gains.

Real-World Performance Gains

Combining NVMe drives in RAID 0 can provide substantial performance gains over SATA SSDs in certain workloads. According to benchmarks from Eteknix, a 4x NVMe RAID 0 array saw sequential read speeds over 6,500 MB/s, compared to around 550 MB/s for a SATA RAID 0 array. Write speeds were similarly impressive at nearly 5,500 MB/s for NVMe versus 500 MB/s for SATA.

These benchmark differences translate to real-world benefits for tasks like video editing, 3D rendering, scientific computing, database access, virtualization, and other demanding workloads involving large files. For example, one Reddit user reported cut render times in half when switching from SATA RAID 0 to NVMe RAID 0 on their Alienware workstation.

The extreme sequential throughput of NVMe RAID 0 makes it well-suited for working with 4K/8K video, high-resolution images, large datasets, and other media-intensive files that stress storage bandwidth.

Considerations and Requirements

Setting up NVMe RAID 0 comes with some important considerations and requirements to be aware of before getting started:

First, you will need an NVMe RAID capable motherboard or add-in controller card. Many modern motherboards have built-in support, but older boards may require a PCIe adapter card for NVMe RAID. The controller must explicitly support RAID 0 stripe arrays for NVMe drives.

You will also need at least two NVMe solid state drives to setup a RAID 0 array. More drives can be added to the array for increased performance and capacity. Just keep in mind that with RAID 0 there is no data redundancy, so more drives means a higher risk of data loss if any one drive fails.

That leads to the next consideration – backup strategy. With RAID 0 you are sacrificing redundancy and fault tolerance for speed. So it is critically important to have a solid backup plan in place. Your data should be regularly backed up to an external drive or cloud storage in case of a RAID failure. Without a backup, a single drive failure will result in complete data loss.

Additionally, for peak performance all NVMe drives should be similar in speed and capacity. Mixing drives may result in the array slowing down to the speed of the slowest drive.

Setup Guide

Here are the steps for creating a NVMe RAID 0 array in Windows 10:

1. Enter the BIOS settings on startup and enable NVMe RAID mode. This allows NVMe drives to be detected as RAID capable. Save settings and reboot. (Source)

2. At boot, press CTRL+I to enter RAID configuration. Select Create RAID Volume and add the NVMe drives you want in the array. (Source)

3. In Disk Management, the RAID 0 volume will now show up. Initialize the disk and format it with your preferred file system (NTFS recommended). The RAID 0 array is now ready for use.

For Linux, mdadm can be used to create a software NVMe RAID 0 array:

1. Install mdadm if not already present. Ensure the NVMe modules are loaded.

2. Use mdadm to create the array, specifying –level=0 for RAID 0 and the NVMe devices:

mdadm --create /dev/md0 --level=0 --raid-devices=2 /dev/nvme0n1 /dev/nvme1n1

3. Create a filesystem on the array like ext4 or xfs. The NVMe RAID 0 array can now be mounted and used.

The main BIOS settings to configure are enabling NVMe RAID mode and settings like the stripe size. Matching drive models and capacities is also recommended. This allows creating high performance NVMe RAID 0 arrays on modern systems.

Alternatives to NVMe RAID 0

While NVMe RAID 0 can provide faster speeds, there are other options that may be better suited depending on your use case and goals.

For those looking for faster speeds, using NVMe caching or tiering can provide many of the benefits of RAID 0 without some of the downsides. With caching, frequently accessed data is stored on a fast NVMe drive while bulk storage remains on slower HDDs. This provides fast access for active data without sacrificing capacity. NVMe tiering takes a similar approach, automatically moving data between tiers based on access patterns.

If redundancy is important, RAID 10 provides a good balance of speed and capacity using mirroring and striping. While not as fast as RAID 0, RAID 10 provides fault tolerance by duplicating data across drives. This comes at the cost of 50% storage efficiency, but for mission critical data, the tradeoff is often worth it.

Other options like ZFS or unRAID also allow combining NVMe and HDDs in creative ways, with optimized caching and flexible software RAID options. Evaluating your specific workflow, capacity, and redundancy needs can help determine if an alternate solution may be preferable.

In the end, NVMe RAID 0 delivers unmatched speed but has downsides. For many use cases, alternate solutions like tiering or RAID 10 can deliver great real-world performance and redundancy without resorting to striping.

Use Cases

NVMe RAID 0 can provide significant performance improvements for certain workloads that demand high throughput and low latency. Some examples of applications that can benefit from NVMe RAID 0 include:

Video Editing – The high bandwidth of NVMe RAID 0 allows for smooth playback and scrubbing of high-resolution video timelines. Transferring and rendering large video files is extremely fast. According to https://linustechtips.com , video editors saw render times decrease by 20-30% compared to a single NVMe SSD.

Databases – Database performance is often gated by storage throughput and latency. NVMe RAID 0 provides massive improvements in IOPS and bandwidth over a single drive or SATA RAID, leading to much faster query response times. https://www.eteknix.com saw SQL transaction throughput increase 150% on NVMe RAID 0.

Virtualization – Virtual machines (VMs) benefit greatly from the reduced latency of NVMe storage. NVMe RAID 0 further reduces latency while allowing far more VMs to be packed onto a host. VMs experience snappier performance and boot times. According to https://www.reddit.com/r/pcmasterrace/comments/12nmcnw/is_raid_0_with_nvme_ssds_still_considered/, users were able to run 40+ VMs smoothly on NVMe RAID 0.

Conclusion

In summary, combining NVMe and RAID 0 offers significant performance benefits but also comes with some potential drawbacks. NVMe RAID 0 can provide incredible sequential read/write speeds and IOPS, allowing you to gain performance that simply is not possible with a single NVMe drive.

However, you do sacrifice capacity and introduce a greater risk of total data loss if a drive fails. NVMe RAID 0 requires a careful backup strategy and discipline to avoid catastrophic data loss. The configuration process can also be complex, requiring RAID controller cards and software.

Going forward, NVMe technology will continue to rapidly evolve. Even faster NVMe drives are already emerging, like PCIe 4.0. As NVMe RAID becomes more accessible and affordable, expect its adoption to grow significantly. However, alternatives like larger NVMe drives will offer an easier setup and decent performance for many users.

Overall, NVMe RAID 0 offers performance that is unattainable through other means. For the right use cases, despite the risks and complexity, it represents an exciting option to take storage speeds to the next level.