Take Command will not release network drive

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
Oct 2, 2008
19
0
#1
I am using the following commands in a script:

net use v: /d
net use v: \\192.168.10.50\issm50_m
... commands
delay 5

net use v: /d
net use v: \\192.168.10.30\issm30_m

The second /d command is refused with a message that the drive is being used by another process. I do not have this problem in 4nt.exe. What am I doing wrong?
 

Charles Dye

Super Moderator
Staff member
May 20, 2008
3,376
39
Albuquerque, NM
prospero.unm.edu
#2
I am using the following commands in a script:

net use v: /d
net use v: \\192.168.10.50\issm50_m
... commands
delay 5

net use v: /d
net use v: \\192.168.10.30\issm30_m

The second /d command is refused with a message that the drive is being used by another process. I do not have this problem in 4nt.exe. What am I doing wrong?
Works for me, using one of our servers in place of \\192.168.10.50 and DIR V: as "commands". I'm guessing that the problem is in the part you haven't given us. Changing the current drive to V:, perhaps?
 

rconn

Administrator
Staff member
May 14, 2008
10,099
85
#3
rawood11 wrote:

> I am using the following commands in a script:
>
> net use v: /d
> net use v: \\192.168.10.50\issm50_m
> ... commands
> delay 5
>
> net use v: /d
> net use v: \\192.168.10.30\issm30_m
>
> The second /d command is refused with a message that the drive
> is being used by another process. I do not have this problem in
> 4nt.exe. What am I doing wrong?

Take Command and TCC / 4NT do not (cannot!) have anything to do with the
behavior of net.exe (which is a Microsoft external app).

Can you reproduce this with *only* the "net" commands (i.e., removing
all of the commands referenced by your "... commands"?

Rex Conn
JP Software