On Tue, 9 Jun 1998, Ian Stuart wrote: > I'm using a i386 portable with 2.0.34 installed. I have a requirement to > plug this machine into various subnets, depending on where I'm working > within my organisation. > > Is there a way to configure the system so that I can use > (a) 4 or 5 different gateways (only one of which will be reachable at one > time) and > (b) 4 or 5 IP numbers, only one of which will be valid at any one time?
There are very few files that actually contain IP numbers, viz. /etc/resolv.conf, /etc/hosts, /etc/networks and /etc/init.d/network and the first of these would probably stay the same as we're talking subnets. So all you need is a few scripts hacked from the last, that delete the two (network and gateway) routes, ifconfig the new number, and add the two new routes. They could meanwhile overwrite the middle two files as well. ifconfig and route commands are totally dynamic; I don't think daemons etc. should hold onto any of this information. (I don't have a clue what reads /etc/networks though I suppose you could use it yourself to delete the appropriate -net route.) Cheers, -- Email: [EMAIL PROTECTED] Tel: +44 1908 653 739 Fax: +44 1908 655 151 Snail: David Wright, Earth Science Dept., Milton Keynes, England, MK7 6AA Disclaimer: These addresses are only for reaching me, and do not signify official stationery. Views expressed here are either my own or plagiarised. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]