On 12 Mar 2003 16:48:46 -0800 James Sparenberg <[EMAIL PROTECTED]>
wrote:

> OK,
> 
>    I've fought with it till I'm blue in the face and it seems I finally
> have tricked my hardware into allowing me to use a wireless nic.  Now
> I've got to find out how to do something simple enough in theory... move
> around.  IE I've got wireless at the office wireless at home and
> wireless at Borders (or Starbucks or McD's)  So ... each has it's own
> config/wep key... and no matter what I do it seems that 9.x is
> determined to overwrite one config with the other.... Danged if I can
> get multiple profiles working... Has any one got a tip... I'd love to
> suspend the box... go to work... use the box... suspend... go home
> use... just like windows people..... so far... I can only 
> 
> A.  Use a wired NIC everywhere but home
> B.  Reconfigure (a 20 minute nightmare) every time I move.
> C.  Cry insanely in my beer......
> 
> How have any of you solved this?  
> 
> James

Here's a quick script I hacked a while back...  it's very specific to my
travelling; but could serve as a guide...

Essentially, I got the networking working correctly at each location and
copied each set of working files like this:
/etc/resolv.conf --> /usr/local/network/resolv.conf.{NC,SC,dial}
/etc/sysconfig/network -->
/usr/local/network/sysconfig/network.{NC,SC,dial}

Then, when I travel to another location, I simply fire up the laptop and
as root, issue:

# chnet NC    (DSL connected LAN)
# chnet SC    (LAN to modem-sharing desktop) 
# chnet dial  (direct dial)

and I'm up and running....  Since I'll be travelling more soon, I plan to
rework this to allow multi-location dial access using my ISP's list of
dialups... 

Aside:  if anyone has been able to compile kaptain
(http://kaptain.sourceforge.net) on ML9.0, I'd be interested in how to
solve the Qt dependancies...

HTH,
Pierre


file:/usr/local/bin/chnet: 
#!/bin/bash

NETSRC=/usr/local/network
RESOLV=resolv.conf
NETWORK=sysconfig/network
case $1 in
    eth*|LAN|NC)
        cp -a ${NETSRC}/${RESOLV}.NC /etc/${RESOLV}
        cp -a ${NETSRC}/${NETWORK}.NC /etc/${NETWORK}
        service network restart
        ;;
    SC)
        cp -a ${NETSRC}/${RESOLV}.SC /etc/${RESOLV}
        cp -a ${NETSRC}/${NETWORK}.SC /etc/${NETWORK}
        service network restart
        ;;
    dial*|mod*)
        rm -f /dev/modem
        modprobe lt_modem
        ln -s /dev/tts/LT0 /dev/modem
        cp -a ${NETSRC}/${RESOLV}.dial /etc/${RESOLV}
        cp -a ${NETSRC}/${NETWORK}.dial /etc/${NETWORK}
        route del default
        ;;
    "")
        echo <<EOF
Usage:
        $0 <location>
EOF
        ;;
esac

Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to