Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to choose which DHCP client to use? (SOLVED)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Fri Mar 04, 2005 9:22 pm    Post subject: How to choose which DHCP client to use? (SOLVED) Reply with quote

I was wondering how the /etc/init.d/net.ethX script determines which dhcp client to try to us.

Right now I am using dhcpcd, but would like to use dhcp. If I unmerge the first and then merge the second, while it pick it up automatically?


Last edited by Headrush on Fri Mar 04, 2005 11:45 pm; edited 3 times in total
Back to top
View user's profile Send private message
Sith_Happens
Veteran
Veteran


Joined: 15 Dec 2004
Posts: 1807
Location: The University of Maryland at College Park

PostPosted: Fri Mar 04, 2005 9:30 pm    Post subject: Reply with quote

dhcp comes with it's own initscript you use in place of net.eth0. Just remove net.eth0 from startup and add dhcp. You can configure the dhcp initscript in /etc/conf.d/dhcp.
_________________
"That question was less stupid; though you asked it in a profoundly stupid way."
I'm the brains behind Jackass! | Tutorials: Shorewall
Back to top
View user's profile Send private message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Fri Mar 04, 2005 9:36 pm    Post subject: Reply with quote

Sith_Happens wrote:
dhcp comes with it's own initscript you use in place of net.eth0.

There is no problem in getting dhcp to work.
I'm looking more for info into the gentoo framework. I have read that baselayout supports several methods (dhcp dhclient, pump, etc), but I don't see where to designate which one it uses.
Back to top
View user's profile Send private message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Fri Mar 04, 2005 9:39 pm    Post subject: Reply with quote

Looks like this is supported in baselayout 1.11+ only.
So it looks like dhcpd is hardcoded in baselayout-1.9.4. (Please correct me if wrong)
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Fri Mar 04, 2005 9:41 pm    Post subject: Reply with quote

Sith_Happens wrote:
dhcp comes with it's own initscript you use in place of net.eth0. Just remove net.eth0 from startup and add dhcp. You can configure the dhcp initscript in /etc/conf.d/dhcp.


Uh wrong :roll:

baselayout-1.11.9-r1 allows dhcpcd, udhcpc, pump and dhclient.

dhcpcd - the current gentoo default. Best all rounder
udhcpc - my personal choice as it's very light weight and the source is easy to read/patch/maintain. The choice for low memory environments - like embedded.
dhclient - the most powerful dhcp client, but also cumbersome (the source is not very well written imo)
pump - has problems with some ISPs and is not maintained by RedHat anymore. The worst - avoid imo

For dhclient and udhcpc you may need the below patch with baselayout-1.11.9-r1 depending on your network
https://bugs.gentoo.org/show_bug.cgi?id=81119
Back to top
View user's profile Send private message
Sith_Happens
Veteran
Veteran


Joined: 15 Dec 2004
Posts: 1807
Location: The University of Maryland at College Park

PostPosted: Fri Mar 04, 2005 9:44 pm    Post subject: Reply with quote

Nevermind
_________________
"That question was less stupid; though you asked it in a profoundly stupid way."
I'm the brains behind Jackass! | Tutorials: Shorewall
Back to top
View user's profile Send private message
Headrush
Watchman
Watchman


Joined: 06 Nov 2003
Posts: 5597
Location: Bizarro World

PostPosted: Fri Mar 04, 2005 11:39 pm    Post subject: Reply with quote

I've installed the 1.11 patched base layout and because of the postup feature, I can use dhcpcd still :D

I'm editing the /etc/dhcp/dhcpd.conf file. (dhcp server)

I'm looking to have a client obtain the same IP but still use dhcp.
I see this in the example conf
Code:
host fantasia {
  hardware ethernet 08:00:07:26:c0:a5;
  fixed-address fantasia.fugue.com;
}

I don't see where to set the IP to give the client.

And no I don't want to use a static IP. The router forwards to this machine when it is plugged into this subnet.
This machine is portable and when plugged into another network asks for a dynamic IP. So best to always have it using dhcp, but when plugged into this subnet the dhcp server should recognize it and give it a specific address. (No manual configuration)

Edit: Found it. fixed-address works with IPs too.
Back to top
View user's profile Send private message
seppelrockt
Guru
Guru


Joined: 14 May 2004
Posts: 423

PostPosted: Thu Jun 16, 2005 7:24 am    Post subject: Reply with quote

I have the latest stable x86 baselayout but even if I use modules= ( "dhclient" ) in /etc/conf.d/net it uses dhcpcd - and yes dhcp is emerged (I can run it manually). What's wrong here?

The new baselayout it indead wonderful with the new net and utf-8 features - great work!
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Thu Jun 16, 2005 8:17 am    Post subject: Reply with quote

Does the file /sbin/dhclient exist?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum