On Sun, May 14, 2017 at 12:49:12PM +0200, Christoph Biedl wrote:

> > Maybe this bug should be reassigned to aoetools to provide a
> > proper systemd.service file?
> 
> Wearing the aoetools maintainer's hat, I'll be happy to provide that but
> will need help on it.

Ok. I'll try to create one and send it to you.

> > Another option is to explicitly add a dependency on the network for a
> > given mount point in /etc/fstab, see the systemd.mount manpage.
> > Basically, the following should work:
> > 
> > /dev/etherd/...  /mountpoint  ext4 x-systemd.requires=network-online.target 
> >  0  2
> 
> How about block devices that were mounted manually i.e. are not listed
> in /etc/fstag? I doubt they will handled in a sane way during shutdown.

Then I would say it's the responsibility of the user to unmount it
manually at the appropriate time. If aoetools can detect such mounts and
unmount them at shutdown, that would be nice. But only if it's very easy
to do.

Having ifupdown keep network interfaces alive is not guaranteed to help
either. What if you mount an NBD or AoE device via VPN? At some point
the VPN daemon will be killed. Is that before or after the kernel
unmounts things?

> > With a proper aoetools.service, perhaps it should become
> > x-systemd.requires=aoetools.service. I see nbd-client has a
> > nbd@.service, but it requires you to write your own dev-%i.device
> > script. I will duplicate this bug and reassign to aoetools and
> > nbd-client. I'll also create a bug report for the kernel bug found.
> 
> My gut feeling warns me about a dependency loop in case of more complex
> mount setups like local block device mounted somewhere inside a mounted
> AoE block device. A check of that situation will be part of the tests.

Well, if all dependencies were correct when booting, then systemd should
shut down everything in reverse order, right?

-- 
Met vriendelijke groet / with kind regards,
      Guus Sliepen <g...@debian.org>

Attachment: signature.asc
Description: Digital signature

Reply via email to