On Wednesday 07 February 2007 23:12, Iain Buchanan wrote: > On Wed, 2007-02-07 at 10:37 +0000, Peter Lewis wrote: > > I start my wireless network with the script > > > > /etc/init.d/net.eth2 > > > > which is started by init in the "default" runlevel. > > > > I also have > > > > /etc/init.d/netmount > > > > to mount some samba shares, and which is also started my init in the > > "default" runlevel, but depends on "net" from the line: > > > > local myneed="net" > > > > So, as I understand it, this makes sure that init starts net.eth* before > > starting netmount. That's good. However, eth2 is on a DHCP-enabled > > connection and takes a few seconds to come up after starting the script. > > By the time netmount is started, net.eth2 has not finished coming up, so > > netmount fails and the samba shares are never mounted automatically. > > > > Is there a way to make the netmount script wait for a route to exist > > before attempting to connect? > > net.eth2 "shouldn't" return (by default) until it has a dhcp address, > which means all other scripts starting after it will wait until you have > an address. > > Things you might have done to change the default behaviour include > RC_PARALLEL_STARTUP, and RC_NET_STRICT_CHECKING in /etc/conf.d/rc. > > You can set them to "no", and "yes" respectively and see if the > following scripts wait...
Thanks for this. I just checked and I have those variables set up correctly. Yes, upon closer inspection, the problem is slightly weirder. I'm using an Intel ipw3945 wireless device, which requires a daemon to run to "regulate it" or something. So, I also have /etc/init.d/ipw3945d start at boot. This must start before I can access eth2. However, I've actually just noticed that I don't explicitly start net.eth2 in any runlevel. It seems that this is kicked into action by ipw3945d somewhere (though I can't see where). The /etc/init.d/net.eth2 process just seems to fork off to the background, meaning that init carries on booting, and hence fails on netmount. Anyone any experience with this? Cheers, Pete. -- gentoo-user@gentoo.org mailing list