[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Setting up 2 alternate environments



On Mon, Mar 13, 2000 at 01:02:23AM +1100, markm@student.unsw.edu.au wrote:
> I would like to set up my linux system so that I can operate in two
> separate environments, hopefully selectable at the lilo boot prompt.
> 
[...]
> What do others do in this situation? Would chroot help?

I have an ethernet segment with 3 machines. When offline, these machines
work together. I have to alternative isp's I sometimes connect to.
When I am online, the other two machines reach the net via masquerading.

When I boot, i load the isdn-card module, and call on of the isp_script, 
which give me a "default" ISP. This script will 

a) adjust the leafnode config file (what is my upstream news server)
b) adjust my exim.conf (what is my smarthost at this isp)
c) kill the ipppd deamon if it is running 
d) kill and recreate the ippp0 device and set it up with outgoing number
and so on

If I want to use the other ISP, i run another script like this with
other parameters.

When I want to connect, I run the "up" script which

a) command "up" to the isdn interface
b) report my current ip to my name service at dyndns.com
c) changes host.conf and resolv.conf to the "connected" versions
d) restarts the name-server
e) restarts junkbuster
f) starts a ping process to some machine to keep the connection alive
g) runs ntpdate

The "down" script
a) kills the ping
b) command "down" to the ippp0 interface
c) changes  host.conf and resolv.conf to the "unconnected" versions
d) restarts nameserver
e) restarts junkbuster

Johan Ur Riise


Reply to: