Page 1 of 1

fuse: failed to open /dev/fuse: Permission denied

Posted: Fri Feb 01, 2008 7:51 pm
by ^rooker
[PROBLEM]
During beta-testing of Ubuntu Hardy, I ran into some problems with wrong permissions when trying to mount e.g. USB harddisks or my CD-ROM drive.

When trying to mount an NTFS partition using ntfs-3g, I suddenly received the following error:
fuse: failed to open /dev/fuse: Permission denied

[SOLUTION]
The device /dev/fuse is only accessible by "root" and users of the group "fuse". Here's the output of "ls -la /dev/fuse"
crw-rw---- 1 root fuse 10, 229 2008-02-01 18:08 /dev/fuse
Now I saw that my user was not in the group "fuse" at all, so I just added it. You can take a look at this Linux Howto: Add a user to a group".

In the shell it's as easy as:

Code: Select all

sudo usermod -a -G groupname username
You would have to logout/login (e.g. end gnome/kde session) in order for the group changes to apply, but you can also do:

Code: Select all

newgrp fuse
to avoid the unnecessary re-login. Verify if you are really in the group fuse by calling the command "groups".

fusermount: option allow_other only allowed if ...

Posted: Fri Feb 01, 2008 8:10 pm
by ^rooker
[PROBLEM]
There's another error that you might run into when trying to mount a fuse-based device:
fusermount: option allow_other only allowed if 'user_allow_other' is set in /etc/fuse.conf
Even if you enable "user_allow_other" in /etc/fuse.conf you still can't mount the drive, and will probably run into this error:
fusermount: option blkdev is privileged

[SOLUTION]
The "ntfs-3g" executable should have the setuid root flag set, but in my case it didn't (Ubuntu Hardy).
These 2 commands will change the ownership to "root" and enable the setuid flag:

Code: Select all

sudo chown root $(which ntfs-3g)
sudo chmod 4755 $(which ntfs-3g)
So, my old (broken) rights for /bin/ntfs-3g looked like this (ls -la /bin/ntfs-3g):
-rwxr-xr-x 1 root root 36940 2008-01-12 06:40 /bin/ntfs-3g
After correcting the rights, it had "-rws" instead of "-rwx":
-rwsr-xr-x 1 root root 36940 2008-01-12 06:40 /bin/ntfs-3g

Another error I ran into.

Posted: Thu Jun 11, 2009 9:11 pm
by ^rooker
Mount is denied because setuid and setgid root ntfs-3g is insecure with the
external FUSE library. Either remove the setuid/setgid bit from the binary
or rebuild NTFS-3G with integrated FUSE support and make it setuid root.
Please see more information at http://ntfs-3g.org/support.html#unprivileged
Unprivileged user can not mount NTFS block devices using the external FUSE
library. Either mount the volume as root, or rebuild NTFS-3G with integrated
FUSE support and make it setuid root. Please see more information at
http://ntfs-3g.org/support.html#unprivileged