Re: dhcpd and static entries
Peter Hessler wrote: > I have a dhcp'd network, with static entries for a ton of machines. > The problem is that the range is for .10 - .254, and the static entries > are scattered throughout. When a random client requests an address, > dhcpd will give out a staticly defined entry. So when the static entry > machine comes back, the two machines fight each other for the address. Hi Peter As has been said, this is not a correct configuration, and dhcpd will complain (at least does on freebsd). To mitigate the problem you might want to set a short max-lease-time for the whole range and a unlimited one for each host with a fixed-address (e.g. one week or more). So the lease of the static address should remain bound until the client comes back. Next step, of course, should be to sort out that network. If it's not possible to move the fixed-address clients out, maybe you could move the dynamic-address clients to the upper half and then split the network. Or assign them to a totally new network segment. Or enlarge the segment to 10.0.0.0/22 and serve dynamic addresses from the upper 3 segments only. Or ... In the end you will be wanting a pool and a group definition. hth /m
Re: dhcpd and static entries
On 12. des. 2005, at 21.22, Peter Hessler wrote: This is with -current dhcpd within the last month. On Mon, 12 Dec 2005 12:15:37 -0800 Peter Hessler <[EMAIL PROTECTED]> wrote: : I have a dhcp'd network, with static entries for a ton of machines. : The problem is that the range is for .10 - .254, and the static : entries are scattered throughout. When a random client requests an : address, dhcpd will give out a staticly defined entry. So when the : static entry machine comes back, the two machines fight each other : for the address. : : Moving the static entries to outside the range is unfeasable right : now. And it doesn't address the issue of 'machine was on a different : dhcp network with an address that happens to be staticly defined on : ours'. : : Why does dhcpd give out addresses that are currently in use, and why : does it give out staticly defined addresses? Shouldn't it remove the : static entries from the dynamic pool? : : : Sanitized portions of config: : : shared-network LOCAL-NET { : option domain-name "example.com"; : option domain-name-servers 10.0.0.1; : : option nis-domain "example.nis"; : option nis-servers nis.example.com; : option ntp-servers ntp.example.com; : option time-offset -28800; # PST : : subnet 10.0.0.0 netmask 255.255.255.0 { : option routers 10.0.0.1; : : range 10.0.0.10 10.0.0.254; : } : : group { : use-host-decl-names on; : # host1.example.com 10.0.0.15 :host host1.example.com { hardware ethernet \ : 00:0f:1f:f7:7d:64; fixed-address host1.example.com; } : # host2.example.com 10.0.0.20 : host host2.example.com { hardware ethernet \ : 02:A0:98:01:F5:B4; fixed-address host2.example.com; } : # host3.example.com 10.0.0.29 : host host3.example.com { hardware ethernet \ : 00:0F:1F:F7:78:B6; fixed- address host3.example.com; } :} : } : I believe OpenBSD's dhcpd is based on ISC's implementation, in which case: static entries are in the global scope and independent of any pool declaration. The error is one of configuration: you've defined static entries and dynamic pool overlapping = you've told it to use the IP addresses twice. At a pinch, the option ping-check, might help you out if your address space utilisation is not too large. /Pete
Re: dhcpd and static entries
On 12/12/05, Peter Hessler <[EMAIL PROTECTED]> wrote: > > On Mon, 12 Dec 2005 13:59:23 -0700 > Abraham Al-Saleh <[EMAIL PROTECTED]> wrote: > > : On 12/12/05, Peter Hessler <[EMAIL PROTECTED]> wrote: > : > : > : > : Moving the static entries to outside the range is unfeasable right > : > : now. And it doesn't address the issue of 'machine was on a > : > : different dhcp network with an address that happens to be > : > : staticly defined on ours'. > : > : > : > : Why does dhcpd give out addresses that are currently in use, and > : > : why does it give out staticly defined addresses? Shouldn't it > : > : remove the static entries from the dynamic pool? > : > : > : Because you're static ips are within your dynamic pool, just setup > : the static addresses so they're outside the dynamic range. Your > : server is misconfigured otherwise. > > > So its a feature, not a bug? Note the paragraph before the one you > addressed, it says "can't happen". > > Would adding such a feature (maybe off by default, but configurable in > command line/conf file) be accepted? I don't know, but it sounds pretty useless to me, your issue is a misconfiguration. If you can't fix the misconfiguration, then it's a policy problem, and you get to hold the peices.
Re: dhcpd and static entries
On Mon, 12 Dec 2005 13:59:23 -0700 Abraham Al-Saleh <[EMAIL PROTECTED]> wrote: : On 12/12/05, Peter Hessler <[EMAIL PROTECTED]> wrote: : > : : > : Moving the static entries to outside the range is unfeasable right : > : now. And it doesn't address the issue of 'machine was on a : > : different dhcp network with an address that happens to be : > : staticly defined on ours'. : > : : > : Why does dhcpd give out addresses that are currently in use, and : > : why does it give out staticly defined addresses? Shouldn't it : > : remove the static entries from the dynamic pool? : : : Because you're static ips are within your dynamic pool, just setup : the static addresses so they're outside the dynamic range. Your : server is misconfigured otherwise. So its a feature, not a bug? Note the paragraph before the one you addressed, it says "can't happen". Would adding such a feature (maybe off by default, but configurable in command line/conf file) be accepted? -- "Here at the Phone Company, we serve all kinds of people; from Presidents and Kings to the scum of the earth ..."
Re: dhcpd and static entries
On 12/12/05, Peter Hessler <[EMAIL PROTECTED]> wrote: > > This is with -current dhcpd within the last month. > > On Mon, 12 Dec 2005 12:15:37 -0800 > Peter Hessler <[EMAIL PROTECTED]> wrote: > > : I have a dhcp'd network, with static entries for a ton of machines. > : The problem is that the range is for .10 - .254, and the static > : entries are scattered throughout. When a random client requests an > : address, dhcpd will give out a staticly defined entry. So when the > : static entry machine comes back, the two machines fight each other > : for the address. > : > : Moving the static entries to outside the range is unfeasable right > : now. And it doesn't address the issue of 'machine was on a different > : dhcp network with an address that happens to be staticly defined on > : ours'. > : > : Why does dhcpd give out addresses that are currently in use, and why > : does it give out staticly defined addresses? Shouldn't it remove the > : static entries from the dynamic pool? Because you're static ips are within your dynamic pool, just setup the static addresses so they're outside the dynamic range. Your server is misconfigured otherwise. : > : Sanitized portions of config: > : > : shared-network LOCAL-NET { > : option domain-name "example.com"; > : option domain-name-servers 10.0.0.1; > : > : option nis-domain "example.nis"; > : option nis-servers nis.example.com; > : option ntp-servers ntp.example.com; > : option time-offset -28800; # PST > : > : subnet 10.0.0.0 netmask 255.255.255.0 { > : option routers 10.0.0.1; > : > : range 10.0.0.10 10.0.0.254; > : } > : > : group { > : use-host-decl-names on; > : # host1.example.com 10.0.0.15 > :host host1.example.com { hardware ethernet \ > : 00:0f:1f:f7:7d:64; fixed-address host1.example.com; } > : # host2.example.com 10.0.0.20 > : host host2.example.com { hardware ethernet \ > : 02:A0:98:01:F5:B4; fixed-address host2.example.com; } > : # host3.example.com 10.0.0.29 > : host host3.example.com { hardware ethernet \ > : 00:0F:1F:F7:78:B6; fixed- address host3.example.com; } > :} > : } > : > : > : > : -- > : Workers of the world, arise! You have nothing to lose but your > : chairs. > : > > > -- > Sex without love is an empty experience, but, as empty experiences go, > it's one of the best. > -- Woody Allen > > -- Abe Al-Saleh I love deadlines. I like the whooshing sound they make as they fly by. --Douglas Adams
Re: dhcpd and static entries
This is with -current dhcpd within the last month. On Mon, 12 Dec 2005 12:15:37 -0800 Peter Hessler <[EMAIL PROTECTED]> wrote: : I have a dhcp'd network, with static entries for a ton of machines. : The problem is that the range is for .10 - .254, and the static : entries are scattered throughout. When a random client requests an : address, dhcpd will give out a staticly defined entry. So when the : static entry machine comes back, the two machines fight each other : for the address. : : Moving the static entries to outside the range is unfeasable right : now. And it doesn't address the issue of 'machine was on a different : dhcp network with an address that happens to be staticly defined on : ours'. : : Why does dhcpd give out addresses that are currently in use, and why : does it give out staticly defined addresses? Shouldn't it remove the : static entries from the dynamic pool? : : : Sanitized portions of config: : : shared-network LOCAL-NET { : option domain-name "example.com"; : option domain-name-servers 10.0.0.1; : : option nis-domain "example.nis"; : option nis-servers nis.example.com; : option ntp-servers ntp.example.com; : option time-offset -28800; # PST : : subnet 10.0.0.0 netmask 255.255.255.0 { : option routers 10.0.0.1; : : range 10.0.0.10 10.0.0.254; : } : : group { : use-host-decl-names on; : # host1.example.com 10.0.0.15 :host host1.example.com { hardware ethernet \ : 00:0f:1f:f7:7d:64; fixed-address host1.example.com; } : # host2.example.com 10.0.0.20 : host host2.example.com { hardware ethernet \ : 02:A0:98:01:F5:B4; fixed-address host2.example.com; } : # host3.example.com 10.0.0.29 : host host3.example.com { hardware ethernet \ : 00:0F:1F:F7:78:B6; fixed- address host3.example.com; } :} : } : : : : -- : Workers of the world, arise! You have nothing to lose but your : chairs. : -- Sex without love is an empty experience, but, as empty experiences go, it's one of the best. -- Woody Allen
dhcpd and static entries
I have a dhcp'd network, with static entries for a ton of machines. The problem is that the range is for .10 - .254, and the static entries are scattered throughout. When a random client requests an address, dhcpd will give out a staticly defined entry. So when the static entry machine comes back, the two machines fight each other for the address. Moving the static entries to outside the range is unfeasable right now. And it doesn't address the issue of 'machine was on a different dhcp network with an address that happens to be staticly defined on ours'. Why does dhcpd give out addresses that are currently in use, and why does it give out staticly defined addresses? Shouldn't it remove the static entries from the dynamic pool? Sanitized portions of config: shared-network LOCAL-NET { option domain-name "example.com"; option domain-name-servers 10.0.0.1; option nis-domain "example.nis"; option nis-servers nis.example.com; option ntp-servers ntp.example.com; option time-offset -28800; # PST subnet 10.0.0.0 netmask 255.255.255.0 { option routers 10.0.0.1; range 10.0.0.10 10.0.0.254; } group { use-host-decl-names on; # host1.example.com 10.0.0.15 host host1.example.com { hardware ethernet \ 00:0f:1f:f7:7d:64; fixed-address host1.example.com; } # host2.example.com 10.0.0.20 host host2.example.com { hardware ethernet \ 02:A0:98:01:F5:B4; fixed-address host2.example.com; } # host3.example.com 10.0.0.29 host host3.example.com { hardware ethernet \ 00:0F:1F:F7:78:B6; fixed- address host3.example.com; } } } -- Workers of the world, arise! You have nothing to lose but your chairs.