Mailinglist Archive: opensuse (1264 mails)

< Previous Next >
Re: [opensuse] Automounting after bringing network up
  • From: Jan Ritzerfeld <suse@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
  • Date: Fri, 16 Jun 2017 11:17:56 +0200
  • Message-id: <1596414.vS2vFh6QGf@karl>
Am Freitag, 16. Juni 2017, 01:48:29 CEST schrieb Mikhail Ramendik:
I have a Leap 42.2 station and need to have a network share mounted. I
tried to add a curlftpfs line to /etc/fstab, only to get emergency
mode instead of GUI. After removing plymouthd that was not really at
fault (but for some reason sent SIGRTMIN+21 and sometimes dumped core,
so I thought it was at fault), I realized that the problem was the
mount. The network is not up at the time /etc/fstab is processed.

systemd automatically detects that a mount needs a network. But "curlftps" is
not on its list. So, Carlos tip "use option _netdev" is correct:
http://codingberg.com/linux/systemd_when_to_use_netdev_mount_option
However, if the network share is not available, this might fail. So, you
should add "nofail", too.

[...]
Is it possible to have an automatic mount that runs when the network
is already up, but before the login screen?

Since you already started editing fstab, you could try systemd automount by
adding(!) the following options:
noauto,x-systemd.automount,x-systemd.idle-timeout=60,nofail
Then, systemd will mount your share only when needed and will automatically
unmount it if you don't use it anymore. That is pretty cool for laptops being
used in different locations where different shares are available.

Personally, I use the old autofs/automount because it supports wildcard
automounting:
https://doc.opensuse.org/documentation/leap/reference/html/
book.opensuse.reference/cha.autofs.html#sec.autofs.advanced.wildcards

Gruß
Jan
--
Enough research will tend to support your theory.


--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse+owner@xxxxxxxxxxxx

< Previous Next >
References