Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation

Configuring a DHCP Server on Switches (CLI Procedure)

A Dynamic Host Configuration Protocol (DHCP) server can provide two valuable TCP/IP network services. DHCP can dynamically allocate IP parameters, such as an IP address, to clients and it can also deliver software upgrades to clients.

DHCP configuration consists of two components, optional reconfiguration of default settings on DHCP clients and configuration of a DHCP server. This topic covers configuration of the DHCP server. For directions for reconfiguring a DHCP client, see Configuring a DHCP Client (CLI Procedure).

You can configure either of two versions of a DHCP server on a switch—either the extended server version or the legacy server version. We recommend that you use the extended server configuration unless you need to keep your DHCP server configuration backward-compatible with the legacy server version.

This topic includes the following tasks:

  1. Configuring an Extended DHCP Server on a Switch
  2. Configuring a Legacy DHCP Server on a Switch (CLI Procedure)

Configuring an Extended DHCP Server on a Switch

To configure an extended DHCP server, you must configure a DHCP pool, indicate IP addresses for the pool, and create a server group. Additional configurations are optional.

Do not assign addresses that are already in use in the network to address pools. The extended DHCP server does not check whether addresses are already in use before assigning them to clients.

  1. Create an address pool for DHCP IP addresses:
    [edit]user@switch# set access address-pool address-pool
  2. Configure addresses for DHCP dynamic assignment:
    [edit access address-assignment]user@switch# set pool address-pool-name
  3. Create a server group on the switch, providing a group name and an interface for DHCP:
    [edit system services dhcp-local-server]user@switch# set group group-name interface interface-name
  4. Optionally, process the information protocol data units (PDUs):
    [edit system services dhcp-local-server]user@switch# set overrides process-inform
  5. Optionally, redefine the order of attribute matching for pool selection:
    [edit system services dhcp-local-server]user@switch# set pool-match-order ip-address-first
  6. Optionally, enable dynamic reconfiguration triggered by the DHCP extended server of all DHCP clients or only the DHCP clients serviced by the specified group of interfaces:
    [edit system services dhcp-local-server]user@switch# set reconfigure
    [edit system services dhcp-local-server group group-name]user@switch# set reconfigure

Configuring a Legacy DHCP Server on a Switch (CLI Procedure)

To configure a legacy DHCP server, you must configure a pool of IP addresses for dynamic assignment. You only need to supply a series of network addresses. Additional configurations are optional.

  1. Configure a pool of IP addresses for dynamic assignment:
    [edit system services dhcp]user@switch# set pool (Legacy DHCP) network-range

    Note: Step 2 through step 15 assign global values at the [edit system services dhcp] hierarchy level. You can also assign the same values to a specific pool using those same commands at the [edit system services dhcp pool network-range] hierarchy level.

  2. Optionally, change the domain search list used to resolve hostnames:
    [edit system services dhcp]user@switch# set domain-search [ domain-list ]
  3. Optionally, change the domain name server (DNS) name that the DHCP server advertises to clients:
    [edit system services dhcp]user@switch# set name-server address
  4. Optionally, change the DHCP options:
    [edit system services dhcp]user@switch# set option id-number
  5. Optionally, change the devices advertised to clients:
    [edit system services dhcp]user@switch# set router address
  6. Optionally, change the SIP server:
    [edit system services dhcp]user@switch# set sip-server addresses-or-names

    For more information, see Configuring a DHCP SIP Server (CLI Procedure).

  7. Optionally, change the DHCP client’s hardware address:
    [edit system services dhcp]user@switch# set static-binding mac-address
  8. Optionally, change the NetBIOs name server:
    [edit system services dhcp]user@switch# set wins-server address

Published: 2013-08-15