Solved

Connect to network drive timeout Windows 7

Posted on 2013-01-01
3
1,109 Views
Last Modified: 2013-01-02
I have a work laptop computer that is mapped to 8 network drives. I can't change that, it's set by IT.

Problem is when I boot when not connected to the network, it takes about 30 seconds for W7 to give up looking for a network drive. That's 8 drives 30 secs each or about 4 minutes of wasted boot time.

How can I set it to give up (timeout) faster? 10 sec? I've googled high and low for an answer and it doesn't look like there is a setting for that. Is there?

Thanks in advance,

swjtx99
0
Comment
Question by:swjtx99
3 Comments
 
LVL 17

Expert Comment

by:sgsm81
ID: 38735721
0
 
LVL 16

Accepted Solution

by:
terencino earned 500 total points
ID: 38736166
Mapped drives are a nuisance if you use your work PC offline, even if it is reasonably quick, because of the red Xs and annoying messages. I delete all the mapped drives using a local logoff script before I take my laptop out of the office. So when I boot at home or wherever, it goes straight to desktop, no attempts to login to network shares that aren't there. I have another script to remap everything if I connect remotely like with VPN. And when you're back in the office, your domain Group Policy scripts will automatically log you on as usual.

Next step is copy the network mappings, these are useful to know in any case.

First manually disconnect from all your network drives. This will clear out remembered connections. Logout & Login again just to make sure your domain script is doing the right thing. The logoff script is a simple VBScript you can have on your desktop or local group policy logoff, just copy to a text file, save as say DeMap.vbs, run it to disconnect the drives (it takes about 5 seconds to disconnect everything), then you are ready to shutdown and take your laptop home.
ON ERROR RESUME NEXT
Set oNetwork = CreateObject("WScript.Network")
Set clDrives = oNetwork.EnumNetworkDrives
For i = 0 to clDrives.Count -1 Step 2
    oNetwork.RemoveNetworkDrive clDrives.Item(i), True, True
Next 
set oNetwork = Nothing
wscript.quit

Open in new window

And setup another script, say ReMap.vbs as follows, to re-map the shares after connecting to your network via VPN
ON ERROR RESUME NEXT
Set oNetwork = CreateObject("WScript.Network")
oNetwork.MapNetworkDrive "X:", "\\SERVER\SHAREX",True
oNetwork.MapNetworkDrive "Y:", "\\SERVER\SHAREY",True
oNetwork.MapNetworkDrive "Z:", "\\SERVER\SHAREZ",True

Open in new window

Hope that helps
...Terry
0
 

Author Closing Comment

by:swjtx99
ID: 38738492
This works perfectly. Also good to have a quick method for adding back network drives that (for whatever reason) get lost.

Thanks!
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Internet Explorer 11.0 crashed. 10 35
Using autoplay with Windows 7 27 55
RDP Connection Issues 12 50
lync, outlook 1 20
Article by: Lee
Windows 7 Ultimate and Enterprise (and 2008 R2) introduced a new feature you may not be aware of - Boot from VHD.   Boot from VHD (or what Microsoft refers to asNative Boot allows you to install Windows to a VHD (Virtual Hard Disk) file that is t…
Possible fixes for Windows 7 and Windows Server 2008 updating problem. Solutions mentioned are from Microsoft themselves. I started a case with them from our Microsoft Silver Partner option to open a case and get direct support from Microsoft. If s…
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…
The viewer will learn how to successfully download and install the SARDU utility on Windows 7, without downloading adware.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now