Subject: switching from Ethernet to PPP
To: None <netbsd-help@NetBSD.ORG>
From: Amitai Schlair <amitai.schlair@usa.net>
List: netbsd-help
Date: 07/20/1998 01:59:48
I've got a machine, currently connected to an Ethernet network, that
will be moving off that network in a month or so. I've already
configured pppd. At this point, I'm trying to determine what commands
need to be issued in order to switch between the machine's Ethernet
configuration and a PPP setup, so I can write a script to make this
switch on the fly. Issues I've considered:

- routing (especially the default route)

  I've read route(8). It doesn't explain things further (to me at
  least). Do I need to delete the Ethernet config's default route before
  letting pppd add its own default route?

  This is what confuses me most, as I don't grok routing too deeply.

- name resolution

  It's as simple as swapping out one resolv.conf and swapping in
  the other, right?

- IPNAT

  I wrote alternate rules for the ppp0 interface; they seem to work
  fine. Swapping in an /etc/ipnat.conf with the PPP rules and running
  'ipnat -CF -f /etc/ipnat.conf' ought to do the trick for this.

Other, minor questions:

  How can I have pppd notify me when PPP is up?

  Any caveats against putting 'pppd /dev/tty00 38400' in rc.local? (This
  is a demand-dial setup.)

Any other things I need to think about?

- Amitai

-- 
Even when I'm sick and depressed, I love life.
     -- Artur Rubinstein