Subject: RE: Location manager type tool?
From: Steve McGrane (firstname.lastname@example.org)
Date: Thu Feb 08 2001 - 19:07:48 MST
Good thing this isn't windows where you have to reboot the machine (or
sleep/wake) to get the IP info to change...
FWIW, I often have to do a full stop/start on network to make it take
effect, the restart for some reason doesn't always work for me.
Mac Friendly Co-Location
From: Philip Good [mailto:email@example.com]
Sent: Thursday, February 08, 2001 7:39 PM
Subject: Re: Location manager type tool?
Here is what I use, it's not much, but works:
# switch between home and work ethernet
if [ $1 == "home" ]; then
echo "Switching to home:"
cp -f /etc/resolv.conf.home /etc/resolv.conf
cp -f /etc/sysconfig/network.home /etc/sysconfig/network
cp -f /etc/sysconfig/network-scripts/home.ifcfg-eth0
cp -f /etc/sysconfig/network-scripts/home.ifcfg-airport
elif [ $1 == "work" ]; then
echo "Switching to work:"
cp -f /etc/resolv.conf.work /etc/resolv.conf
cp -f /etc/sysconfig/network.work /etc/sysconfig/network
cp -f /etc/sysconfig/network-scripts/work.ifcfg-eth0
echo "Not a valid option: $1"
I'd like to make it more generic and check to make sure all the cp's
worked, but for now its simple and works. Just make sure you have the
files defined which are copied back and forth.
> >Any thoughts on the right way to do this?
> Must be synchronicity. I was just about to post this question. I'm
> a Linux newbie running YDL on a PowerBook G3/400 (Lombard). I'm
> still messing with trying to get it to recognize ethernet *at all*
> but when it does I'll need some kind of Location Manager-like tool...
> Megan Lynch
> Ethknow - http://www.ethknow.com
> Your Guide to the Ethnic Bay Area.
-- Philip Good Red Planet Development, Red Canyon Software, Good Chi Tai Chi
This archive was generated by hypermail 2a24 : Thu Feb 08 2001 - 19:41:37 MST