====== DHCP Server - Advanced ====== DHCP stands for Dynamic Host Configuration Protocol and is a protocol for auto-configuration of IP interfaces. Read more: [[troubleshooting:dhcp_server_problems|DHCP server problems]] [[wp>DHCP|DHCP]] ==== Fixed addresses ==== {{ :web_gui:dhcp_server.png?329|DHCP Server in rel 5.30}} Here you can specify which IP addresses the DHCP server should give to certain clients. :!: Usually this is not necessary - the DHCP server chooses addresses by itself from the specified address range. **IP Address** the IP address to be given to the client. Must be within the corresponding port's subnet, but does not need to be within the "From/To" range given to the DHCP server (on the [[network_page#DHCP Server|Network page]]). **MAC address** the unique MAC address of the client to receive the IP address. [[wp>MAC_address|MAC address]] **Known hosts** list of hosts known by this unit. The list can be used to ease configuration by pressing **Add this host**. (After that the IP address can be changed if desired.) Press "Apply" after you are finished. ==== IP address lease time ==== Lease time values for IP addresses given to clients on the LAN. **Normal** If the DHCP client on the LAN doesn't ask for a particular time value, this is the lease time used. **Maximum** If the DHCP client on the LAN asks for longer time than this, this is the lease time used. If a shorter time is requested by the client, it is granted. :!: The DHCP client normally starts refreshing the lease after half the agreed lease time. ==== Add DHCP server options ==== Use this if the DHCP server should send any additional options to the clients (the IP address, default gateway, broadcast address, DNS and domain name are always sent). **Option** Number according to [[http://tools.ietf.org/html/rfc2132|RFC2132]], along with identification (the ISC DHCP server standard names). **Data** The data for the option. Typically an IP address in dot notation, a string or a number, depending on the option. Some options (no. 19,20,27,29,30,31,34,36,39) are flags - write "true" or "false" for these. For arrays of values (e.g. "time-servers") use comma as separator. **Allow DHCP client to set option 43** Uncheck this box if the automatic option 43 setting by the DHCP client is not wanted (see below, under [[dhcp_server#DHCP Client|DHCP Client]]). ==== Vendor class ID (option 60) ==== Listen to any incoming DHCP option 60 string from DHCP clients and act upon that. This is typically used to support different brands of an IPTV set-top box, that needs to get data (option 43) from the remote (ISP's) DHCP server. [[wp>DHCP_option_60|DHCP option 60]] If the **Option 60 pattern** is found in such a string, the following **Actions** will take place depending on the configuration: - The vendor class ID string could be copied (//"Copy vendor class ID"// is selected under DHCP client settings) onto the field in the **DHCP Client** box below. If //"Send this vendor class ID:"// is selected, the string entered in the **Option string** will be written to the **DHCP Client** box instead. - If the Clone MAC address is checked, the MAC address taken from the client (with the matching pattern) on the LAN will be set on the interface selected under the WAN interface (//"All WAN"// should not be selected). The strings in the **Option 60 pattern** and the **Option string** fields could be entered either as readable strings or as comma-separated (decimal) byte values. ==== DHCP Client ==== This setting deals with the DHCP Client and option requests or information sent to the remote DHCP Server. **Vendor class ID (option 60)** Used to pass information about this product type to the remote DHCP server. [[wp>DHCP_option_60|DHCP option 60.]] The data is an array of comma-separated (decimal) byte values. It could be preceeded by an interface name and a colon. Example: "ipwan2:125,3,15,45,57". If this list is specified, an option 43 value (//vendor-encapsulated-options//) will be collected from the remote DHCP server and distributed to the local DHCP clients. The collected option 43 will show up in the [[dhcp_server#Add DHCP server options]] table. **Send hostname in DHCP requests** The host name as entered on the [[Advanced Network Configuration]] page will be sent to the DHCP server as option 12, if this checkbox is checked. ==== DHCP Relay ==== The DHCP relay can forward DHCP requests from a client on the inside network to a remote DHCP server. In practise, global IP addresses will then be given to the local client. To be useful, the DHCP relay would normally be used in conjunction with the setting "//Bridged, WAN -> ET4//" (or ET1) under **Additional IP addresses** on the [[Advanced Network Configuration#Additional IP addresses|Advanced Network Configuration]] page. **DHCP server IP address** The DHCP relay must know the address of the (remote) DHCP server. If not known, use the default setting "//Automatic//". This will make the DHCP client collect the server's IP address - implying that the same server is giving addresses to both the WAN interface (in DHCP mode) and the client on the inside network. ==== IP address lease status ==== **Reset** Makes the DHCP server erase all information about previous leases (what addresses were given to which clients). The server then starts from a default state to provide new addresses. **Save Permanently** Makes the DHCP server save information about leases (what addresses were given to which clients) permanently, to survive restarts. Usually you do not need to do this as the information is saved regularly.