Documentation du Dr FRAPPE

Ce wiki regroupe les résultats de mes expériences en informatique accumulés au cours de mes recherches sur le net.

Dans la mesure du possible, j'ai cité mes sources ; il en manque certainement… :-)

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
Prochaine révisionLes deux révisions suivantes
logiciel:internet:dnsmasq:dnsmasq.conf [2020/11/05 22:58] – [Options] adminlogiciel:internet:dnsmasq:dnsmasq.conf [2020/11/06 10:43] – [Options] admin
Ligne 315: Ligne 315:
     ? tftp-no-blocksize     ? tftp-no-blocksize
     : This option stops dnsmasq from negotiating a larger blocksize for TFTP transfers. It will slow things down, but may rescue some broken TFTP clients.     : This option stops dnsmasq from negotiating a larger blocksize for TFTP transfers. It will slow things down, but may rescue some broken TFTP clients.
- +  ? dhcp-boot 
-Set the boot file name only when the "red" tag is set. +  : 
-#dhcp-boot=tag:red,pxelinux.red-net +    ? dhcp-boot=tag:red,pxelinux.red-net 
- +    : Set the boot file name only when the "red" tag is set. 
-An example of dhcp-boot with an external TFTP server: the name and IP +    ? dhcp-boot=/var/ftpd/pxelinux.0,boothost,192.168.0.3 
-address of the server are given after the filename. +    : An example of dhcp-boot with an external TFTP server: the name and IP address of the server are given after the filename. 
-Can fail with old PXE ROMS. Overridden by --pxe-service. +    : Can fail with old PXE ROMS. Overridden by --pxe-service. 
-#dhcp-boot=/var/ftpd/pxelinux.0,boothost,192.168.0.3 +    ? dhcp-boot=/var/ftpd/pxelinux.0,boothost,tftp_server_name 
- +    : If there are multiple external tftp servers having a same name (using /etc/hosts) then that name can be specified as the tftp_servername (the third option to dhcp-boot) and in that case dnsmasq resolves this name and returns the resultant IP addresses in round robin fashion. This facility can be used to load balance the tftp load among a set of servers. 
-If there are multiple external tftp servers having a same name +  ? dhcp-lease 
-(using /etc/hosts) then that name can be specified as the +  :  
-tftp_servername (the third option to dhcp-boot) and in that +    ? dhcp-lease-max=150 
-case dnsmasq resolves this name and returns the resultant IP +    : Set the limit on DHCP leases, the default is 150 
-addresses in round robin fashion. This facility can be used to +    ? dhcp-leasefile=/var/lib/misc/dnsmasq.leases 
-load balance the tftp load among a set of servers. +    : The DHCP server needs somewhere on disk to keep its lease database. 
-#dhcp-boot=/var/ftpd/pxelinux.0,boothost,tftp_server_name +    : This defaults to a sane location, but if you want to change it, use the line below. 
- +  ? dhcp-authoritative 
-Set the limit on DHCP leases, the default is 150 +  : Set the DHCP server to authoritative mode. In this mode it will barge in and take over the lease for any client which broadcasts on the network, whether it has a record of the lease or not. This avoids long timeouts when a machine wakes up on a new network. DO NOT enable this if there's the slightest chance that you might end up accidentally configuring a DHCP server for your campus/company accidentally. The ISC server uses the same option, and this URL provides more information: http://www.isc.org/files/auth.html 
-#dhcp-lease-max=150 +  ? dhcp-rapid-commit 
- +  : Set the DHCP server to enable DHCPv4 Rapid Commit Option per RFC 4039. 
-The DHCP server needs somewhere on disk to keep its lease database. +  : In this mode it will respond to a DHCPDISCOVER message including a Rapid Commit option with a DHCPACK including a Rapid Commit option and fully committed address and configuration information. This must only be enabled if either the server is the only server for the subnet, or multiple servers are present and they each commit a binding for all clients. 
-This defaults to a sane location, but if you want to change it, use +  ? dhcp-script=/bin/echo 
-the line below. +  : Run an executable when a DHCP lease is created or destroyed. 
-#dhcp-leasefile=/var/lib/misc/dnsmasq.leases +  : The arguments sent to the script are "add" or "del", then the MAC address, the IP address and finally the hostname if there is one. 
- +  ? cache-size=150 
-Set the DHCP server to authoritative mode. In this mode it will barge in +  : Set the cachesize here. 
-and take over the lease for any client which broadcasts on the network, +  ? no-negcache 
-whether it has a record of the lease or not. This avoids long timeouts +  : If you want to disable negative caching, uncomment this. 
-when a machine wakes up on a new network. DO NOT enable this if there's +  ? local-ttl= 
-the slightest chance that you might end up accidentally configuring a DHCP +   Normally responses which come from /etc/hosts and the DHCP lease file have Time-To-Live set as zero, which conventionally means do not cache further. If you are happy to trade lower load on the server for potentially stale date, you can set a time-to-live (in seconds) here. 
-server for your campus/company accidentally. The ISC server uses +  ? bogus-nxdomain=64.94.110.11 
-the same option, and this URL provides more information: +  : If you want dnsmasq to detect attempts by Verisign to send queries to unregistered .com and .net hosts to its sitefinder service and have dnsmasq instead return the correct NXDOMAIN response, uncomment this line. You can add similar lines to do the same for other registries which have implemented wildcard A records. 
-http://www.isc.org/files/auth.html +  ? alias 
-#dhcp-authoritative +  : If you want to fix up DNS results from upstream servers, use the alias option. This only works for IPv4. 
- +    ? alias=1.2.3.4,5.6.7.8 
-Set the DHCP server to enable DHCPv4 Rapid Commit Option per RFC 4039. +    : This alias makes a result of 1.2.3.4 appear as 5.6.7.8 
-In this mode it will respond to a DHCPDISCOVER message including a Rapid Commit +    ? alias=1.2.3.0,5.6.7.0,255.255.255.0 
-option with a DHCPACK including a Rapid Commit option and fully committed address +    : and this maps 1.2.3.x to 5.6.7.x 
-and configuration information. This must only be enabled if either the server is  +    ? alias=192.168.0.10-192.168.0.40,10.0.0.0,255.255.255.0 
-the only server for the subnet, or multiple servers are present and they each +    : and this maps 192.168.0.10->192.168.0.40 to 10.0.0.10->10.0.0.40 
-commit a binding for all clients. +  ? MX records 
-#dhcp-rapid-commit +  : Change these lines if you want dnsmasq to serve MX records. 
- +    ? mx-host=maildomain.com,servermachine.com,50 
-Run an executable when a DHCP lease is created or destroyed. +    : Return an MX record named "maildomain.com" with target servermachine.com and preference 50 
-The arguments sent to the script are "add" or "del", +    ? mx-target=servermachine.com 
-then the MAC address, the IP address and finally the hostname +    : Set the default target for MX records created using the localmx option. 
-if there is one. +    ? localmx 
-#dhcp-script=/bin/echo +    : Return an MX record pointing to the mx-target for all local machines. 
- +    ? selfmx 
-Set the cachesize here. +    : Return an MX record pointing to itself for all local machines. 
-#cache-size=150 +  ? srv-host 
- +  : Change the following lines if you want dnsmasq to serve SRV records. These are useful if you want to serve ldap requests for Active Directory and other windows-originated DNS requests. 
-If you want to disable negative caching, uncomment this. +  : See RFC 2782. 
-#no-negcache +  : You may add multiple srv-host lines. 
- +  : The fields are <name>,<target>,<port>,<priority>,<weight> 
-Normally responses which come from /etc/hosts and the DHCP lease +  : If the domain part if missing from the name (so that is just has the service and protocol sections) then the domain given by the domain= config option is used. (Note that expand-hosts does not need to be set for this to work.) 
-file have Time-To-Live set as zero, which conventionally means +    ? srv-host=_ldap._tcp.example.com,ldapserver.example.com,389 
-do not cache further. If you are happy to trade lower load on the +    : A SRV record sending LDAP for the example.com domain to ldapserver.example.com port 389 
-server for potentially stale date, you can set a time-to-live (in +    ? domain=example.com\\ srv-host=_ldap._tcp,ldapserver.example.com,389 
-seconds) here. +    : A SRV record sending LDAP for the example.com domain to ldapserver.example.com port 389 (using domain=) 
-#local-ttl+    ? srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,1\\ srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,
- +    : Two SRV records for LDAP, each with different priorities 
-If you want dnsmasq to detect attempts by Verisign to send queries +    ? srv-host=_ldap._tcp.example.com 
-to unregistered .com and .net hosts to its sitefinder service and +    : A SRV record indicating that there is no LDAP server for the domain example.com 
-have dnsmasq instead return the correct NXDOMAIN response, uncomment +  ? ptr-record=_http._tcp.dns-sd-services,"New Employee Page._http._tcp.dns-sd-services" 
-this line. You can add similar lines to do the same for other +  : The following line shows how to make dnsmasq serve an arbitrary PTR record. This is useful for DNS-SD. (Note that the domain-name expansion done for SRV records _does_not occur for PTR records.) 
-registries which have implemented wildcard A records. +  ? txt-record 
-#bogus-nxdomain=64.94.110.11 +  : Change the following lines to enable dnsmasq to serve TXT records. 
- +  : These are used for things like SPF and zeroconf. (Note that the domain-name expansion done for SRV records _does_not occur for TXT records.) 
-If you want to fix up DNS results from upstream servers, use the +    ? txt-record=example.com,"v=spf1 a -all" 
-alias option. This only works for IPv4. +    : Example SPF. 
-This alias makes a result of 1.2.3.4 appear as 5.6.7.8 +    ? txt-record=_http._tcp.example.com,name=value,paper=A4 
-#alias=1.2.3.4,5.6.7.8 +    : Example zeroconf 
-and this maps 1.2.3.x to 5.6.7.x +  ? cname=bertand,bert 
-#alias=1.2.3.0,5.6.7.0,255.255.255.0 +  : Provide an alias for a "local" DNS name. Note that this _only_ works for targets which are names from DHCP or /etc/hosts. Give host "bert" another name, bertrand 
-and this maps 192.168.0.10->192.168.0.40 to 10.0.0.10->10.0.0.40 +  ? log-queries 
-#alias=192.168.0.10-192.168.0.40,10.0.0.0,255.255.255.0 +  : For debugging purposes, log each DNS query as it passes through dnsmasq. 
- +  ? log-dhcp 
-Change these lines if you want dnsmasq to serve MX records. +  : Log lots of extra information about DHCP transactions. 
- +  ? conf-file=/etc/dnsmasq.more.conf 
-Return an MX record named "maildomain.com" with target +  ? conf-dir=/etc/dnsmasq.d 
-servermachine.com and preference 50 +  : Include another lot of configuration options.
-#mx-host=maildomain.com,servermachine.com,50 +
- +
-Set the default target for MX records created using the localmx option. +
-#mx-target=servermachine.com +
- +
-Return an MX record pointing to the mx-target for all local +
-machines. +
-#localmx +
- +
-Return an MX record pointing to itself for all local machines. +
-#selfmx +
- +
-Change the following lines if you want dnsmasq to serve SRV +
-records.  These are useful if you want to serve ldap requests for +
-Active Directory and other windows-originated DNS requests. +
-See RFC 2782. +
-You may add multiple srv-host lines. +
-The fields are <name>,<target>,<port>,<priority>,<weight> +
-If the domain part if missing from the name (so that is just has the +
-service and protocol sections) then the domain given by the domain= +
-config option is used. (Note that expand-hosts does not need to be +
-set for this to work.) +
- +
-A SRV record sending LDAP for the example.com domain to +
-ldapserver.example.com port 389 +
-#srv-host=_ldap._tcp.example.com,ldapserver.example.com,389 +
- +
-A SRV record sending LDAP for the example.com domain to +
-ldapserver.example.com port 389 (using domain=) +
-#domain=example.com +
-#srv-host=_ldap._tcp,ldapserver.example.com,389 +
- +
-# Two SRV records for LDAPeach with different priorities +
-#srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,1 +
-#srv-host=_ldap._tcp.example.com,ldapserver.example.com,389,2 +
- +
-A SRV record indicating that there is no LDAP server for the domain +
-example.com +
-#srv-host=_ldap._tcp.example.com +
- +
-The following line shows how to make dnsmasq serve an arbitrary PTR +
-record. This is useful for DNS-SD. (Note that the +
-domain-name expansion done for SRV records _does_not +
-occur for PTR records.) +
-#ptr-record=_http._tcp.dns-sd-services,"New Employee Page._http._tcp.dns-sd-services" +
- +
-Change the following lines to enable dnsmasq to serve TXT records. +
-These are used for things like SPF and zeroconf. (Note that the +
-domain-name expansion done for SRV records _does_not +
-occur for TXT records.) +
- +
-#Example SPF. +
-#txt-record=example.com,"v=spf1 a -all" +
- +
-#Example zeroconf +
-#txt-record=_http._tcp.example.com,name=value,paper=A4 +
- +
-Provide an alias for a "local" DNS name. Note that this _only_ works +
-for targets which are names from DHCP or /etc/hosts. Give host +
-"bert" another name, bertrand +
-#cname=bertand,bert +
- +
-For debugging purposes, log each DNS query as it passes through +
-dnsmasq. +
-#log-queries +
- +
-Log lots of extra information about DHCP transactions. +
-#log-dhcp +
- +
-# Include another lot of configuration options. +
-#conf-file=/etc/dnsmasq.more.conf +
-#conf-dir=/etc/dnsmasq.d+
  
 # Include all the files in a directory except those ending in .bak # Include all the files in a directory except those ending in .bak