[Bug Report] key conflict message for create host by OMAPI
Caciano Machado
caciano at cpd.ufrgs.br
Fri Nov 6 11:44:53 UTC 2015
Hi Steve,
Clodoaldo is talking about ISC DHCP different behaviors when configuring
host statements in configuration files or through OMAPI.
On 11/06/2015 07:33 AM, Steven Carr wrote:
> On 5 November 2015 at 18:37, Clodoaldo de Borba Lambiase
> <clodoaldo at cpd.ufrgs.br> wrote:
>> It is a little different from what people have suggested because I would like to be able to remove and insert 'host' entries by omapi using the ip as unique identifier.
>> Without use the IP as unique identifier I would have to update or remove and reinsert the host entry.
> How will OMAPI be able to know which one of the many host statements
> with the same "name" you want to remove? Did you write a crystal ball
> routine? A unique key is there for a reason.
Yes, you are right. If this case happens OMAPI will not be able to know
which entry to remove. Although, this case never happens in Clodoaldo
environment. Also, the key conflict is because of the MAC address, not
because of the host statement name. That is what is confusing about ISC
DHCP OMAPI behavior. Why this key conflict doesn't happen when you write
the same configuration in conf files instead of using OMAPI, like
Clodoaldo's example?
>
> Updating a single host record to include multiple IP addresses is much
> cleaner and programatically safer.
I can't see how that could be safer. In some environments this approach
will be definitely less safer and less intuitive than creating/removing
individual host statements with only one IP address, because you will
need more code to check the IPs that already are in host statements
before updating them. Also, one IP address per host statement is
consistent with how DHCP configuration files works.
>
> Steve
> _______________________________________________
> dhcp-users mailing list
> dhcp-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/dhcp-users
--
Caciano Machado
Universidade Federal do Rio Grande do Sul
More information about the dhcp-users
mailing list