[ltp] Network connection and bootup

Matthias Posseldt linux-thinkpad@linux-thinkpad.org
Sat, 8 Nov 2003 15:54:06 +0100


On Saturday 08 November 2003 15:29, S. Anthony Sequeira wrote:
> I am building a TP360e using LFS (www.linuxfromscratch.org)
>
> I would like to know the strategies used (by distros or otherwise) to
> handle bootup scripts when the laptop is connected to a network.
>
> I run various daemons that I want available when I am connected to a LAN
> (as opposed to my ISP via ppp - next issue).  Things like samba, ssh,
> nfs.
>
> I have thought about using another bootup script which starts and stops
> the relevant daemons.  This script will go in start_fn and stop_fn in
> /etc/pmcia/network.opts.  I had an abortive attempt at putting _all_
> network daemon bootup scripts in this function, with pretty bad results.

I--on Gentoo--use a concept to switch to a different runlevel when in 
different network environments. I use a program called quickswitch for that 
task. It copies around some configuration files (resolv.conf, conf.net, etc.) 
and then switches to a different runlevel. It works on Gentoo, because Gentoo 
has boot script dependencies. Therefore, if I change from network1 to 
network2, Gentoo will restart all services that depend on network.

Also, Gentoo has an unlimited number of runlevels. But I use three different 
ones, so you can use level 3, 4, 5 for different configurations if you like.

Ciao, Matthias

-- 
There is still the danger of EU software patents!

http://swpat.ffii.org/