سؤال

I have a BAT file that runs on startup via the group policy on an internal server. The BAT executes a nant script which then maps several external locations via net use command. Until now, all mappings have been to external computers that are part of a different domain via public IPs.

net use e: \\111.111.111.111\someshare$ /persistent:yes
net use f: \\111.111.111.222\someshare$ /persistent:yes
net use g: \\111.111.111.333\someshare$ /persistent:yes

This has been successful. Now, I added a new computer that is part of the same network and domain as the internal server. While the old mappings continue to work, the new mapping does not.

net use h: \\anothercomputer\d$\somefolder /persistent:yes

I only know that this doesn't work because subsequent scripts that depend on this drive mapping are all failing, saying that the location doesn't exist. If I try to run the same connection script manually, net use says

System error 85 has occurred... The local device name is already in use.

Ok, so it mapped already somewhere, somehow. So I try to unmap it using net use h: /d and that fails.

The network connection could not be found.

So I cannot map it. I cannot unmap it. Apparently it exists in some networking purgatory. What is going on here? How can I get this new location mapped and visible to my scripts?

لا يوجد حل صحيح

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top