I run Linux in a VM on a Windows host. When I'm in the office, my Windows host machine self registers it's DNS name and it's
mymachine.myco.com. When I'm at home, it self registers as
mymachine.local. In the Linux guest, I want to mount shares on
mymachine. I do that in
//mymachine/development /home/ben/Development cifs credentials=/home/ben/.creds/alderaan,rw,user,noauto,iocharset=utf8,file_mode=0777,dir_mode=0777 0 0
This works in the office and at home if I type
mount Development. However, once it's mounted, I can't then switch locations and have it still work. It appears that once mount has run it's tied to the IP address not the DNS name and if that changes it no longer works. Is there a way I can make it reconnect on timeout so that it switches over if the IP address changes?
Or at the very least is there a way so that I can easily unmount the directory? At the moment I just get
mount point busy if I try to remount it and I can't even type
ls on my home folder since it times out getting the attributes of the mount point.