How can I use a `nofail` alternative with fuse?

Using mergerfs the computer refused to boot with the following error

[Failed] Failed to mount /mnt/merged
[Failed] Failed to mount /mnt/storage
[Depend] Dependency failed for Local File Systems
You are in emergency mode. After logging in, type “journalctl -xb” to view system logs, “systemctl reboot” to reboot, “systemctl default” or “exit” to boot into default mode.
Root password for maintenance (or press Control-D to continue):

I added the nofail option and it boots up fine but now I can’t mount the folder because I get

fuse: unknown option nofail

How can I use a nofail alternative with fuse? I’m looking for a way more specific than this.

The error was because the mount point wasn’t empty. I may need nofail in the future to avoid this same error.

Unknown option, means the protocol you use for mounting it (fuse) does not know the option or what to do with it.

So you can’t.

What I mean is how do I accomplish the same thing with fuse?

mergerfs is a custom package - and as such unsupported in every way

Don’t mount any device so you hide the content of the folder - this is bound to create errors or other weird issues.

Look at the github page for the mergerfs project - it has an extensive documentation.

1 Like

You should not use nofail for mounts that the system itself is not depended on, and also might not be available till the system loads all modules, because will try to mount it before it is available, hence hang. You can use: nobootwait

2 Likes

I tried using nobootwait but it failed to mount. Then I tried with nobootwait and nonempty but it failed again. At the end I had to add nofail again to boot up properly.

I’m sure i’m not following where you added it, in conjunction with what other fstab parameters, and when and how it failed because you once say

and then

meaning that once it boot properly (the system) but did not mount (your custom merged drives), or it prevented to boot properly all together (the system), hence the mount failed too.
Looking at your other post, this reply made sense tho

I don’t really know what the steps in the boot up sequence are called.

The system fails to mount when I don’t use nofail before I see the login screen. If I use nofail I can login but I can’t mount the merged drives with fuse.

In your shared fstab from the other topic i can’t see where the mount for / aka root line is placed, but the order is important, and in your selfsolved comment i do not see you using the nofail … and together with the explanation from you above, i can’t put 1+1 together. Sorry.

Maybe share the entire content of fstab and someone will help you out.

nofail is giving me trouble so I need some alternative. I’ll include the alternative in the solution when I find it.

UUID=F42A-E24F                            /boot/efi      vfat    umask=0077 0 2
UUID=06080c24-dbdf-45c5-b0ec-7218d3cc2b3a /              ext4    defaults,noatime 0 1
UUID=deeabd3e-26e6-4520-a0b4-9b86ae0a27e6 swap           swap    defaults,noatime 0 0
tmpfs                                     /tmp           tmpfs   defaults,noatime,mode=1777 0 0
UUID=301e3d8d-6c0a-4f7c-864b-4185a70efbb0 /mnt/hdd1      auto    nosuid,nodev,nofail,x-gvfs-show 0 0
UUID=be8b9fd3-7ed2-45ae-881a-25fa06f4de47 /mnt/hdd2      auto    nosuid,nodev,nofail,x-gvfs-show 0 0
UUID=05aa7429-44d2-4736-b5ef-a76add22cee2 /mnt/hdd3      auto    nosuid,nodev,nofail,x-gvfs-show 0 0

/mnt/hdd*  /mnt/merged  fuse.mergerfs  allow_other,use_ino,cache.files=partial,dropcacheonclose=true,ignorepponrename=true,func.mkdir=epall,nofail,x-gvfs-show  0  0

user@192.168.1.122:/mnt/merged  /mnt/shared  fuse.sshfs  _netdev,user,idmap=user,follow_symlinks,IdentityFile=/home/user/.ssh/id_rsa,allow_other,default_permissions,uid=1000,gid=1001,reconnect,ServerAliveInterval=15,ServerAliveCountMax=3,noatime,x-gvfs-show 0 0

/mnt/hdd*:/mnt/shared  /mnt/storage  fuse.mergerfs  allow_other,use_ino,cache.files=partial,dropcacheonclose=true,ignorepponrename=true,func.mkdir=epall,nofail,x-gvfs-show  0  0

I’d think that this “nofail” option needs to go
probably the “gvfs-show” option as well

It’s nowhere to be found in the manual page for mergerfs.

1 Like

Are you sure is suppose to be auto and not autofs for those 3 hdd filesystem type?
filesystem types, such as adfs, affs, autofs, coda, coherent, cramfs, devpts, efs, ext2, ext3, hfs, hpfs, iso9660, jfs, minix, msdos, ncpfs, nfs, ntfs, proc, qnx4, reiserfs, romfs, smbfs, sysv, tmpfs, udf, ufs, umsdos, vfat, xenix, xfs are known to me, but auto ?!?!
Also what @Nachlese said …

The thing is that without nofail the computer doesn’t login, it gives the error

[Failed] Failed to mount /mnt/merged
[Failed] Failed to mount /mnt/storage

Those three lines where added by gnome-disk-utility so I assume those are fine. I’ve sometimes used ext4 instead of auto but there doesn’t seem to be any difference.

auto is simply the negative of noauto with latter meaning to not mount the filesystem from mount -a, therefore not at boot. Given that adding a filesystem to /etc/fstab in the first place tends to be exactly because one wants it mounted at boot, auto is very much default and therefore very seldomly specified explicitly…

[EDIT] See you’re typing; yes, you were talking about auto as a type rather than option I see on reread; my above bit would be as to auto as option. As a type auto simply means “autodetect”. Any case – still the below…

But other than that and in that mentioned autofs sense, i.e., the automount on access sense: I for e.g. NFS mounts in /etc/fstab tend to not specify nofail but x-systemd.automount. While not the same this still very much also defends against at boot inaccessible/failing mounts, of course unless something at boot in fact accesses the filesystem. No idea about nor interest in mergerfs – but poster may supposedly want to do that as well.

The auto seems to be on the column and not in the column, and i never used it like that.

Yes, see my edit; I misread…

According to this:

You need fuse3 for nofail to work. And it’s in the extra repository:

$ pamac search fuse3
[...]
fuse3                                                                                                                                                                                                               [Installed] 3.12.0-1              extra
A library that makes it possible to implement a filesystem in a userspace program.

So you should be able to install it with:

pamac install fuse3

I don’t know if it will, but I hope it does help.

You have two mount points.
on one you want to merge just the hdd1 to hdd3 (/mnt/merged)
on the other you want to merge the same, as well as your sshfs mount (/mnt/storage)

seems odd, but I don’t know your plan behind this :wink:
or whether this can even work.

Can you comment the two lines (hash mark in front: # )
and mount it, with these options, from the command line once your system is booted up?
Have you verified that this works as intended?

IMO you should do this, before attempting to automate the process via /etc/fstab

Are the 3 hdd’s (and the sshfs) correctly mounted as you intended and as they need to be for the subsequent mergerfs mount to be successful?

Also, I would probably not use the /mnt directory for this, but this choice is no reason for it to fail here.