dhcpd.conf : dynamic ddns-domainname option

David W. Hankins David_Hankins at isc.org
Fri Jul 28 15:47:44 UTC 2006


On Fri, Jul 28, 2006 at 04:27:23PM +0200, Clément Jeanne wrote:
> I get the fqdn from option 81 like machineA.subdomain4.domain6 
> 
> I want to extract subdomain4.domain6 to put it in ddns-domainname (ddns-domainname=suffix (???))
> and by the way machineA in ddns-hostname

This is dhcpd's default configuration for these values:

option server.ddns-hostname =                                               \n\
  pick (option fqdn.hostname, option host-name);                            \n\
option server.ddns-domainname = config-option domain-name;                  \n\
option server.ddns-ttl = encode-int(lease-time / 2, 32);                    \n\
option server.ddns-rev-domainname = \"in-addr.arpa.\";";

So, logically, to get the behaviour you just described, you would
configure the following in dhcpd.conf (over-riding the above):

	option server.ddns-hostname = option fqdn.hostname;
	option server.ddns-domainname = option fqdn.domainname;

-- 
David W. Hankins	"If you don't do it right the first time,
Software Engineer		you'll just have to do it again."
Internet Systems Consortium, Inc.	-- Jack T. Hankins


More information about the dhcp-users mailing list