From ArchWiki

dhcpd is the older Internet Systems Consortium (ISC) DHCP server. Be aware that dhcpd is no longer maintained as of January 2023; ISC promotes Kea as its official replacement.

Note: dhcpd (DHCP server daemon) is not the same as dhcpcd (DHCP client daemon).


Install the dhcp package.


dhcpd includes two unit files, dhcpd4.service and dhcpd6.service, which can be used to control the daemon. They start the daemon on all network interfaces for IPv4 and IPv6 respectively. See #Listening on only one interface for an alternative.


Assign a static IPv4 address to the interface you want dhcpd to listen on (here eth0). The specified subnet should not overlap with that of other interfaces.

# ip link set up dev eth0
# ip addr add dev eth0 # arbitrary address
Tip: To have a static IP address assigned at boot, see Network configuration#Static IP address.
Tip: The following subnets are usually reserved for private networks and will not conflict with hosts on the internet:
  • 192.168/16 (subnet, netmask
  • 172.16/12 (subnet, netmask
  • 10/8 (for large networks; subnet, netmask
See also RFC 1918.

The default configuration file dhcpd.conf contains many uncommented examples, so relocate it:

# cp /etc/dhcpd.conf /etc/dhcpd.conf.example

To only listen on the subnet, you may create the following minimal configuration file:

option domain-name-servers,;
option subnet-mask;
option routers;
subnet netmask {

The options used in this configuration file are:

domain-name-servers which contains addresses of DNS servers supplied to the clients. Here we use Google's public DNS servers. If you have configured your own DNS server on a local machine, specify its address in your subnet (here

subnet-mask and routers which define a subnet mask and a list of available routers on the subnet; routers also defines the default gateway served to the client. For small networks, you can usually use as a mask and specify an IP address of the machine on which you are running dhcpd (here

subnet which defines options for separate subnets that are applied to the network interfaces on which dhcpd is listening. Here we have defined the range of available IP addresses for a single subnet (on a single interface eth0).

For a complete list of options, consult dhcpd.conf(5).

Listening on only one interface

This article or section is out of date.

Reason: While the man page dhcpd(8) suggests the behavior described below, in practice dhcpd only listens on interfaces with subnets declared in its configuration file. (Discuss in Talk:Dhcpd)

If your computer is already part of one or several networks, it could be a problem if your computer starts giving ip addresses to machines from the other networks. It can be done by either configuring dhcpd or starting it as a daemon with systemctl.

Configuring dhcpd

The factual accuracy of this article or section is disputed.

Reason: dhcpd does not listen on interfaces whose subnets are not declared in its configuration file. (Discuss in Talk:Dhcpd)

In order to exclude an interface, you must create an empty declaration for the subnet that will be configured on that interface.

This is done by editing the configuration file (for example):

# No DHCP service in DMZ network (
subnet netmask {

Service file

The factual accuracy of this article or section is disputed.

Reason: Does not work with systemd 251. (Discuss in Talk:Dhcpd)

The default service file provided by dhcpd does not specify an interface. Use a drop-in unit file for the dhcpd4.service as follows:

ExecStart=/usr/bin/dhcpd -4 -q -cf /etc/dhcpd.conf -pf /run/dhcpd4/dhcpd.pid %I

This allows using dhcpd4.service as a template unit, binding dhcpd to a particular interface; for example dhcpd4@eth0.service, where eth0 is the first enumerated Ethernet device.

Use for PXE

PXE Configuration is done with the following two options:

filename "/pxelinux.0";

This section can either be in an entire subnet or just in a host definition. next-server is the IP of the TFTP Server, and filename is the filename of the image to boot. For more information see PXE.

See also