Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm attempting to mount an ext4 partition image in userspace. (no sudo, no special config/permissions modification to /dev/loop0 or /etc/fstab etc). So I'm hoping FUSE will come to the rescue.

However it seems that each file system mounted through the FUSE system needs to have a special FUSE driver, and I've not been able to find a linux read-write ext4 FUSE driver for linux.

Is there a way to mount ext4 images via FUSE (with write permission)?

share|improve this question
add comment

3 Answers

up vote 1 down vote accepted

fuseext2 apparently will mount ext4 partitions read-write.

Caveat: ext4 support is not advertised in their documentation, and attempts to mount come with a warning:

This is experimental code, opening rw a real file system could be
dangerous for your data. Please add "-o ro" if you want to open the file
system image in read-only mode, or "-o rw+" if you accept the risk to test
this module
share|improve this answer
    
AFAIK, even fuseext2 only mounts ext4 read only. That still comes back to the original question- why do you need FUSE driver that writes to your ext4 partition? And how and why is this question on a website for system administrators? –  rchhe Jun 29 '12 at 3:27
    
The text of my post specifically includes the warning that mentions that it does rw. As stated in my reply to your answer, the use case is manipulating disk images without root access. And this is definitely a system administration issue. –  Catskul Jun 29 '12 at 4:21
add comment

You need a specific fuse driver for each file system type, as the point of fuse is to have the file system code running in user-land. So any pre-existing kernel driver code, running in kernel-land (ext2, ext3, ext4, xfs...) can't be used 'as-is' by fuse.

Nothing prevent developers to re-use part of the code from the corresponding kernel driver to implement a user-land fuse driver. But anyway, you always have to create a new driver for fuse for each file-system type. Kernel C code and user-land C code are quite different (no standard libc in the kernel, the driver entry-points do not have the same signature, etc...)

share|improve this answer
1  
It would be an interesting project to be able to use a kernel module as a fuse driver though. I'm wondering if it's possible (running a kernel module in a kind of "emulated kernel environment"). –  lOranger Mar 10 '13 at 15:59
add comment

Maybe something like this. First search result on Google.

share|improve this answer
1  
Note: that is read-only. –  Zoredache Jun 28 '12 at 19:41
1  
I've seen that. It doesn't solve the problem for two reasons: It's OSX specific (unless I'm mistaken) and it's read-only. I should have specified that I need write access, but please be more polite before you know if someone has actually done their homework. –  Catskul Jun 28 '12 at 19:47
    
My understanding is that ext4fuse works fine in Linux (I am trying to be polite!). Yes, it is read only but have you even tried it? Why would you need a read-write FUSE ext4 driver for Linux? –  rchhe Jun 28 '12 at 20:17
    
Apologies, I skipped over the word "result" in your answer : / Sorry. The use-case is building and manipulating disk images in userspace, where root access is not available. –  Catskul Jun 29 '12 at 0:15
    
I did a quick test of ext4fuse on linux, and confirmed that it does work, but read-only. –  Catskul Jun 29 '12 at 0:28
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.