X
Business

WWDC 2016: Apple File System a welcome update for MacOS and iOS

Unmentioned in the WWDC keynote, but critical to MacOS, Apple is updating the 30-year-old HFS+ file system. APFS will put a modern foundation under your digital life next year. Here are the key features.
Written by Robin Harris, Contributor

Nine years ago I was pleased to see that Apple was starting to integrate the state-of-the-art ZFS file system into Snow Leopard Server. Even then the HFS+ file system, whose roots go back to file systems from the 60s, was a buggy mess.

But Mac ZFS never happened. Instead the parade of data corruption, slow Time Machine backups, limited TRIM support and other issues continued. I despaired.

Meet APFS

This month Apple introduced the bones of a new file system to its developers. The documentation says a 2017 release is planned, which means it won't become fully supported until after MacOS 10.12.1. But the MacOS's UNIX core is designed to make it easy to slide in new file systems, so APFS could become an option under later versions of Sierra.

Apple warns that APFS is in the early stages of development, so don't use it for anything important, which, since it requires MacOS Sierra, you probably won't. You can't boot from it (today) and it is case-sensitive. Time Machine, FileVault, and Fusion drives also don't work with APFS - but I trust they (or something better) will in time.

A next gen file system

APFS has some important capabilities, including

  • 64-bit inodes. APFS supports over 9 quintillion files on a single volume.
  • Nanosecond timestamp granularity. Important for proper journaling and clustered systems.
  • Copy-on-write metadata. Helps your data survive system crashes.
  • TRIM support. HFS+ has sub-optimal TRIM support. APFS handles TRIM operations asynchronously, after metadata is stored in stable media.
  • Native encryption. You can choose different encyption schemes for each APFS volume, including multi-key encryption with per-file keys for file data and a separate key for sensitive metadata.
  • Native SMB. SMB is what the non-Apple world uses to share data over networks.

New pro features

These are the features that pro users will soon grow to love.

SSD optimization. APFS works with disk drives, but offers a key new feature: write coalescing. Flash SSD writes are slow, so instead of a bunch of independent small writes, APFS will gather writes into a group and do one big write for much higher performance. Keeping track of those small writes is one reason for nanosecond timestamps.

Space sharing. APFS volumes can grow and shrink dynamically, up to the capacity limit of the underlying storage. No more repartitioning.

Cloning. Cloning is a way to create a copy of a file (or directory) without taking up more drive capacity. As the clone is modified, only modified blocks are written to new locations. This means you can have multiple versions of a file with little overhead. As a writer I've missed this feature since I stopped using VMS in 1995!

Snapshots. Long a staple of enterprise storage systems, snapshots are read only instances of your file system. As with clones, when blocks in the file system are modified, the old blocks are kept so the file system can be restored to an earlier point in time. Handy if malware pooches your Mac.

The Storage Bits take

There's more to APFS, and there's more to come. I'm curious about how APFS handles metadata, since there are magical things that other file systems do.

But after a nine year wait, I'm glad to see that Apple is moving the foundation of our data into the 21st century. They've been far behind Windows for years now, and relief is on the way. Pro users, rejoice!

Courteous comments welcome, of course.

Editorial standards