Location Profiles For Unix Laptops?
Cyron Green asks: "I travel quite a bit with my laptop (it keeps me company). I hate having to change my NIC settings everytime I stop somewhere or I go from work to home. Is there any type of Location Managment software out there for Linux or FreeBSD?"
to switch to your home or work network settings respectively. However, at some time around Red Hat 6.x, this stopped working. By then, though, I wasn't using the laptop enough for me to bother to find out why... Can anyone shed any light on this?
"The invisible and the non-existent look very much alike." -- Delos B. McKown
That was driving me nuts too, so I installed sudo, gave my user account sudo rights to ifconfig, route, and pump. Then my scripts looks similar to:
/etc/resolv.conf to which one you ned in the bash script. I dont have that problem as I just use my ISP's named from wherever I am. A little slower, but I dont have to change anything!
#!/bin/bash
sudo ifconfig eth0 192.168.0.50
sudo route add default gw 192.168.0.1
or...
#!/bin/bash
sudo pump -i eth0
Now, if you need to change your resolv.conf, maintain several and chown them to your user account. That way you can have resolv.conf.work, resolv.conf.home, resolv.conf.client3 and hell, you could symlink
After I made all my scripts, I put a menu in my KDE bar that had links to all my scripts. I bring the laptop out of suspend, click the bar, choose where I am, and poof.
I've heard of some people setting up init scripts on laptops to use the (generally) unused runlevel 4. Usually I've heard about this in terms of enabling some power management features, but I don't see why you couldn't change the network startup scripts while you were at it. Once you'd done that it would just be a matter of typing init 4 or init 5 to switch between two different profiles.
_____________
I don't want free as in beer. I just want free beer.