File systems

From Mac Guides

Jump to: navigation, search
This article contains out of date information that doesn't reflect recent events or releases.
You can help by updating it.
Mac OS X supports a variety of file systems with varying degrees of support. There are three principal file systems that most Mac OS X users interact with.

Contents

File Systems

HFS+

This is the principal file system of Mac OS X. It is a journalled, relatively modern file system that supports POSIX permissions, and features at least limited automatic defragmenting of files. Mac OS X is capable of mounting these volumes for reading and writing, and has full capabilities to utilize them. Mac OS X systems can also only boot from hard disks formatted in this system (as well as bootable optical media). Windows has no native support for this format, but third party tools such as MacDrive allow for limited read/write support on Windows systems.

NTFS

This is the current preferred file system of Windows (beginning predominance circa Windows NT 4.0 and Windows 2000, and including Windows XP). Most Windows systems use principle partitions with this file system. This is a journalled file system with good support for large files. It should be noted that it does NOT support POSIX permissions or ownership. Mac OS X has read only support for this format. It has no capabilities to write to an NTFS drive. Windows has complete read/write capabilities for this format.

FAT32

FAT32 is a legacy file system in the Windows world. However, it is still widely used as almost all Flash-based drives use this format. Mac OS X supports this format for both reading and writing, as does Windows. It has notable limitations, including difficulties with files of size larger than 4 GB. Also, as with NTFS, this file system does not support POSIX and permission / ownership errors could arise when files are moved back and forth between this file system and a POSIX-compliant file system.

exFAT

exFAT, also known as FAT64, is a newer file system developed with the simplicity of FAT in mind, and also to alleviate the FAT32 limits. Mac OS X 10.6.5 and later versions have full read/write support for it. Unlike FAT32, it does NOT have a 4GB single file limit. However, Linux support for exFAT is poor to nonexistent. Also, as with NTFS, this file system does not support POSIX and permission / ownership errors could arise when files are moved back and forth between this file system and a POSIX-compliant file system.

ext2

Ext2 is a relatively modern filesystem that is used primarily in Linux environments. It features many of the same creature comforts as OS X, including a journal and the ability to use large files (e.g. bigger than the 4 GB limit in FAT32). This file system is not natively supported in either OS X or Windows, but free extensions are available for both operating systems that allow basically full read/write utilization of this filesystem on both OS X and Windows. The Mac OS implementation is available at Sourceforge; the Windows implementation is available here.

Comparison

Another important distinction that should be noted is that all of the above is based on disks mounted under the given operating system. Limitations can be bypassed by serving a disk from a server for which the format is native. For instance, a Windows client that is accessing a served HFS+ disk that is served from a Mac OS X computer (a "shared" disk across the network) can write to that disk if the server has granted permission. Likewise, while a Mac OS computer cannot write to an NTFS volume it mounts itself, it can write to an NTFS volume being served by a Windows computer.

One important question that gets asked frequently at MacRumors is: how should I format my external device? Here are some suggestions, based on the above limitations of each filesystem.

  1. If the device will only be used on a Mac OS X computer, use HFS+. This will offer the most complete support for Mac OS X features.
  2. If the device will only be used in Windows, use NTFS, for the same rationale.
  3. If the device will be mounted on both Windows and Mac computers, and you will not be using very large files (all files <4 GB) use FAT32. Alternatively, if possible, mount the device on a computer on the network which is always turned on, and format it in the native format of that computer. Then use that computer as a server to share that volume with other computers. For this purpose, it may be slightly advantageous to make the server a Mac OS X computer, so that the file system complies with POSIX.
  4. If the device is to be mounted on both Windows and OS X computers, and the user has sufficient privileges on all computers with which it will be used to install the EXT2FS extensions discussed above, then finally, EXT2FS may be an excellent solution. Note however that, should this drive be taken to other Windows or OS X computers, it will not work without installation of the extensions.
  5. If you are using an Intel Mac, one configuration that is very popular is to create a three partition system. This system consists of boot partitions in HFS+ and NTFS for Mac OS X and Windows, respectively, plus a third partition in FAT32. All documents are then placed on the FAT32 partition, where they are accessible to both operating systems. While this does have limitations, based on the limitations of FAT32, it may be a good compromise solution for many users.
  6. Current iPods come formatted by default in a format which can be read by both systems (FAT32) and should probably be left this way unless specific needs exist with respect to alternate usage (e.g. as a drive for sharing files). While earlier iPods were formatted in HFS+ and this system confers some advantages in Mac-only environments, this is probably not something you should worry about unless you already know what you are doing. Likewise, Flash drives should NOT be reformatted and should be left in FAT32.

File systems cannot easily be converted from one standard to another, so make your decision carefully. In the event that you must later change systems, you will need to back up all files, reformat the drive (destroying all data on it), and then return the files to the drive. Drives can be formatted with Disk Utility in Mac OS X, and similar system tools in Windows, though Windows cannot format a FAT32 partition above 32GB, as Microsoft want you to use NTFS; this is an artificial restriction. iPods can be reformatted using the iPod Software Updater, available from Apple. Backup utilities are also readily available on both platforms (backup to multiple DVD-R or DVD-RW discs may be necessary if only one external drive is owned).

When Mac OS X writes to a FAT32 drive, it will create additional "dot files" (files beginning with "." are normally hidden in Unix systems) such as .DS_Store. These files allow Mac OS X to compensate somewhat for features of HFS+ that are not available in FAT32. The end result is that most files, including almost all document files, can be transferred back and forth between FAT32 and HFS+ without any real concern over he file system differences.

For a more detailed discussion of file system nuances, see the Comparison of file systems article at Wikipedia.