Date: Tue, 18 Jun 2002 01:50:08 +0800 (CST) From: Kang-min Liu <gugod@gugod.org> To: tony@saign.com Cc: freebsd-mobile@FreeBSD.ORG Subject: Re: start_if.wi0?? Message-ID: <20020618.015008.59554913.gugod@gugod.org> In-Reply-To: <000001c215bb$0bf098e0$1401a8c0@frankenmobl> References: <000001c215bb$0bf098e0$1401a8c0@frankenmobl>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --]
From: "Tony Saign" <tony@saign.com>
Subject: start_if.wi0??
Date: Sun, 16 Jun 2002 21:54:21 -0700
> Anyone have an example of a script to connect to 2 different nets?
> I've been playing around with it without success!
>
> Running 4.6 -stable and MiniPCI Intersil 802.11b card.
here is my script. every time I mv to a new network, I
change the content of /etc/wi_where to match what I need.
enjoy it. :)
---8<---
wi_where=`cat /etc/wi_where`
case ${wi_where} in
[Hh][Oo][Mm][Ee])
ifconfig_wi0="inet 192.168.1.3 netmask 0xfffffff0 wepmode on wepkey xxxxxx channel 3 ssid XXXXXX media auto"
defaultrouter="192.168.1.1"
/bin/cp -f /etc/resolv.conf.home /etc/resolv.conf
;;
[Nn][Tt][Uu])
ifconfig wi0 wepmode on wepkey xxxxxx media auto
ifconfig_wi0="dhcp"
;;
[Aa][Uu][Tt][Oo])
ifconfig wi0 wepmode off media auto
ifconfig_wi0="dhcp"
;;
esac
--->8---
[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (FreeBSD)
iD8DBQA9DiFTt9iYDlxKbHARAkGhAKCA2nAvCCEmT8U7NdPrwd7RGp+pWwCfYTU5
YaXYQxg793IYXdpFWlDMqAo=
=AVtz
-----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020618.015008.59554913.gugod>
