I have some trouble with fileserver shares, if the share get's disconnected and reconnected again. The mount dir, e.g. /Volumes/Data isn't removed and when the share get's reconnected again, a new directory /Volumes/Data-1 is created.

However, I need the mount to be available at a static path, so that I can use it in some tools.


I fixed the issue using automount

sudo mkdir -p /mnt/scan

sudo echo "/mnt/scan auto_scan" >> /etc/auto_master

sudo echo "scansnap -fstype=smbfs ://MYUSER:MYPASS@" >> /etc/auto_scan

sudo chmod 600 /etc/auto_scan

sudo automount -vc

ls -la /mnt/scan/scansnap

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .