XRAID brings declustered parity RAID to zoned XFS
On November 13, Christoph Hellwig announced the first public release of XRAID, a declustered parity RAID implementation integrated into XFS. The announcement is not a product launch. There is no upstream submission yet, no distribution support, and no claim that the code is ready for production. What Hellwig published is a branch of xfsprogs, a set of kernel patches for review, and an invitation for wider testing. That is a modest framing for a piece of storage engineering with unusually large implications.
The two goals are narrow and ambitious at the same time. XRAID is meant to support parity RAID on zoned devices such as shingled magnetic recording (SMR) hard drives, and to provide a fast RAID implementation without the data-integrity problems that have historically come with parity RAID. Hellwig says XRAID also works on conventional hard drives and SSDs, though optimizing for SSD performance has not been a focus. Even without that optimization, he reports writes up to twenty times faster than mdraid. That number deserves scrutiny, but the architecture behind it is more interesting than the benchmark.
Why zoned storage breaks the RAID playbook
Conventional RAID assumes that every block on every member device can be overwritten in place. A parity update reads the old data and parity, computes the difference, and writes the new data and parity back to the same locations. That works because the device exposes a random-access block interface and hides its internal erase and rewrite behavior. The RAID layer does not need to know whether the underlying medium is a flash cell, a magnetic platter, or something else.
Zoned storage removes that assumption. An SMR drive exposes zones that must be written sequentially. Some zones can be appended to; others must be reset before they can be written again. The device is still a block device, but it is a block device with a direction and a frontier. Writing out of order, or rewriting a block in the middle of a zone, forces the drive to do expensive internal work or is rejected outright. The host is expected to cooperate: write sequentially, append at the zone write pointer, and reclaim whole zones when they are no longer needed.
This is why zoned storage pairs naturally with log-structured file systems and out-of-place updates. XFS on zoned devices already writes in a sequential, zone-aware way. A RAID layer sitting underneath has to preserve that behavior. If it turns a sequential stream into a scatter of in-place parity updates, it destroys the very property that makes zoned storage efficient. Traditional RAID5 or RAID6 on top of zoned drives is therefore not just slow; it can be structurally wrong.
There is a second problem, and it is the one that matters after a disk fails. Conventional parity RAID rebuilds by reading every surviving member and reconstructing the missing blocks onto a spare. The rebuild is a single sequential scan of the array, and its duration grows with the capacity of the largest member. During that window the array is degraded. If another disk fails before the rebuild finishes, the array may lose data. Large modern drives make that window long enough to be a real operational risk, which is why many teams avoid parity RAID for large pools altogether.
Declustered RAID attacks both problems at once. Instead of placing one data block and its parity on fixed devices, it spreads data and parity across many devices in a pool, using a layout that can be reconstructed in parallel. A rebuild does not have to read one spare device's worth of data from every survivor in a single pass. It can read from all devices that hold fragments of the lost data, and it can write the reconstructed fragments to all devices that have free capacity. The rebuild becomes a distributed operation rather than a serial one.
What declustering changes in practice
Hellwig's description emphasizes exactly this. XRAID can rebuild to all devices that have spare capacity, and the rebuild order is dynamic. Zones with multiple lost redundancies are rebuilt first. Data zones are rebuilt before parity zones, because reconstructing data zones first reduces the overhead of degraded reads. That ordering is a small detail with large consequences: it means the array is not simply walking a fixed rebuild plan, but prioritizing the fragments that are most at risk and the reads that are most expensive.
The layout also makes it easier to use a large number of disks in one pool. Conventional RAID groups have a fixed width. A twelve-disk RAID6 array is a twelve-disk array; adding capacity means adding another group or reshaping the array. A declustered layout can treat a pool of many devices as a single failure domain, with parity spread across the pool. That is the same idea that has been used in large storage systems for years, but it has mostly lived in proprietary or specialized software. Bringing it into XFS, under an open-source license and in the kernel's own file system, changes who can use it.
The word "declustered" can be misleading. It does not mean that data is randomly scattered with no structure. It means that the parity relationship is not tied to a fixed set of disks. The layout is still deterministic, still checksummed, and still recoverable. What changes is the granularity of failure and repair. A lost device does not force a single spare to absorb the entire rebuild; the pool repairs itself in parallel.
That parallelism is the source of the rebuild-time claim. It is also the source of the complexity. A declustered layout has to track which fragments live where, which zones are degraded, which redundancies have been lost, and which repairs are in flight. It has to do that without turning every I/O into a metadata lookup. XFS already has a sophisticated allocation and extent infrastructure, and XRAID is integrated into XFS rather than bolted on as a separate block layer. That integration is what lets the file system reason about zones, extents, and parity placement together.
Parity for data, mirrors for metadata
One of the most important design choices in the announcement is a deliberate limitation. XRAID provides parity RAID only for file data, where parity RAID works efficiently. Metadata redundancy is delegated to existing stacked Linux drivers such as MD RAID mirroring, which Hellwig describes as more suitable than parity RAID for small objects updated in place.
This is a concession to reality. Parity RAID is efficient when writes are large and sequential, because the parity computation is amortized over many blocks. It is inefficient when writes are small and random, because every small update requires a read-modify-write cycle and a parity update. File system metadata is the archetype of small, random, frequently updated objects: inodes, directory entries, allocation btrees, extent lists. Putting that traffic through parity RAID would generate a storm of partial writes and parity updates, which is exactly what zoned storage and large arrays are bad at.
Mirroring metadata is more expensive in raw capacity, but it is simpler and faster for small writes. A two-way mirror can absorb a small update without reading the other copy or recomputing parity. It also gives the file system a clear, low-latency path for critical metadata. The trade-off is that the metadata tier needs its own devices, or at least its own allocation policy, and the operator has to understand that the pool is now a stack of two different redundancy schemes.
That stacking is not unusual in Linux storage. dm-integrity, dm-crypt, MD RAID, and file systems are routinely layered. But each layer adds a place where a write can be split, reordered, or amplified. XRAID's choice to delegate metadata is a way of keeping the parity layer focused on the workload it handles well, rather than pretending that one redundancy scheme can be optimal for every object size. It is the kind of decision that makes a preview release credible: the authors are not claiming to have solved every case.
The same logic explains why XRAID is integrated into XFS rather than presented as a generic block device. A generic parity layer would have to infer which writes are data and which are metadata, or expose a complex configuration interface. XFS already knows. It can place file data on the parity pool and metadata on the mirror, and it can align writes with zone boundaries because it owns the allocation decisions. The cost is that XRAID is not a drop-in replacement for mdraid on an arbitrary file system. The benefit is that the file system and the RAID layer can cooperate instead of guessing.
Twenty times faster, with caveats
The headline claim is that writes are up to twenty times faster than mdraid, even without SSD optimization. That is a striking number, and it is worth being precise about what it can and cannot mean.
First, it is a claim from the author, not an independent benchmark. Hellwig is an experienced storage developer, and the comparison is presumably against a specific mdraid configuration on specific hardware with a specific workload. Without the full setup, the number is a signal that the architecture avoids a known bottleneck, not a guarantee that a given array will be twenty times faster.
Second, the comparison is about writes. Parity RAID writes are where conventional implementations pay the read-modify-write tax. A declustered, zone-aware layout can turn many small updates into large sequential writes, which is exactly the case where the gap should be largest. A workload that is mostly large sequential writes, or mostly reads, may see a much smaller difference. A workload that is metadata-heavy may see no benefit at all, because metadata is not on the parity pool.
Third, mdraid is a general-purpose block layer. It has to work with many file systems, many device types, and many configuration styles. XRAID is allowed to make assumptions that mdraid cannot: that the file system will write sequentially, that metadata lives elsewhere, that the pool has spare capacity for parallel rebuilds. Some of the speedup comes from the algorithm; some comes from the freedom to specialize. Both are legitimate, but they mean the comparison is not apples to apples.
Fourth, SSD performance is explicitly not a focus. On flash, the bottleneck is often the device's internal parallelism, write amplification, and garbage collection, not the RAID parity computation. A layout that is excellent for SMR drives may be neutral or worse on SSDs until it is tuned. Hellwig says XRAID works on conventional drives and SSDs, which is a compatibility statement, not a performance claim.
The right way to read the twenty-times number is as a hypothesis worth testing. If independent users reproduce a large write-throughput gain on zoned SMR arrays, that is a strong result. If the gain shrinks on other hardware, that is not a failure; it is the normal process of turning a research prototype into a general-purpose feature.
Zero to two parities, and a long road to upstream
The current implementation supports zero to two parities. That covers mirroring-like layouts with no parity, single-parity layouts comparable to RAID5, and double-parity layouts comparable to RAID6. The team experimented with the SnapRAID parity library to support three or more parities. That support is not in the current version, but it is planned, and the code is prepared for it.
Three or more parities matter for very large pools. The probability of multiple simultaneous failures grows with the number of devices, and rebuild times, even when parallel, are not zero. A pool with dozens of drives may want to survive two failures plus a third failure during repair. Double parity is often enough for small and medium pools; it is not a universal answer. The fact that the layout is prepared for additional parities, but not yet shipping them, is another sign that this is an early release rather than a finished product.
The project has been underway for a year and a half. That is a long time for a prototype and a short time for a storage format. File system on-disk formats are effectively permanent: once users have data in a format, the kernel has to be able to read it for years, and compatibility constraints accumulate. XRAID's on-disk layout, its recovery semantics, and its interaction with XFS features such as reflinks, quotas, and repair all have to be settled before an upstream submission. Hellwig is explicit that the code is not anywhere near ready for that.
What is available now is a development branch. The xfsprogs branch includes mkfs support and a new xraid utility for managing devices and inspecting an XRAID file system. Zonar, the zoned file system visualization tool, has been extended to show how each logical zone maps onto physical zones on the underlying devices. That tooling is not incidental. A declustered layout is hard to reason about without visualization; being able to see the mapping is part of making the design testable and debuggable.
Hellwig also gave a FOSSY talk in August on the topic. The slides are available; the video does not appear to be. The talk and the release together suggest a deliberate strategy: explain the design publicly, publish code that people can build and test, and collect feedback before asking the kernel community to accept a new on-disk format. That is a healthier sequence than landing a half-finished format and discovering its problems in production.
What to watch
The first thing to watch is upstream review. XRAID touches XFS, the block layer, zoned storage, and RAID semantics at once. Each of those areas has its own maintainers and its own expectations. A patch series that crosses all of them will get close scrutiny, and the review may change the design rather than merely polish it. The absence of an upstream submission is not a criticism; it is the correct state for a project that is still collecting feedback.
The second is independent testing. The twenty-times write claim, the rebuild behavior, and the metadata delegation all need to be reproduced by people who are not the author, on hardware that is not the author's. Zoned SMR drives are still a niche, and the number of people who can test a zoned XFS array with parity is small. If that number grows, the design will improve faster.
The third is the parity limit. Support for three or more parities is planned, but it is not here. Until it lands, XRAID is a two-failure solution. That is enough for many pools and not enough for the largest ones. Watch whether the SnapRAID-based work is integrated, and whether it changes the rebuild and layout code in ways that affect the current two-parity path.
The fourth is SSD behavior. Hellwig says SSD optimization is not a focus, which is honest but also a boundary. If XRAID is going to be useful beyond SMR arrays, it will need to understand flash. That may mean different layout policies, different write patterns, or simply accepting that mdraid and other layers remain the better choice for flash. Not every storage feature needs to win on every medium.
The fifth is the tooling and the format. mkfs support, the xraid utility, and Zonar visualization are the beginnings of an operational story. A storage feature becomes usable when operators can create it, inspect it, repair it, and reason about failure. Those tools will evolve alongside the kernel code, and their maturity is a better indicator of readiness than a benchmark number.
XRAID is not a drop-in replacement for mdraid, and it is not a finished file system feature. It is a serious attempt to solve a real problem: parity RAID on storage that does not behave like a random-access disk, with rebuilds that do not take forever. The design choices are conservative where they need to be and ambitious where they can afford to be. That is a reasonable combination for a first public release.
Sources
- Announcing XRAID: declustered parity RAID for zoned XFS, LWN.net, November 13, 2026.
- XRAID Declustered Parity RAID For Zoned XFS Announced, Phoronix.