Abstract
The emergence of byte-addressable non-volatile memory (NVM) has shifted the performance bottleneck from hardware to software. Traditional kernel-level file systems suffer from significant system call and virtual file system (VFS) overheads, while user-level alternatives often sacrifice data protection for speed. This paper introduces KucoFS, a collaborative file system that bridges this gap. By partitioning responsibilities between a user-level library (Ulib) for high-speed data access and a kernel-level "Master" thread for secure metadata management, KucoFS achieves up to 6x the throughput of state-of-the-art NVM file systems while maintaining robust protection against accidental metadata corruption.
Introduction
Persistent memory technologies, such as Intel Optane DC, offer near-DRAM speeds with the durability of traditional storage. However, existing software stacks struggle to keep pace. In optimized NVM file systems like NOVA, the VFS layer and system call context switching can account for over 50% of execution time. While user-level file systems bypass these overheads, they typically require granting applications write access to the entire NVM space, making the system vulnerable to "buggy pointers" that can corrupt critical metadata.
KucoFS addresses this "software bottleneck" and protection dilemma through a collaborative architecture. It enables applications to perform data operations at hardware speeds while delegating sensitive metadata updates to a protected kernel component.
System Architecture
KucoFS utilizes a "divide and conquer" approach consisting of two primary components: the Master and Ulib.
The Master is a dedicated kernel thread responsible for metadata updates (e.g., file creation, deletion) and enforcing protection. It manages a per-user file system image and controls page table permissions. To prevent corruption, KucoFS maps the NVM storage into the application's memory space as read-only by default. When a write operation is required, the Master temporarily toggles permissions or utilizes Copy-on-Write (CoW) mechanisms.
The Ulib is a user-space library linked with the application. It offloads computationally intensive tasks like pathname resolution from the kernel. By performing the search for directory paths in user space and providing pre-located addresses to the Master, Ulib significantly reduces kernel-side bottlenecks.
Key Innovations
- Direct Access Range-Locking: To coordinate concurrent writes without kernel intervention, KucoFS implements a DRAM-based ring buffer in user space. This allows threads to manage locks efficiently across different file ranges.
- Lock-Free Fast Reads: KucoFS employs 96-bit block mapping items with embedded version numbers. This allows Ulib to perform consistent, optimistic reads. If a version mismatch is detected during a read, the library knows the metadata was updated mid-operation and can retry, eliminating the need for heavy read-locks.
Evaluation and Results
KucoFS was evaluated on a server with 1.5 TB of Intel Optane DC Persistent Memory using benchmarks like FxMark, Filebench, and Redis.
The results demonstrate significant performance advantages:
- Throughput: KucoFS outperformed NOVA and PMFS by up to 6x in micro-benchmarks and showed nearly linear scalability as CPU core counts increased.
- Metadata Efficiency: Offloading pathname resolution allowed KucoFS to achieve an order of magnitude higher file creation throughput than its competitors.
- Real-World Application: In Redis SET operations, KucoFS provided a 53% throughput improvement over other NVM-aware file systems.
Conclusion and Future Work
KucoFS successfully demonstrates that a collaborative kernel/user-level design can provide both high performance and robust protection for persistent memory. While it currently focuses on protecting against accidental errors (buggy programs), future work aims to harden the system against malicious attacks and optimize the DRAM footprint of metadata. Additionally, the team plans to explore high-performance mechanisms for cross-user data sharing to overcome current POSIX-related isolation constraints.
Summary updated