I am trying to write a systemd unit to mount a NAS after boot, but it fails during boot because it seems not to wait for the network. After I have booted, I can start the service fine. I already tried to put NetworkManager-wait-online.service, but it still doesn’t work.
None of the solutions worked and I ended up writing an automount script, which works well but seems to have the side effect that my system is not shutting down properly as described in this thread. I see that one of the last messages is the unmount of the cifs script. When I disable the script, I can shutdown fine. Any idea why this could be? Could it be that I have to write an unmount service as well?