Change Hosts file based on connection - Windows

1

So I have a laptop. It connects to places wirelessly. Home, work and public. I want to change the host file based on the network I'm connected too.

Realistically, in my situation, I should have 2 sets of IPs:

Home Network (Inside Network):

192.168.1.101 HomePC
192.168.1.102 HomePrinter

Home Network (Outside Network):

1.2.3.4 HomePC
1.2.3.5 HomePrinter

Work (Inside Network):

192.168.50.101 WorkPC
192.168.50.102 WorkPrinter

Work (Outside Network):

70.2.3.4 WorkPC
70.2.3.5 WorkPrinter

I need an easy way to toggle between the 3 states, preferably automatically based on Hotspot I'm connected too.

Powershell scripts, open-source, etc preferred, but I'm not adverse to spending if the best tool is affordable

WernerCD

Posted 2013-10-21T14:43:13.730

Reputation: 4 263

Answers

1

So far here is what I found:

  • Mobile Net Switcher, which does much more than just switching hosts file. It costs 29€.
  • Switch Location (developed by Kevin Blake), which is totally free, but seems to be crashing on Windows 8.1 x64.

Did you find anything else?

SiamKreative

Posted 2013-10-21T14:43:13.730

Reputation: 11