* [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address?
@ 2005-09-25 3:52 michael
2005-09-25 5:30 ` Iain Buchanan
0 siblings, 1 reply; 4+ messages in thread
From: michael @ 2005-09-25 3:52 UTC (permalink / raw
To: gentoo-user
I have a computer with both a wired and wireless network card. At home I
use the wired connection, but when out I use the wireless.
Normally, I use the default net.eth0 for my wired connection, and my own
script for wireless :
ifconfig eth1 up
iwconfig eth1 essid "foo"
dhcpcd eth1
If I enable them both using rc-update, then if one isn't available (I
only plug in the wired network when I know wireless is not available)
the init process will wait until the dhcpcd times out, which is quite
long (and it needs to be, because some access points seem to take a
long time).
Is there some way I can have dhcpcd to run in the background, and to
provide an IP address to my interface when it gets a response from the
server? I seem to remember busybox had script that did this; is there a
general solution?
Thanks,
Michael
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address?
2005-09-25 3:52 [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address? michael
@ 2005-09-25 5:30 ` Iain Buchanan
2005-09-25 13:57 ` Luk van den Borne
0 siblings, 1 reply; 4+ messages in thread
From: Iain Buchanan @ 2005-09-25 5:30 UTC (permalink / raw
To: gentoo-user
On Sat, 2005-09-24 at 20:52 -0700, michael@michaelshiloh.com wrote:
> I have a computer with both a wired and wireless network card. At home I
> use the wired connection, but when out I use the wireless.
[snip]
> Is there some way I can have dhcpcd to run in the background, and to
> provide an IP address to my interface when it gets a response from the
> server? I seem to remember busybox had script that did this; is there a
> general solution?
The first thing that comes to mind is to set
RC_PARALLEL_STARTUP="yes"
in /etc/conf.d/rc
However, lots of things rely on the net.* scripts before they start.
Have a look at the output of
`egrep need.*net /etc/init.d/*`
and you'll see every service that will wait for your network script to
start (which means waiting for a dhcp response)
The second thing that came to my mind, and this would probably rely on
you only getting a dhcp for the wireless, and not the wired lan, would
be to "roll your own" /etc/init.d/net.eth1 script. Make it exactly the
same as /etc/init.d/net.lo, but in the depend() function, add something
like "provide mywireless". This, coupled with parallel startup, should
mean that no other init script will require your net.eth1 connection and
it can take time without holding other scripts up.
I've never tried this idea, so it could be fundamentally flawed, but its
just a thought!
HTH,
--
Iain Buchanan <iaindb@netspace.net.au>
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address?
2005-09-25 5:30 ` Iain Buchanan
@ 2005-09-25 13:57 ` Luk van den Borne
2005-09-25 18:10 ` John Jolet
0 siblings, 1 reply; 4+ messages in thread
From: Luk van den Borne @ 2005-09-25 13:57 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1783 bytes --]
Maybe you should have a look at ifplugd. It will background the networking
part and bring up those interfaces that are actually plugged in.
Luk van den Borne
On 9/25/05, Iain Buchanan <iaindb@netspace.net.au> wrote:
>
> On Sat, 2005-09-24 at 20:52 -0700, michael@michaelshiloh.com wrote:
> > I have a computer with both a wired and wireless network card. At home I
> > use the wired connection, but when out I use the wireless.
> [snip]
> > Is there some way I can have dhcpcd to run in the background, and to
> > provide an IP address to my interface when it gets a response from the
> > server? I seem to remember busybox had script that did this; is there a
> > general solution?
>
> The first thing that comes to mind is to set
> RC_PARALLEL_STARTUP="yes"
> in /etc/conf.d/rc
>
> However, lots of things rely on the net.* scripts before they start.
> Have a look at the output of
> `egrep need.*net /etc/init.d/*`
> and you'll see every service that will wait for your network script to
> start (which means waiting for a dhcp response)
>
> The second thing that came to my mind, and this would probably rely on
> you only getting a dhcp for the wireless, and not the wired lan, would
> be to "roll your own" /etc/init.d/net.eth1 script. Make it exactly the
> same as /etc/init.d/net.lo, but in the depend() function, add something
> like "provide mywireless". This, coupled with parallel startup, should
> mean that no other init script will require your net.eth1 connection and
> it can take time without holding other scripts up.
>
> I've never tried this idea, so it could be fundamentally flawed, but its
> just a thought!
>
> HTH,
> --
> Iain Buchanan <iaindb@netspace.net.au>
>
> --
> gentoo-user@gentoo.org mailing list
>
>
[-- Attachment #2: Type: text/html, Size: 2296 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address?
2005-09-25 13:57 ` Luk van den Borne
@ 2005-09-25 18:10 ` John Jolet
0 siblings, 0 replies; 4+ messages in thread
From: John Jolet @ 2005-09-25 18:10 UTC (permalink / raw
To: gentoo-user
On Sunday 25 September 2005 08:57, Luk van den Borne wrote:
> Maybe you should have a look at ifplugd. It will background the networking
> part and bring up those interfaces that are actually plugged in.
I'm using that for my wired network. works great.
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2005-09-25 18:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-25 3:52 [gentoo-user] Can I make dhcpcd run in background when trying to get an ip address? michael
2005-09-25 5:30 ` Iain Buchanan
2005-09-25 13:57 ` Luk van den Borne
2005-09-25 18:10 ` John Jolet
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox