2
I currently use a batch script to mount my network shares each morning:
NET USE * /DELETE /Y
NET USE Z: \\<IP>\<SHARE> <AUTHENTICATION> /persistent:no
...
Which is fine when I'm on the network, but doesn't work off-site. We have a domain which points to our public IP, and then port forwarding kicks in, so in theory, I can
NET USE * /DELETE /Y
NET USE Z: \\fqdn.com\<SHARE> <AUTHENTICATION> /persistent:no
...
Except that doesnt work in the batch script or windows UI.
I'm thinking there'd be a way to get the IP of fqdn.com (which is conveniently also stored at fqdn2.com/ip.txt) but there's well outside my experience of batching.
Any input much appreciated.
Um, why not just change the end part to /persistent:yes? and not map your drives every day. – Spencer5051 – 2013-07-25T01:31:27.123
You're allowing SMB in from the internet?! That's brave. – afrazier – 2013-07-29T17:01:57.357