|
& |
|
NetBSD-SoC: HFS+ Filesystem
Update
hfs has been imported into NetBSD
as of 20070305. Information on this page is no longer kept
up-to-date, please refer to NetBSD sources for current information.
What is it?
HFS+ is the standard filesystem used by Apple Computer's Mac OS 9 and X operating systems. It is a relatively recent revision of the original HFS filesystem used in the first incarnations of the Macintosh. While HFS has been implemented on and distributed with NetBSD and other UNIX-like operating systems for quite some time, robust HFS+ implementations are not nearly as widespread. This is an impediment to Macintosh users who use or would like to use their Mac-based files with these systems.
The purpose of this project is to create a BSD-licensed implementation of the HFS+ filesystem for NetBSD. It will allow users to natively mount and read data from an HFS+ volume on any disk. Due to the time limit imposed by Google (about two months), there will initially be no support for writing data to a volume, nor for mounting/reading from a journaled volume whose journal is nonempty (implying that the filesystem is inconsistent). Once the initial framework is done, however, these features can be added with relative ease.
There are two phases to this project:
- Creating a library which provides routines to turn raw device bytes into intelligible HFS+ structures and to perform useful operations on them, such as locating a file on the volume or listing the contents of a directory.
- Writing a kernel-level filesystem driver, using the above library for HFS+-specific operations.
A formal list of expected project deliverables can be found below.
Status
- 2005-08-31: Very, very basic HFS+ filesystem is complete. It dosn't do a lot, and there are still some bugs, but I'm proud to call it my child.
- 2005-08-30: Fixed the reading failure and another major bug. Despite some minor deficits, it is now possible to browse the filesystem of many HFS+ volumes, as well as read any file on them. With one day left, this comes not a moment too soon. :)
- 2005-08-20: Trying to read the disk from inside the kernel, but failing miserably. Updated libhfsp with a callback mechanism, minimal journal reading, and other sundry changes.
- 2005-08-11: Wrote skeleton filesystem that can mount and unmount without crashing the system (always a nice thing). For now, it just lists a dummy root directory. Started adding HFS+-specific features.
- 2005-07-28: Principal work on library is complete. Additional changes will be made as needed. Starting work on kernel implementation.
- 2005-07-22: Much of the library is done; expect to "finish" it in the next few days.
- 2005-06-31: Started writing library and userland program to read and explore HFS+ volumes.
- 2005-06-24: Project accepted, started design phase.
Documentation
- The documentation for the developmental HFS+ library and accompanying sample program is here.
- Minimal instructions for adding (very incomplete and undoubtedly buggy) HFS+ support to your kernel.
Technical Details
By September 1, 2005, this project must deliver a kernel-level HFS+ implementation with the following capabilities:
Mandatory
- Mount/unmount volumes, list files, read file data, and perform
all other operations needed for a normal read-only filesystem.
- Support HFS+ and both varieties of HFSX.
- Support journaled volumes whose journals are empty.
Optional
- Support volumes with HFS wrappers.
- Properly deal with device node files located on HFS+ volumes.
- Allow exporting volumes as NFS mounts.
- Support all journaled volumes by rolling forward dirty journals. (Unlikely.)
- Allow booting from HFS+ volumes. (Mostly useless without R/W support.)
- Provide nice man pages and supple documentation.
Wishful Thinking
- Mount Apple Disk Image files.
- Read vanilla HFS volumes.
- fsck_hfsp, newfs_hfsp.
- R/W support. (Requires a wish-granting genie that can conjure double espressos at a ridiculous rate.)
|
Yevgeny Binder <yevbee at comcast dot net> |
$Id: index.html,v 1.11 2007/03/06 10:39:09 dillo Exp $ |
|