EXT4 implementation for FUSE
Switch branches/tags
Clone or download
Latest commit 325bf27 Feb 18, 2018
Failed to load latest commit information.
test 0014 had some missing cleanup Jan 20, 2013
types First implementation of a dcache Jun 6, 2010
.gitignore Add some test framework and basic tests May 22, 2010
COPYING Licensing May 16, 2010
Makefile Fix "make test" Jan 20, 2013
README.md Fix homebrew command count Feb 15, 2018
common.h First implementation of a dcache Jun 6, 2010
dcache.c First implementation of a dcache Jun 6, 2010
dcache.h First implementation of a dcache Jun 6, 2010
disk.c don't try to use FreeBSD pread wrapper on OSX May 5, 2011
disk.h Fix ext2/ext3 multiple indirected block reading Jan 20, 2013
extents.c Avoid reading extent index that does't contain our block Jan 14, 2013
extents.h Support extent trees of depth > 1 Jan 13, 2013
fuse-main.c Store full version (git hash) in the binary Jan 20, 2013
inode.c Reset inode_idx to 0 if the entry cannot be found. Mar 8, 2015
inode.h Modify the inode_dir_ctx API to detach alloc and init Jan 19, 2013
logging.c Add back buffering to log file writing Jan 19, 2013
logging.h Refactor super and group descriptor functionality May 23, 2010
op_getattr.c Fix files over the 4GB limit Jan 14, 2013
op_init.c First implementation of a dcache Jun 6, 2010
op_open.c Lookup path at open time and then use inode number at read Jun 8, 2010
op_read.c Fix files over the 4GB limit Jan 14, 2013
op_readdir.c Modify the inode_dir_ctx API to detach alloc and init Jan 19, 2013
op_readlink.c Memory corruption with long symlinks Feb 7, 2013
ops.h Move operations to their own files May 29, 2010
super.c Statically allocate the superblock descriptor Jan 19, 2013
super.h Do the file magic check before fuse initialization Jan 19, 2013



This is a read-only implementation of ext4 for FUSE. The main reason this exists is to be able to read linux partitions from OSX. However, it should work on top of any FUSE implementation. Linux and FreeBSD have been tested to some point and I've heard that OpenSolaris should also work.

Write support will only come if I get the time, knowledge, patience and nerve to support it. Most of them I lack, so it's a long shot. However, the fact that ext4fuse is read-only also means that it's completely safe to use.



If you use OS X I suggest you rely on the homebrew project.

Once you have homebrew installed, simply type the following two commands:

$ brew cask install osxfuse

$ brew install ext4fuse

At least on Leopard, you need to add your user to the operator group so you can have readonly permissions to the disks. Use this:

$ sudo dscl . append /Groups/operator GroupMembership <your-user>

Also, you will need to know the name of your ext4 partition. Take a look at the Mac Disk Utility. It should be something like /dev/disk0s5.


Simply install it through the ports tree:

$ cd /usr/ports/sysutils/fusefs-ext4fuse && make install clean

Remember that you need the fuse module loaded. In my experience it doesn't load automatically, but then again, I have nearly zero experience with FreeBSD.

Compiling from source

If you prefer bleeding edge, get the source, untar it and compile using:

$ make

or in case you are on FreeBSD:

$ gmake

You need to have pkg-config for the compilation to work as well as the FUSE kernel module. For OSX you should use fuse4x (notice that fuse4x is also available via brew install).


You can mount a filesystem like this:

$ ext4fuse <device> <mountpoint>

If you compiled from source, and you haven't manually installed ext4fuse in your $PATH, go to the directory where you did the compilation and run this

$ ./ext4fuse <device> <mountpoint>

The should be the partition device and the is the directory where you want to mount your partition.

On macOS Sierra (10.12) or later, when mounting a filesystem with sudo, you need to add the option -o allow_other to allow non-root accounts access to the mount. See this issue for details.

Reporting bugs

If you notice a problem, please file a bug report.

If you have a reproducible problem the easiest for debugging is to share the filesystem. First of all, umount the partition, then you can create a backup like this:

$ dd if=<device> bs=64K | gzip -c > filesystem.backup.gz

Then, just upload the .gz file somewhere.

However, I understand that you generally do not want to do that. In that case you can also generate a log file. Notice that the log file still contains the directory listings.

To get a logfile, you can run ext4fuse like this:

$ ext4fuse <device> <mountpoint> -o logfile=/dev/stdout

If you do not want to share the logfile, another option is to provide a backtrace with gdb or a coredump (a coredump might contain file data).

Finally, you can always drop a mail:


  • All code is religiously Little Endian only. If you don't know what this means, you are probably OK (ie, you are using an intel or amd cpu). The code should be better tested on x86-64, you should not be using anything else on modern hardware anyway.
  • Block numbers over 32 bits aren't supported. You hit those when you reach around the terabyte, and I don't have any way to test that. It should be quite easy to fix, but I don't feel like spending time on something that neither has a use for me or can be proved to be correct. I don't have such big disks :P.