I have a Nas and to make the experience using it more seamless I wanted a way to auto mount my shares after waking my laptop.
First I thought of using some kind of utility which allowed me to run a script on wake up, but then I found out that there is a built in utility for auto mounting drives called autofs.
So I looked at some tutorials and tried my luck but my results are inconsistent.
Sometimes the shares show up mounted sometimes not.
Here ist my auto_master file:
#
# Automounter master map
#
+auto_master # Use directory service
/net -hosts -nobrowse,hidefromfinder,nosuid
/home auto_home -nobrowse,hidefromfinder
/Network/Servers -fstab
/- -static
/Users/Anonymous/Nas auto_afp
In the same directory I put the auto_afp file:
HomeServer -fstype=afp,rw afp://Anonymous:1234@192.168.1.3/Daniel
Time-Machine -fstype=afp,rw afp://Anonymous:1234@192.168.1.3/Time-Machi$
Wg -fstype=smb smb://Anonymous:1234@192.168.1.3/Wg
Could someone enlighten me on what I did wrong?
First I thought of using some kind of utility which allowed me to run a script on wake up, but then I found out that there is a built in utility for auto mounting drives called autofs.
So I looked at some tutorials and tried my luck but my results are inconsistent.
Sometimes the shares show up mounted sometimes not.
Here ist my auto_master file:
#
# Automounter master map
#
+auto_master # Use directory service
/net -hosts -nobrowse,hidefromfinder,nosuid
/home auto_home -nobrowse,hidefromfinder
/Network/Servers -fstab
/- -static
/Users/Anonymous/Nas auto_afp
In the same directory I put the auto_afp file:
HomeServer -fstype=afp,rw afp://Anonymous:1234@192.168.1.3/Daniel
Time-Machine -fstype=afp,rw afp://Anonymous:1234@192.168.1.3/Time-Machi$
Wg -fstype=smb smb://Anonymous:1234@192.168.1.3/Wg
Could someone enlighten me on what I did wrong?