Switching wired <-> wireless in a user-friendly manner, possible?

AT Matik asstec at matik.com.br
Sun Nov 27 02:36:50 GMT 2005


On Saturday 26 November 2005 17:19, Hans Nieser wrote:
>
> I am guessing that what needs to happen is, as soon as fxp0 becomes
> inactive, the default route needs to be updated so it will route over the
> ipw0 interface. What is the best way to accomplish this? Do I have to
> write a shellscript that continiously checks for fxp0's status and then
> somehow update the default route, or are there facilities available for
> this? _______________________________________________


yep, you got it ;)

may be you like what I do

i have DHCP for my nic in rc.conf

when my eth is up (sis0 in my case)  nothing happens as getting the config 
from the dhcp server

else I call a script to configure my wireless connection (/etc/start-wif)

so you may check running this in crontab as I understand you unplug the cable 
and run around ;)

João

this runs on 6.0 but should work correctly on 5.x as well

################################
#!/bin/sh
status="`ifconfig sis0 | grep status | awk '{print $2$3}'`"

case ${status} in
        nocarrier)
        (/etc/start-wif &)
        ;;
        *)
        logger -s "running ethernet dhclient"
        ;;
        esac
#################################







A mensagem foi scaneada pelo sistema de e-mail e pode ser considerada segura.
Service fornecido pelo Datacenter Matik  https://datacenter.matik.com.br


More information about the freebsd-mobile mailing list