Open yurikoles opened 5 years ago
$ mount|grep mac
/dev/sda2 on /mnt/macOS type fuse (ro,nosuid,nodev,relatime,user_id=0,group_id=0)
sudo apfs-fuse /dev/sda2 /mnt/macOS -opass=<removed>,user_id=501,group_id=22
Volume macOS is encrypted.
fuse: unknown option(s): `-o user_id=501,group_id=22'
Well, the options are uid=N, gid=N, and only numeric values are supported.
Can you run it with an additional -d 15
option, and tell me if you see something relevant?
@sgan81 it's stuck with -d 15
Well, run apfs-fuse in one console, and execute the commands in another console. When running with debug flags, apfs-fuse will not return until the volume is unmounted. Because it will display all the info in the console.
Nothing interesting, because I can't even access volume as normal user (uid, gid). So nothing is print in debug. apfs-fuse set correct rights inside volume but mount dir is owned by root:root, even if I explicitly chown dir before mounting.
$ ls -lah /mnt|grep mac
ls: cannot access '/mnt/macOS': Permission denied
d????????? ? ? ? ? ? macOS
$ sudo ls -lah /mnt|grep mac
drwxr-xr-x 2 root root 0 Jan 1 1970 macOS
I had a similar issue, it turned out to be permission to access the device. Does this work for you?
$ sudo chmod +r /dev/sda2
(Edit: I also need to run apfs-fuse
as myself, not root)
Other FUSE and non-FUSE FSes doesn't have this issue, for example NTFS-3g.
Did you mount as root and try to access it as user? If yes, did you mount with -o allow_other
?
@sgan81, yes, allow_other
did the trick, but other filesystems automatically set permissions for mount dir to uid, gid.
$ ls -lah /mnt|grep macOS
drwxr-xr-x 2 root root 0 Jan 1 1970 macOS
$ ls /mnt/macOS -lah
total 0
drw-r--r-- 1 yurikoles yurikoles 65 May 23 20:30 private-dir
drwxr-xr-x 1 yurikoles yurikoles 31 May 23 20:25 root
$ ls -lah /mnt|grep win
drwxrwxrwx 1 yurikoles yurikoles 4.0K May 24 08:52 win
$ grep win /etc/fstab
LABEL=windows /mnt/win ntfs-3g uid=yurikoles,gid=yurikoles 0 0
I had a similar issue, it turned out to be permission to access the device. Does this work for you?
$ sudo chmod +r /dev/sda2
(Edit: I also need to run
apfs-fuse
as myself, not root)
maybe this would've been fine if i had used the allow_other option, but for me i had to chown and chmod +rwx of my mountpoint. then run apfs-fuse without sudo.
At first I thought that problem with uid=yurikoles,gid=yurikoles, but same issue with numeric IDs.