[Bug 1052140] New: NetworkManager dispatcher script "nfs" is mounting nfs shares from fstab with option "noauto"

http://bugzilla.opensuse.org/show_bug.cgi?id=1052140 Bug ID: 1052140 Summary: NetworkManager dispatcher script "nfs" is mounting nfs shares from fstab with option "noauto" Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: x86-64 OS: SUSE Other Status: NEW Severity: Normal Priority: P5 - None Component: Network Assignee: bnc-team-screening@forge.provo.novell.com Reporter: opensuse@mike.franken.de QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- The NetworkManager dispatcher script "nfs" is mounting nfs shares from fstab, which have set option "noauto". In my environment this is a good thing, but it is not the expected behaviour. Perhaps we could have a new fstab option like "x-nm.mount" for nfs shares to explicitly control this behaviour? The reason for experimenting with fstab options for nfs shares is the really strange "cooperation" of systemd and NetworkManager. Having the "auto" option set and nfs.service is active, systemd tries to mount the shares on boot, before network is available. This gives lots of errors in the log, although NetworkManager succeeds in mounting the share, when running the dispatcher script. With "auto" in fstab and a deactivated nfs.service neither systemd nor NetworkManager are trying to mount nfs shares. With "noauto" in fstab and an activated nfs.service systemd ignores the shares, but NetworkManager's nfs dispatcher is mounting them nevertheless. I tried x-systemd.automount, too. This worked generally, but after a hibernate/resume cycle all nfs shares were inaccessible. -- You are receiving this mail because: You are on the CC list for the bug.

http://bugzilla.opensuse.org/show_bug.cgi?id=1052140 http://bugzilla.opensuse.org/show_bug.cgi?id=1052140#c1 Jacob W <jacobwinski@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jacobwinski@gmail.com --- Comment #1 from Jacob W <jacobwinski@gmail.com> --- Bug confirmed, but only recently on TW (started in 2018). I have 3 NFS shares, setup via YaST NFS Client module. All have noauto and user options set. In fact, in NFS Client the following are set: [ X ] NFSv4 share [ X ] pNFS Options for every share: rw,user,noauto,minorversion=1 Also obviously hostname, remote and mount point are set. $ systemctl status NetworkManager-dispatcher.service shows all 3 NFS shares being started 1) on boot and 2) on every suspend / resume cycle. Very frustrating because when mounted by NM the shares are mounted by root, instead of user and are therefore not modifiable as user. $ zypper info openSUSE-release Repository : openSUSE-Tumbleweed-Oss Version : 20180129-1.4 -- You are receiving this mail because: You are on the CC list for the bug.

http://bugzilla.opensuse.org/show_bug.cgi?id=1052140 http://bugzilla.opensuse.org/show_bug.cgi?id=1052140#c2 --- Comment #2 from Jacob W <jacobwinski@gmail.com> --- Found the cause: NetworkManager More precisely, /etc/NetworkManager/dispatcher.d/nfs Lines: NET_MOUNTS=$(sed -e '/^.*#/d' -e '/^.*:/!d' -e 's/\t/ /g' /etc/fstab | tr -s " ")$'\n'b ... if /usr/bin/systemctl is-enabled nfs.service >/dev/null 2>&1; then printf %s "$NET_MOUNTS" | while IFS= read -r line; do MOUNT_POINT=$(echo $line | cut -f2 -d" ") net_mount "$MOUNT_POINT" done fi The above regex checks for all NFS mounts, and then if nfs.service is enabled, mounts them every single time NetworkManager is dispached (every boot, every resume from suspend, etc.) The problem is, it totally ignores options such as noauto My simple temporary solution is to just disable the service nfs.service because I don't need auto mounted nfs shares. This is also the reason why I just recently started having trouble: my nfs service was disabled until recently. -- You are receiving this mail because: You are on the CC list for the bug.

http://bugzilla.opensuse.org/show_bug.cgi?id=1052140 http://bugzilla.opensuse.org/show_bug.cgi?id=1052140#c3 --- Comment #3 from Michael Hirmke <opensuse@mike.franken.de> --- Does anyone care for this problem? It still exists up to the latest Tumbleweed snapshot. -- You are receiving this mail because: You are on the CC list for the bug.

http://bugzilla.opensuse.org/show_bug.cgi?id=1052140 http://bugzilla.opensuse.org/show_bug.cgi?id=1052140#c4 --- Comment #4 from Michael Hirmke <opensuse@mike.franken.de> --- Sorry, forget about my latest comment. It belongs to a different bug. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com