[Bug 1164642] New: Systend automounts entries which are marked as noauto
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 Bug ID: 1164642 Summary: Systend automounts entries which are marked as noauto Classification: openSUSE Product: openSUSE Distribution Version: Leap 15.1 Hardware: x86-64 OS: SUSE Other Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem Assignee: bnc-team-screening@forge.provo.novell.com Reporter: werner@suse.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: --- Every time my NAS wakes up from sleep I see those entries mounted on my laptop ```dataslide.intern.lan:/Multimedia/Music 1829485312 174848000 1654637312 10% /mounts/dataslide/Music dataslide.intern.lan:/Multimedia/Video 1829485312 174848000 1654637312 10% /mounts/dataslide/Video dataslide.intern.lan:/Multimedia/Pictures 1829485312 174848000 1654637312 10% /mounts/dataslide/Photo ``` but those are marked as noauto: ``` /local/werner> grep -E 'dataslide.*noauto' /etc/fstab dataslide.intern.lan:/Multimedia/Music /mounts/dataslide/Music nfs rw,nosuid,nodev,relatime,rsize=1048576,wsize=1048576,noauto,user,soft,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountproto=udp,local_lock=all,intr 0 0 dataslide.intern.lan:/Multimedia/Video /mounts/dataslide/Video nfs rw,nosuid,nodev,relatime,rsize=1048576,wsize=1048576,noauto,user,soft,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountproto=udp,local_lock=all,intr 0 0 dataslide.intern.lan:/Multimedia/Pictures /mounts/dataslide/Photo nfs rw,nosuid,nodev,relatime,rsize=1048576,wsize=1048576,noauto,user,soft,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountproto=udp,local_lock=all,intr 0 0 ``` as root I see ``` tux:~ # systemctl list-units | grep mounts-dataslide tux:~ # systemctl show mounts-dataslide-Music.mount | grep ^Op Options=rw,nosuid,nodev,noexec,relatime,vers=3,rsize=262144,wsize=262144,namlen=255,hard,nolock,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=192.168.0.22,mountvers=3,mountport=30000,mountproto=udp,local_lock=all,addr=192.168.0.22,user ``` the option ``noauto`` is missed here -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c1 --- Comment #1 from Dr. Werner Fink <werner@suse.com> --- Created attachment 830974 --> http://bugzilla.opensuse.org/attachment.cgi?id=830974&action=edit /run/systemd/generator/mounts-dataslide-Music.mount The auto generated /run/systemd/generator/mounts-dataslide-Music.mount -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c2 --- Comment #2 from Dr. Werner Fink <werner@suse.com> --- Created attachment 830975 --> http://bugzilla.opensuse.org/attachment.cgi?id=830975&action=edit Output of systemctl show mounts-dataslide-Music.mount Interesting: ``` tux:~ # systemctl show mounts-dataslide-Music.mount | grep -i auto DevicePolicy=auto ``` -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 Dr. Werner Fink <werner@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Systend automounts entries |Systemd automounts entries |which are marked as noauto |which are marked as noauto -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c5 Dr. Werner Fink <werner@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Flags|needinfo?(werner@suse.com) | --- Comment #5 from Dr. Werner Fink <werner@suse.com> --- Created attachment 832439 --> http://bugzilla.opensuse.org/attachment.cgi?id=832439&action=edit output of sudo journalctl -b -o short-monotonic (In reply to Franck Bui from comment #4)
Also please make sure the entries are not mounted before running the procedure given previously.
Just done and the shares are mounted ... -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c6 --- Comment #6 from Dr. Werner Fink <werner@suse.com> --- Hmmm ... could be that this file /etc/NetworkManager/dispatcher.d/nfs which is part of NetworkManager does this job at least in the log output there are many lines with nm-dispatcher doing or causing nfs mounts. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c7 --- Comment #7 from Dr. Werner Fink <werner@suse.com> --- this should do the job more correct --- /tmp/nfs 2020-03-10 19:19:45.977494993 +0100 +++ /etc/NetworkManager/dispatcher.d/nfs 2020-03-10 19:29:43.575427345 +0100 @@ -59,6 +59,10 @@ case "$COMMAND" in # Check with systemd if nfs service is enabled if /usr/bin/systemctl is-enabled nfs.service >/dev/null 2>&1; then printf %s "$NET_MOUNTS" | while IFS= read -r line; do + MOUNT_OPTIONS=$(echo $line | cut -f2 -d" ") + case ",${MOUNT_OPTIONS}," in + *,noauto,*) continue ;; + esac MOUNT_POINT=$(echo $line | cut -f2 -d" ") net_mount "$MOUNT_POINT" done -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c8 --- Comment #8 from Dr. Werner Fink <werner@suse.com> --- Ouch ... wrong ... it is the fourth field --- /tmp/nfs 2020-03-10 19:19:45.977494993 +0100 +++ /etc/NetworkManager/dispatcher.d/nfs 2020-03-10 19:34:21.084137993 +0100 @@ -59,6 +59,10 @@ case "$COMMAND" in # Check with systemd if nfs service is enabled if /usr/bin/systemctl is-enabled nfs.service >/dev/null 2>&1; then printf %s "$NET_MOUNTS" | while IFS= read -r line; do + MOUNT_OPTIONS=$(echo $line | cut -f4 -d" ") + case ",${MOUNT_OPTIONS}," in + *,noauto,*) continue ;; + esac MOUNT_POINT=$(echo $line | cut -f2 -d" ") net_mount "$MOUNT_POINT" done -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c9 --- Comment #9 from Franck Bui <fbui@suse.com> --- (In reply to Dr. Werner Fink from comment #8)
Ouch ... wrong ... it is the fourth field
So does it fix you issue ? Can you please re-assign this bug to NM maitainer ? Thanks. -- You are receiving this mail because: You are on the CC list for the bug.
http://bugzilla.opensuse.org/show_bug.cgi?id=1164642 http://bugzilla.opensuse.org/show_bug.cgi?id=1164642#c10 Dr. Werner Fink <werner@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dimstar@opensuse.org, | |sreeves@suse.com Component|Basesystem |Network Assignee|systemd-maintainers@suse.de |os.gnome.maintainers@gmail. | |com Summary|Systemd automounts entries |NetworkManager (auto)mounts |which are marked as noauto |entries which are marked as | | noauto --- Comment #10 from Dr. Werner Fink <werner@suse.com> --- See SR#783666 for the fix: - Modify nfs script (boo#1164642) * Also mount nfs4 shares * Ignore nfs or nfs4 shares in case if the noauto option is set -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com