Systemd, how to mount a device at boot, but disable automount after boot
Hi,
I do not seem to find a simple solution to the following problem:
I have a device listed in fstab, this should get mounted at boot. But if I manually unmount/remove the device after boot and if I present the device later on, systemd sees the device and automatically mounts it.
So how to prevent the latter (like pre-systemd behaviour). I can not use noauto in /etc/fstab since that will disable mounting at boot, which I still want to have.
Thanks
Responses
Hi Sven,
I wonder if this could help you: http://askubuntu.com/questions/25071/how-to-run-a-script-when-a-specific-flash-drive-is-mounted#679600.
Here, the device still gets mounted when it's hot-plugged, but your trigger script can unmount it immediately, or do anything else while at it.
Regards, Radek
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
