I want to connect to a network share and I want the connection to remain active after logout. I tried:
$ echo "/- auto_smb -nosuid,noowners,nofail
/- auto_afp -nobrowse,nosuid" >> /etc/auto_master
$ echo "/System/Volumes/Data/mount/Test2 -fstype=smbfs,soft,noowners,nosuid,rw ://$username:$password@server/share" >> /etc/auto_smb
$ automount -cv
My username and password have special characters so I tried escaping them and replacing them with URL encoding, but it did not work. What am I doing wrong?