Take the 2-minute tour ×

I have connected my work computer to the company network via vpn. Unfortunately, the vpn is not up on boot nor on login, so my normally mapped drives are not available. How may I list the normally mapped drives to map them now that the vpn is providing connectivity? Is there a way to automatically try the login time mapping?

share|improve this question

3 Answers 3

up vote 1 down vote accepted

Further to John T's suggestion to try run the script after connecting:

You could try determining your logon server as follows:

At a command prompt, type:

set logonserver [enter]

(note: this doesn't actually set anything, just displays it)

This may return the name of a domain controller.

If it does, type:

start \\whatevernameitreturned\netlogon

Browsing that directory, you can hopefully determine the name of the batch file/script that does the drive mapping and run it (and create a shortcut to it).

Whether the script will actually work properly or not is another story.

Another lower tech option (if you can go into the office and logon properly):

-Note what your regular drive mappings are:

At a command prompt, type:

net use <enter>

You'll see something like this:

m: \\domain\share    
p: \\domain\anothershare

-Create a batch file to to the mappings:

net use m: \\domain\share
net use p: \\domain\anothershare

Then run that batch file after you're connected.

share|improve this answer
I ended up getting back to the office two days later and copying the mounted drives to a script. Later, running the script after logging in to the VPN proved to work –  mpez0 Feb 20 '11 at 1:20

No. When connected to the network, your machine interrogates one of the company's domain controllers for the login script associated with your Active Directory user object. If you know the path to the name/IP address of the domain controller you can browse it for the NETLOGON share and find the script in there. If you do not, ask your network administrator to give you the appropriate script to run from your desktop after connecting VPN.

share|improve this answer
does a log exist with the failed mounts? –  mpez0 Feb 15 '11 at 22:56
If a mount failed it may show up in event viewer, but if you are not connected to a domain controller it has no way of failing since it didn't try in the first place. –  John T Feb 15 '11 at 22:59

Here is the syntax that will help you disconnect mapped drives, rearrange mapped drive letters, and reconnect them.

Net Use at Microsoft.com

Make a batch file you can run AFTER VPN is connected.

I'd /delete all networked drives first, and then add back in those you want to use.

"It's the only way to be sure." - Sigourney Weaver, Aliens

share|improve this answer

Your Answer


