Disconnect drive mappings in batch file in Win2k

J

Jeff

I made the mistake of adding a drive mapping on my Win2k
Domain controller login script to a server that will be
offline for at least a few days while we ship it to a
remote location. The problem I am seeing is when the box
is brought down everyones computers take a long time to
open up My Computer or Explorer. I assume the problem is
that it is looking for the unavailable resource. I have
since removed the drive mapping from the Domains login
script in the group policy, but the drive mappings are
still connected on everyones machine. Rebooting leaves the
connection restored. I tried running the command: net use
\\servername\sharename /DELETE but it comes back saying
the network connection can not be found. The only way I
can get that command to work is by first mapping the share
using the net use command and THEN running the delete
switch. Can someone please tell me how I can remove this
mapping until the server is in its new home so that I dont
have to manually disconnect the mapping on everyone in the
companies computer?

Thanks
 
R

Ray at

Try using

net use TheDriveLetter: /D

This is partially why [I think] it is good to use /p:n (persitence = no) in
mappings via logon script.

Ray at work
 
M

Mark V

Try using

net use TheDriveLetter: /D

This is partially why [I think] it is good to use /p:n (persitence
= no) in mappings via logon script.

Or even better IMO is to set the defaults for persistent:no at OS
installation.
 
R

Ray at

How does one do that? From what I remember, if you do not specify
persistence, it will use whatever you specified the last time you mapped a
drive, and if you have never specified, the default is yes. Hmm, maybe I
can find it... I don't see anything jumping out at me in the registry like
in winlogon or anything.

Thanks,

Ray at work
 
R

Ray at

That was what I mentioned, the /p:n, but he said something about setting
that to be the default at OS installation.

Ray at work
 
D

DerDude

REM

I made the mistake of adding a drive mapping on my Win2k
Domain controller login script to a server that will be
offline for at least a few days while we ship it to a
remote location. The problem I am seeing is when the box
is brought down everyones computers take a long time to
open up My Computer or Explorer. I assume the problem is
that it is looking for the unavailable resource. I have
since removed the drive mapping from the Domains login
script in the group policy, but the drive mappings are
still connected on everyones machine. Rebooting leaves the
connection restored. I tried running the command: net use
\\servername\sharename /DELETE but it comes back saying
the network connection can not be found. The only way I
can get that command to work is by first mapping the share
using the net use command and THEN running the delete
switch. Can someone please tell me how I can remove this
mapping until the server is in its new home so that I dont
have to manually disconnect the mapping on everyone in the
companies computer?

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top