bind
) é a principal autora do servidor DHCP. O pacote Debian correspondente é o isc-dhcp-server.
/etc/dhcp/dhcpd.conf
, and /etc/dhcp/dhcpd6.conf
for IPv6) are the domain name and the DNS servers. If this server is alone on the local network (as defined by the broadcast propagation), the authoritative
directive must also be enabled (or uncommented). One also needs to create a subnet
section describing the local network and the configuration information to be provided. The following example fits a 192.168.0.0/24
local network with a router at 192.168.0.1
serving as the gateway. Available IP addresses are in the range 192.168.0.128
to 192.168.0.254
.
Exemplo 10.15. Trecho do /etc/dhcp/dhcpd.conf
# # Sample configuration file for ISC dhcpd for Debian # # The ddns-updates-style parameter controls whether or not the server will # attempt to do a DNS update when a lease is confirmed. We default to the # behavior of the version 2 packages ('none', since DHCP v2 didn't # have support for DDNS.) ddns-update-style interim; # option definitions common to all supported networks... option domain-name "internal.falcot.com"; option domain-name-servers ns.internal.falcot.com; default-lease-time 600; max-lease-time 7200; # If this DHCP server is the official DHCP server for the local # network, the authoritative directive should be uncommented. authoritative; # Use this to send dhcp log messages to a different log file (you also # have to hack syslog.conf to complete the redirection). log-facility local7; # My subnet subnet 192.168.0.0 netmask 255.255.255.0 { option routers 192.168.0.1; option broadcast-address 192.168.0.255; range 192.168.0.128 192.168.0.254; ddns-domainname "internal.falcot.com"; }
machine-192-168-0-131.internal.falcot.com
). Usar esse recurso requer a configuração do servidor DNS para aceitar atualizações para a zona DNS internal.falcot.com
a partir do servidor DHCP, e configurar esse último para submeter atualizações para cada registro.
bind
, a diretiva allow-update
precisa ser adicionada a cada uma das zonas que o servidor DHCP deve editar (uma para o domínio internal.falcot.com
, e uma para a zona reversa). Essa diretiva lista o endereço IP que tem permissão para realizar essas atualizações; ela deve então conter os possíveis endereços do servidor DHCP (tanto o endereço local quanto o endereço público, se apropriado).
allow-update { 127.0.0.1 192.168.0.1 212.94.201.10 !any };
bind
, e esse último irá sobrescrever seus arquivos de configuração em intervalos regulares. Como esse procedimento automatizado produz arquivos que são menos legíveis por humanos que os escritos manualmente, os administradores da Falcot lidam com o domínio internal.falcot.com
com um servidor DNS delegado; isso significa que o arquivo de zona falcot.com
continua firmemente sob controle manual.
ddns-update-style interim;
and ddns-domain-name "internal.falcot.com";
lines.