Jump to content

Apple File System: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
m Minor grammar tweak
Tags: Visual edit Mobile edit Mobile web edit
Line 57: Line 57:


== Limitations ==
== Limitations ==
Apple File System does not provide checksums for user data, but does for metadata integrity.<ref>[https://arstechnica.com/apple/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/ A ZFS developer’s analysis of the good and bad in Apple’s new APFS file system] {{webarchive|url=https://web.archive.org/web/20170202044416/https://arstechnica.com/apple/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/ |date=February 2, 2017|df=mdy-all}}</ref> It also does not take advantage of byte-addressable [[non-volatile random-access memory]],<ref>[http://www.zdnet.com/article/why-apples-apfs-wont-last-30-years/ Why Apple's APFS won't last 30 years] {{webarchive|url=https://web.archive.org/web/20170406190806/http://www.zdnet.com/article/why-apples-apfs-wont-last-30-years/|date=April 6, 2017|df=mdy-all}}</ref> and does not support [[data compression|compression]] yet.<ref name=leventhalOverview>{{cite web | url=http://dtrace.org/blogs/ahl/2016/06/19/apfs-part1/ | author=Adam Leventhal | title=APFS in Detail: Overview | date=June 19, 2016 | accessdate=October 1, 2017 | df=mdy-all}}</ref>
Apple File System does not provide checksums for user data, but does for metadata integrity.<ref>[https://arstechnica.com/apple/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/ A ZFS developer’s analysis of the good and bad in Apple’s new APFS file system] {{webarchive|url=https://web.archive.org/web/20170202044416/https://arstechnica.com/apple/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/ |date=February 2, 2017|df=mdy-all}}</ref> It also does not take advantage of byte-addressable [[non-volatile random-access memory]],<ref>[http://www.zdnet.com/article/why-apples-apfs-wont-last-30-years/ Why Apple's APFS won't last 30 years] {{webarchive|url=https://web.archive.org/web/20170406190806/http://www.zdnet.com/article/why-apples-apfs-wont-last-30-years/|date=April 6, 2017|df=mdy-all}}</ref> and does not yet support [[data compression|compression]].<ref name=leventhalOverview>{{cite web | url=http://dtrace.org/blogs/ahl/2016/06/19/apfs-part1/ | author=Adam Leventhal | title=APFS in Detail: Overview | date=June 19, 2016 | accessdate=October 1, 2017 | df=mdy-all}}</ref>


Unlike versions of HFS+ since Leopard, APFS has no support for [[hard link]]s to directories.<ref name="appleApfsFaq2018">{{cite web|title=Apple File System Guide / Frequently Asked Questions|url=https://developer.apple.com/library/content/documentation/FileManagement/Conceptual/APFS_Guide/FAQ/FAQ.html|accessdate=May 25, 2018|df=mdy-all}}</ref><ref name="zfs-developers-analysis">{{cite web|last=Leventhal|first=Adam H.|url=https://arstechnica.com/gadgets/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/|title=A ZFS developer’s analysis of the good and bad in Apple’s new APFS file system|quote=APFS right now is incompatible with Time Machine due to the lack of directory hard links, a fairly disgusting implementation that likely contributes to Time Machine's questionable reliability.|website=[[Ars Technica]]|date=June 26, 2016}}</ref> This is in line with many other modern file systems, but [[Time Machine (macOS)|Time Machine]] still relies on them, so APFS is not yet an option for its backup volumes (as of macOS 10.14 Mojave).<ref>{{cite web|title=Disks you can use with Time Machine|url=https://support.apple.com/guide/mac-help/disks-you-can-use-with-time-machine-mh15139/mac|accessdate=December 10, 2017|df=mdy-all}}</ref><ref name="zfs-developers-analysis"/>
Unlike versions of HFS+ since Leopard, APFS has no support for [[hard link]]s to directories.<ref name="appleApfsFaq2018">{{cite web|title=Apple File System Guide / Frequently Asked Questions|url=https://developer.apple.com/library/content/documentation/FileManagement/Conceptual/APFS_Guide/FAQ/FAQ.html|accessdate=May 25, 2018|df=mdy-all}}</ref><ref name="zfs-developers-analysis">{{cite web|last=Leventhal|first=Adam H.|url=https://arstechnica.com/gadgets/2016/06/a-zfs-developers-analysis-of-the-good-and-bad-in-apples-new-apfs-file-system/|title=A ZFS developer’s analysis of the good and bad in Apple’s new APFS file system|quote=APFS right now is incompatible with Time Machine due to the lack of directory hard links, a fairly disgusting implementation that likely contributes to Time Machine's questionable reliability.|website=[[Ars Technica]]|date=June 26, 2016}}</ref> This is in line with many other modern file systems, but [[Time Machine (macOS)|Time Machine]] still relies on them, so APFS is not yet an option for its backup volumes (as of macOS 10.14 Mojave).<ref>{{cite web|title=Disks you can use with Time Machine|url=https://support.apple.com/guide/mac-help/disks-you-can-use-with-time-machine-mh15139/mac|accessdate=December 10, 2017|df=mdy-all}}</ref><ref name="zfs-developers-analysis"/>

Revision as of 00:31, 9 June 2019

APFS
Developer(s)Apple Inc.
Full nameApple File System
IntroducedMarch 27, 2017 with iOS 10.3
Partition IDs7C3457EF-0000-11AA-AA11-00306543ECAC (GPT)
Structures
Directory contentsB-tree[1]
Limits
Max file size8 EiB (263 bytes)[2]
Max no. of files263 [2]
Allowed filename
characters
Unicode 9.0 encoded in UTF-8[3]
Features
Dates recordedaccess, attributes modified, contents modified, created
Date rangeJanuary 1, 1970 – July 21, 2554[1]
Date resolution1 ns[2]
File system
permissions
Unix permissions, NFSv4 ACLs
Transparent
compression
Yes[4]
Transparent
encryption
Yes[5]
Copy-on-writeYes[3][5]
Other
Supported
operating systems
macOS, iOS, tvOS, watchOS and audioOS

Apple File System (APFS) is a proprietary file system for macOS High Sierra (10.13) and later, iOS 10.3 and later, tvOS 10.2 and later,[6] and watchOS 3.2 and later,[7] developed and deployed by Apple Inc.[8][9] It aims to fix core problems of HFS+ (also called Mac OS Extended), APFS's predecessor on these operating systems. Apple File System is optimized for flash and solid-state drive storage, with a primary focus on encryption.[10][11]

History

Apple File System was announced at Apple's developers conference (WWDC) in June 2016 as a replacement for HFS+, which had been in use since 1998.[10][11] APFS was released for 64-bit iOS devices on March 27, 2017, with the release of iOS 10.3, and for macOS devices on September 25, 2017, with the release of macOS 10.13.[12][7]

Design

The file system can be used on devices with relatively small or large amounts of storage. It uses 64-bit inode numbers,[2] and allows for more secure storage. The APFS code, like the HFS+ code, uses the TRIM command, for better space management and performance. It may increase read-write speeds on iOS and macOS,[7] as well as space on iOS devices, due to the way APFS calculates available data.[13]

Clones

Clones allow the operating system to make efficient file copies on the same volume without occupying additional storage space. Changes to a cloned file are saved as deltas, reducing storage space required for document revisions and copies.[9]

Snapshots

Apple File System supports snapshots for creating a point-in-time, read-only instance of the file system.[9]

Encryption

Apple File System natively supports full disk encryption,[2] and file encryption with the following options:

  • no encryption
  • single-key encryption
  • multi-key encryption, where each file is encrypted with a separate key, and metadata is encrypted with a different key.[9]

Increased maximum number of files

APFS supports 64-bit inode numbers, supporting over 9 quintillion files on a single volume.[2][5]

Data integrity

Apple File System uses checksums to ensure data integrity for metadata, but not user data.[14]

Crash protection

Apple File System is designed to avoid metadata corruption caused by system crashes. Instead of overwriting existing metadata records in place, it writes entirely new records, points to the new ones and then releases the old ones. This avoids corrupted records containing partial old and partial new data caused by a crash that occurs during an update. It also avoids having to write the change twice, as happens with an HFS+ journaled file system, where changes are written first to the journal and then to the catalog file.[14]

Space sharing

APFS adds the ability to have multiple logical drives (referred to as Volumes) in the same container where free space is available to all volumes in that container.[15]

Limitations

Apple File System does not provide checksums for user data, but does for metadata integrity.[16] It also does not take advantage of byte-addressable non-volatile random-access memory,[17] and does not yet support compression.[18]

Unlike versions of HFS+ since Leopard, APFS has no support for hard links to directories.[3][19] This is in line with many other modern file systems, but Time Machine still relies on them, so APFS is not yet an option for its backup volumes (as of macOS 10.14 Mojave).[20][19]

Support

macOS

Since macOS High Sierra, all devices with flash storage are automatically converted to APFS.[21] FileVault volumes are also converted. As of macOS Mojave, Fusion Drives and hard disk drives are also upgraded on installation.[22] The primary user interface to upgrade does not present an option to opt out of this conversion, and devices formatted with the High Sierra version of APFS will not be readable in previous versions of macOS.[21] Users can disable APFS conversion by using the installer's startosinstall utility on the command line and passing --converttoapfs NO.[23]

An experimental version of APFS, with some limitations, is available in macOS Sierra through the command line diskutil utility. Among these limitations, it does not perform Unicode normalization while HFS+ does,[24] leading to problems with languages other than English.[25] Drives formatted with Sierra’s version of APFS may also not be compatible with future versions of macOS or the final version of APFS, and the Sierra version of APFS cannot be used with Time Machine, FileVault volumes, or Fusion Drives.[26]

iOS, tvOS, and watchOS

iOS 10.3, tvOS 10.2, and watchOS 3.2 convert the existing HFSX file system to APFS on compatible devices.[12][7][27]

Third party utilities

Despite the ubiquity of APFS volumes in today's Macs and the format's 2016 introduction, third party repair utilities continue to have notable limitations in supporting APFS volumes, due to Apple's delayed release of complete documentation. According to Alsoft, the maker of the popular DiskWarrior, Apple's 2018 release of finalized APFS format documentation will enable safe rebuilding of APFS disks in future versions of its flagship product.[28] Competing products, including as MicroMat's TechTool and Prosoft's Drive Genius are expected to increase APFS support as well.

See also

References

  1. ^ a b Hansen, K.H.; Toolan, F. (September 21, 2017). "Decoding the APFS file system". Digital Investigation. 22: 107–132. doi:10.1016/j.diin.2017.07.003. ISSN 1742-2876.
  2. ^ a b c d e f "Volume Format Comparison". Apple Developer. Retrieved May 25, 2018.
  3. ^ a b c "Apple File System Guide / Frequently Asked Questions". Retrieved May 25, 2018.
  4. ^ Bertin, René. "Compression and APFS". Github. Retrieved February 2, 2019.
  5. ^ a b c Apple Inc. "Apple File System Guide (Features)". Retrieved May 25, 2018.
  6. ^ "tvOS 10.2". What's New in tvOS. Apple Inc.
  7. ^ a b c d Warren, Tom (March 27, 2017). "Apple is upgrading millions of iOS devices to a new modern file system today". The Verge. Vox Media. Archived from the original on March 27, 2017. Retrieved March 27, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  8. ^ Roger Fingas (June 13, 2016). "'Apple File System' will scale from Apple Watch to Macs, replace HFS+". Apple Insider. Archived from the original on July 23, 2016. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  9. ^ a b c d Hutchinson, Lee (June 13, 2016). "Digging into APFS, Apple's new file system". Ars Technica UK. Retrieved June 15, 2016.
  10. ^ a b Weintraub, Seth (June 13, 2016). "Apple File System (APFS) announced for 2017, scales 'from Apple Watch to Mac Pro' and focuses on encryption". 9to5Mac. Archived from the original on March 28, 2017. Retrieved March 27, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  11. ^ a b Hutchinson, Lee (June 13, 2016). "New file system spotted in macOS Sierra [Updated]". Ars Technica. Condé Nast. Archived from the original on March 28, 2017. Retrieved March 27, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  12. ^ a b Clover, Juli (March 27, 2017). "Apple Releases iOS 10.3 With Find My AirPods, APFS, App Store Review Tweaks and More". MacRumors. Archived from the original on March 27, 2017. Retrieved March 27, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  13. ^ Alan Loughnane. "Updating your iPhone will give you one major benefit". joe.co.uk. Archived from the original on May 20, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  14. ^ a b Adam Leventhal (June 19, 2016). "APFS in Detail: Data Integrity". Archived from the original on June 21, 2016. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  15. ^ "Archived copy" (PDF). Archived from the original (PDF) on October 23, 2016. Retrieved June 10, 2017. {{cite web}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)CS1 maint: archived copy as title (link)
  16. ^ A ZFS developer’s analysis of the good and bad in Apple’s new APFS file system Archived February 2, 2017, at the Wayback Machine
  17. ^ Why Apple's APFS won't last 30 years Archived April 6, 2017, at the Wayback Machine
  18. ^ Adam Leventhal (June 19, 2016). "APFS in Detail: Overview". Retrieved October 1, 2017.
  19. ^ a b Leventhal, Adam H. (June 26, 2016). "A ZFS developer's analysis of the good and bad in Apple's new APFS file system". Ars Technica. APFS right now is incompatible with Time Machine due to the lack of directory hard links, a fairly disgusting implementation that likely contributes to Time Machine's questionable reliability.
  20. ^ "Disks you can use with Time Machine". Retrieved December 10, 2017.
  21. ^ a b "Prepare for APFS in macOS High Sierra". Apple.com. September 7, 2017. Retrieved September 19, 2017.
  22. ^ "macOS 10.14 Mojave: The Ars Technica review". arstechnica.com. September 25, 2018. Retrieved December 20, 2018.
  23. ^ Trouton, Rich (September 26, 2017). "Using the macOS High Sierra OS installer's startosinstall tool to avoid APFS conversion". Der Flounder. Retrieved January 16, 2018.
  24. ^ APFS’s “Bag of Bytes” Filenames
  25. ^ APFS is currently unusable with most non-English languages – The Eclectic Light Company Archived June 8, 2017, at the Wayback Machine
  26. ^ "How to Format a Drive With the APFS File System on macOS Sierra". Archived from the original on October 26, 2016. Retrieved October 26, 2016. {{cite news}}: Unknown parameter |deadurl= ignored (|url-status= suggested) (help)
  27. ^ "jakepetroules/Filesystem". GitHub. Retrieved March 29, 2017.
  28. ^ Alsoft DiskWarrior: Mojave and Apple File System (APFS)