You are not logged in.

#1 2023-05-26 13:55:24

duyinthee
Member
Registered: 2015-06-14
Posts: 222
Website

[SOLVED] user option in fstab no longer allow user to mount

I have the following in my fstab

# Static information about the filesystems.
# See fstab(5) for details.
.....
# /dev/sda1
UUID=63edf43c-b195-49da-bb5c-9f14c4e01574	/home/username/Data-hdd     	ext4      	rw,user,noauto,exec,relatime	0 2
.....

And I have

exec mount ~/Data-hdd

in my ~/.config/sway/config file because I am using sway.

I think, until Yesterday, it mount ~/Data-hdd at start of sway but today, it no longer mount.
I tested in terminal

$ mount ~/Data-hdd/
mount: /home/username/Data-hdd: must be superuser to use mount.
       dmesg(1) may have more information after failed mount system call.

If I do it with sudo, yes I can and data are intact.

Is there anyone experiencing this?
Please...
Thanks in advance.

Last edited by duyinthee (2023-05-26 15:49:12)

Offline

#2 2023-05-26 14:32:53

loqs
Member
Registered: 2014-03-06
Posts: 17,192

Re: [SOLVED] user option in fstab no longer allow user to mount

https://github.com/util-linux/util-linux/issues/2238 ?
Edit:
Might also be the same issue as https://bbs.archlinux.org/viewtopic.php?id=286042

Last edited by loqs (2023-05-26 14:35:55)

Offline

#3 2023-05-26 15:47:43

duyinthee
Member
Registered: 2015-06-14
Posts: 222
Website

Re: [SOLVED] user option in fstab no longer allow user to mount

Yes, thanks for the links.
A comment said user must be after exec in this https://github.com/util-linux/util-linux/issues/2238

this is solution. I changed like

# Static information about the filesystems.
# See fstab(5) for details.
.....
# /dev/sda1
UUID=63edf43c-b195-49da-bb5c-9f14c4e01574	/home/username/Data-hdd     	ext4      	rw,noauto,exec,relatime,user	0 2
.....

It works now.

Last edited by duyinthee (2023-05-26 15:48:31)

Offline

#4 2023-05-26 16:09:03

d.ALT
Member
Registered: 2019-05-10
Posts: 914

Re: [SOLVED] user option in fstab no longer allow user to mount

duyinthee wrote:

A comment said user must be after exec in this https://github.com/util-linux/util-linux/issues/2238

Be aware of the declaration order though (if you need it)!

man.archlinux.org wrote:

user

Allow an ordinary user to mount the filesystem. The name of the mounting user is written to the mtab file (or to the private libmount file in /run/mount on systems without a regular mtab) so that this same user can unmount the filesystem again. This option implies the options noexec, nosuid, and nodev (unless overridden by subsequent options, as in the option line user,exec,dev,suid).


(https://man.archlinux.org/man/mount.8)

GitHub wrote:

there is also a bug in the v2.39. It incorrectly reorders the options when it reads options from fstab


(https://github.com/util-linux/util-linu … 1557250479)


<49,17,III,I>    Fama di loro il mondo esser non lassa;
<50,17,III,I>    misericordia e giustizia li sdegna:
<51,17,III,I>    non ragioniam di lor, ma guarda e passa.

Offline

Board footer

Powered by FluxBB