0

I have two cifs shares mount in fstab and when I shutting down computer (elementaryOS Loki) system waiting 90sec because WiFi connection was closed earlier. I tried to:

  1. Create a file /etc/init.d/umountcifs containing the CIFS unmount command:

"#!/bin/sh

[ "$1" = "stop" ] && umount -a -t cifs -l"

and link to it at the start of the "init.d" shutdown process like so:

sudo ln -s /etc/init.d/umountcifs /etc/rc0.d/K02umountcifs
sudo ln -s /etc/init.d/umountcifs /etc/rc6.d/K02umountcifs
  1. Add script to NetworkManager:

"#!/bin/bash

umount -a -l -t cifs"

to /etc/NetworkManager/dispatcher.d/pre-down.d/mount_cifs

  1. Fstab Ad the x-systemd.requires=network.target to line in fstab.

And still is the same - system waiting on shutdown. Can somebody help?

0

Same problem here. I usually run a script manually to unmount cifs shares prior to logging out. This then makes logging out fast. As my cifs shares are on VPN I must run this script while my VPN channel still exists otherwise I have to wait 1-2 mins for shutdown, too. Also tried to placing a script at pre-down.d, no success.

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.