3

I have set up some network path in Windows 8.1 which can only be accessed when I'm connected to a VPN. I don't want to re-map/add them every time when I connect to the VPN (I do this quite often).

If I'm not connected to the VPN, however, explorer.exe gets very laggy. I can fix the issue by disabling the "Client for Microsoft Networks" in the properties of the network adapter (see https://superuser.com/a/390043). But then I can't access any network path. This is even worse, because then I can't access my locale network path which I need always, of course.

I tried it with both ways: mapping a drive letter to the network path or using the full name. Problem exists in both cases.

Another annyoing thing is: when drag-dropping a file between two explorer windows and randomly hovering the non-available network path "half-way" (because it's in the list that teh mouse cursor needs to pass) while dragging lets the explroer.exe hang for ~3-5 seconds as if crashed.

How do I set up Windows to not get laggy when having non-available network paths without disabling the network path functionality at all?

With "laggy" I mean two things:

  1. all programs accessing filesystem using Windows own Open/Save dialogs "hang" for ~3 seconds
  2. I have to hit F5 after each filesystem operation in Explorer (copy, move, etc.), see Explorer does not auto-refresh
3
  • Placing this as a comment rather than an answer, because it does not answer your question, but rather is a workaround. Have you considered creating a batchfile to map and unmap your network drives? Launching the batchfile could be all you need to toggle this on and off.
    – LPChip
    Oct 5, 2014 at 14:41
  • Also, can you define "laggy" Because on my company laptop running windows 8.1, windows does not get "laggy" when the network paths aren't found, which indicates 2 things: or the problem you have is weird and shouldn't happen, or our definitions of laggy aren't the same (I expect the last one)
    – LPChip
    Oct 5, 2014 at 14:43
  • @LPChip for laggy see my question, I edited it. A Batch file would be an annoying hack that I will only do if there's really no other "clean" solution. The problem stops as soon as I'm connected to the VPN (I only connect when I'm working, always-on is a no-go) or remove the network path in Explorer (a no-go, because I need it often).
    – Foo Bar
    Oct 5, 2014 at 14:49

2 Answers 2

1

I solved it now this way. I added a firewall rule to the Windows firewall (incoming and outgoing with the same name) and enable/disable it via batch file with netsh advfirewall firewall set rule name="rulename" new enable=yes (resp. no). This works now perfectly fine.

0

You can use c:/windows/system32/drivers/etc/hosts file to block the VPN destinations. For example, add these lines will block vpn-computer1 and 2:

127.0.0.1        vpn-computer1
127.0.0.1        vpn-computer2

When VPN is connected, these entry needs to be removed, which can be done with a batch file.

4
  • And it requires restarting the computer each time it's changed. -1 Oct 5, 2014 at 20:34
  • 3
    No, it does not require reboot. I literally just tested on my computer, windows 7 pro. Please verify your claim before down vote.
    – Dummy
    Oct 5, 2014 at 20:38
  • Thanks, I'll try that and report back afterwards (and accept if it works well).
    – Foo Bar
    Oct 7, 2014 at 20:37
  • No, this won't work, because I need to block IP addresses, not domain names. So, I need a way to configure the Windows firewall via batch file to (dis)allow on VPN (dis)connect.
    – Foo Bar
    Oct 11, 2014 at 11:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .