Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the 'Change location automatically based on network' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Change location automatically based on network
Authored by: mdzorn on Jan 18, '05 11:40:28PM

Am I missing someting here?

My 12in G4 laptop automatically switches locations (i.e., network locations).
I have the network set to "Automatic". Whenever a network (wireless or wired) is available, MacOSX checks them all out and connects to the one that is available. The order in the Network Status list defines the priority. I connect wireless and by Ethernet at home, at work, and various locations around the counry and never ever manually switch locations. So there is no need for an automatic script to do it either.

So I don't quite understand why you would need a script to changethe location. The program Location X is useful if and only if you want additional automatic changes, e.g., change the preferred printer, mounting disks, etc. that are specific for each location. But just to connect to your network, the Automatic Network preferences is more than enough.

For each specific network (Home, Work, Starbucks, etc.) create a location in network preferences. The Automoatic setting will select the best location from the list.

[Airport asks you whether you want to remember a specific wireless network. If you choose yes, it will automatically connect to the best available wireless network.]

[ Reply to This | # ]
Change location automatically based on network
Authored by: lagroue on Jan 19, '05 03:40:23AM

An example of usefulness of such a script :

When I'm home, my iBook acts as a server for some services (like web). It needs a fixed IP, so that other computers know how to reach it.

But when I travel, I have to switch to DHCP so that I can plug (yes, I'm old-fashioned) to the network I've come to.

The disavantage is that I have to remember to switch back to "Home" location when I come back, since DCHP stills works and that I have no clue I'm not serving any more.

This is just an example, there are certainly more cases.

[ Reply to This | # ]
Change location automatically based on network
Authored by: chris_on_hints on Jan 19, '05 08:57:59AM

As i understand it, the 'Automatic' location is just the default location where settings are to get an ip address from the server automatically (ie DHCP) for all of the different network types (Airport, ethernet, firewire etc). So whenever you connect to a network which wants you to use a specific IP address, you need to modify the network prefs to do it: For ages, my 'automatic' location had been changed to use a manual IP address, so it wasnt really automatic any more... I have renamed it 'Home' and created a new location 'Away' which has all the automatic settings. I dont think the 'Automatic' location name itself has any real relevance.

[ Reply to This | # ]
Change location automatically based on network
Authored by: mdzorn on Jan 20, '05 12:21:45AM
The Apple documentation states regarding the Automatic Network Preference:
This ( is the help I found on the Apple support site. It seems to apply to 10.2, but from what I can see a "Port Configuration" is the same as a new "Network Location". In this help article Apple recommends duplicating a Port Configuration and customizing it for each location. Then Automatic will be able to pick one of multiple configurations, i.e., scan through the defined Network Locations until it finds one that works or give up if it doesn't.

[ Reply to This | # ]