#Dynamic DNS security settings key DHCP_TSIG_KEY_NAME { algorithm DHCP_TSIG_KEY_ALGO; secret "DHCP_TSIG_KEY_SECRET"; }; zone DHCP_DYN_IPS_DOMAIN { primary DHCP_DNS_MASTER; key DHCP_TSIG_KEY_NAME; } zone DHCP_SITE_DOMAIN { primary DHCP_DNS_MASTER; key DHCP_TSIG_KEY_NAME; } zone DHCP_REV_DOMAIN { primary DHCP_DNS_MASTER; key DHCP_TSIG_KEY_NAME; } # Custom routes classes option classless-routes code 121 = array of unsigned integer 8; option classless-routes-win code 249 = array of unsigned integer 8; # Leases settings default-lease-time 600; max-lease-time 7200; # Dynamic DNS update ddns-updates on; ddns-update-style interim; update-static-leases on; #allow client-updates; ddns-rev-domainname "in-addr.arpa."; # Misc settings use-host-decl-names on; authoritative; log-facility local7; subnet DHCP_SUBNET netmask DHCP_NETMASK { # Dynamic DNS update ddns-domainname "DHCP_DYN_IPS_DOMAIN"; update-conflict-detection false; # IP settings range DHCP_IP_FIRST DHCP_IP_LAST; option subnet-mask DHCP_NETMASK; option broadcast-address DHCP_BROADCAST; option routers DHCP_ROUTERS; # DNS settings option domain-name "DHCP_SITE_DOMAIN"; option domain-search "DHCP_SITE_DOMAIN", "DHCP_DOMAIN"; option domain-name-servers DHCP_DNS_SERVER; # Push custom routes to clients #option classless-routes 24, 10,15,42, 10.15.12,2; #option classless-routes-win 24, 10,15,42, 10.15.12,2; # Netboot settings next-server DHCP_TFTP_SERVER; #option root-path "10.15.100.1:/pxeroot/ubuntu"; if exists user-class and ( option user-class = "iPXE-rthoni" ) { option domain-search "DHCP_SITE_DOMAIN"; filename "http://netboot/boot.ipxe"; } else { filename "ipxe-rthoni.kpxe"; } # Static IP hosts group { host vm-pxe { hardware ethernet 08:00:27:7b:9d:21; fixed-address 10.15.100.10; } host vm-windows { hardware ethernet 08:00:27:76:ce:95; fixed-address 10.15.100.11; } ddns-domainname "DHCP_SITE_DOMAIN"; option host-name = host-decl-name; ddns-hostname = config-option host-name; } # Force a default hostname if not present if option dhcp-message-type = 3 and not exists host-name and config-option host-name = null { option host-name = concat("dyn-", binary-to-ascii(10, 8, "-", leased-address)); ddns-hostname = config-option host-name; } }