Saturday, March 17, 2007

NTFS read/write support for Mac OS X

It is a fact that hard disk drives are very, very large nowadays. Formatting them as FAT (in any of its versions) is suboptimal due to the deficiencies of this file system: big clusters, lack of journaling support, etc. But, like it or not, FAT is the most compatible file system out there: virtually any OS and device supports it in read/write mode.

Today, I had to reinstall Windows XP on my Mac (won't bother you with the reasons). In the past, I had used FAT32 for its 30Gb partition so I could access it from Mac OS X. But recently, some guys at Google ported Linux's FUSE to Mac OS X, effectively allowing anyone to use FUSE modules under this operating system. And you guessed right: there is a module that provides stable, full read/write support for NTFS file systems; it's name: ntfs-3g.

So I installed Windows XP on a NTFS partition and gave these a try.

MacFUSE, as said above, is a port of Linux's FUSE kernel-level interface to Mac OS X. For those that don't know it, FUSE is a kernel facility that allows file system drivers to be run as user-space applications; this speeds up development of these components and also prevents some common programming mistakes to take the whole system down. Having such a compatible interface means that you can run almost any FUSE module under Mac OS X without changes to its code.

Installing MacFUSE is trivial, but I was afraid that using ntfs-3g could require messing with the command line — which would be soooo Mac-unlike — and feared it could not integrate well with the system (i.e. no automation nor replacement of the standard read-only driver).

It turns out I was wrong. There is a very nice NTFS-3G for Mac OS X project that provides you the typical disk image with a couple of installers to properly merge ntfs-3g support into your system. Once done, just reboot and your NTFS partition will automatically come up in the Finder as a read/write volume! Sweet. Kudos to the developers that made this work.

Oh, and by the way. We have got FUSE support in NetBSD too!

5 comments:

Anonymous said...

thanks - that helped me find what I was looking for!

Dan

Anonymous said...

Thank you. I wanted to be able to take my old files and bring them over to the mac. I was upset when the tools available to do so, where no already included with bootcamp. Please forward this to them, it might prove useful to those who wish to make the swicth to mac.

Thank you for telling us about this beautiful thing!!

ooseven said...

Could someone help me locate NTFS-3G? I have searched many many pages and the links for the file has been broken in all of them / the file does not exist.

Anonymous said...

http://chucker.mystfans.com/opensource/ntfs-3g/NTFS-3G%2020070116-r4.dmg

macguitarman said...

Great work, seems to be working.

Formatted 750 GB WD Caviar drive in Leopard BootCamp. What is the difference between Quick Format and Format in Win XP, Format takes hours, what a joke (anyway).

Installed MacFUSE, and stable build at first, taking an hour to copy 90 GB to NTFS. So I figure I'll use the ublio build and it may be faster, says it will be 40 minutes. Not bad, but this would be 20 minutes or so HFS+ to HFS+.

Anything you can do to speed up this copies would be great, perhaps not using a finder copy but ditto from terminal, although ditto is supposed to be what a Finder copy does.

And I have heard from Apple engineers, that the Finder has a 80 MB / sec limitation (governor) and ditto does not.

Is this basically using vfs (virtual file system) of BSD UNIX, is this how this is possible. This is how Xsan works, Xsan being Store Next File System, SNFS or Apple Clustered File System, ACFS and is loaded via vfs.

Thanks, I am really needed this to copy large Panasonic P2 files (they are from FAT32 format) , but now on a Mac HFS+ drive to an NTFS partition (for a Windows using client) as well as large dv files and H264 and WMV files that will be larger than 4 GB in size.

I am actually quite glad I did not have to do this using Win XP SP2, a joke really, no network connection and only sees 1.99 GB of RAM not the full 7 GB, so much better that I can do this from Mac OS 10.5 Leopard.

I l almost wasted a bunch of time screwing around with Windows and then I said, screw this I'll try this and and stay in the Mac world. I would have had to copy my data to another drive and then re-format as FAT32 so Windows could see it, forget it.

So much more peaceful.

macguitarman@mac.com