This document describes Nx Networks Dynamic Host Configuration Protocol (DHCP) implementation for both the DHCP client and the DHCP server and includes the following sections:
DHCP Overview
Configuring DHCP Client
DHCP Client Commands
Configuring DHCP Server
DHCP Server Commands
DHCP Overview
Dynamic Host Configuration Protocol (DHCP) is an Internet standard for passing configuration information, including Internet Protocol (IP) addresses, to hosts on a Transmission Control Protocol/Internet Protocol (TCP/IP) network. DHCP is an extension of the BOOTstrap Protocol (BOOTP) that adds the capability of automatic allocation of reusable network addresses. When you configure your Nx Networks router to use DHCP, you enable dynamic, centralized management of the IP addresses on your local internet so you no longer need to assign and track IP addresses manually.
The Nx Networks DHCP implementation allows a LAN interface to be either a DHCP client or a DHCP server, but not both simultaneously.
The DHCP client obtains its IP address and subnet mask for a router LAN interface from a DHCP server.
The DHCP server provides IP address, subnet mask, default gateway, DNS, and domain name information to DHCP clients.
Configuring DHCP Client
This section outlines the initial steps required to configure DHCP client on your router. After completing these tasks, restart the router for the new configuration to take effect.
IP Config> prompt enter add address.
IP config> add address
Which net is this address for [0]?
New address [0.0.0.0]?
Allow dynamic address assignment via DHCP(Yes or [No]):yes
Accept default routes from DHCP server(Yes or [No]):
IP> prompt:IP>dhc
DHCP Client>
Press Space after you type a command to display the available options for each command. Enter help for information about using the command line interface.
[M] means the command is available at the DHCP Client> prompt.
| Command | Function |
|---|---|
| Clear [M] | Clears either global counters or the counters on a specified interface. |
| Exit [M] | Returns to the previous prompt level. |
| Interface [M]] | Lists either a summary of information on the router's LAN interfaces configured for dynamic address assignment or detailed information on a specified interface. |
| Release [M] | Releases the IP address lease on the specified interface. |
| Statistics [M] | Lists global statistical information about the DHCP client. |
Clear [M]
Clears either global counters or the counters on a specified interface.
clear
Example:Clearing global counters.
clear 0
Clearing counters for client configured on 0.
exit
Interface [M]
Displays information on all interfaces that you configured to learn their address dynamically or, if you specified the interface number, displays detailed information on the specified interface.
interface
Network Number (CR for summary)?
NetName IP Address Mask ServerId State
Eth/0 128.185.5.2 255.255.255.0 192.168.111.250 Bound
TKR/0 0.0.0.0 0.0.0.0 255.255.255.255 Selecting
Interfaces that are Bound:
NetName IP Address Bound Lease Renewal Rebind BroadcastAddr
Time Time Time Time
Eth/0 128.185.5.2 15 1000 500 875 255.255.255.255
NetName IP Address Mask serverId State
Eth/0 162.6.0.226 255.255.0.0 162.6.0.20 Bound
Destination address: 162.6.0.20
Requested address: 0.0.0.0
Time since bound: 149
Bad packets received: 0
Discover packets sent: 0
Request packets sent: 0
Decline packets sent: 0
Release packets sent: 0Active Lease:
serverId: 162.6.0.20
Packet Type: DhcpOffer
Broadcast Address: 162.6.255.255
Lease Time: 1802
Renewal Time: 901
Rebind Time: 1576Offered Lease(s): None
Release [M]
Releases the lease.
release
Statistics [M]
Displays statistics related to the DHCP and IP forwarding process.
statistics
Number of clients: 1
Number of clients bound: 1
Bad packets received: 0
Buffer allocation failures: 0
Memory allocation failures: 0
Input packet overflows: Net Count
Eth/0 0
Assignable-Range, Subnet Mask, and Default Gateway are automatically set based on the IP address assigned to the interface.
You must configure a numbered IP address on the selected interface.
OpenROUTE software supports a DHCP server only on LAN interfaces.
You configure a DHCP server per interface. If you have more than one LAN interface, you need to provide the interface number when configuring the server.
IP Config> prompt:IP config>dhs
DHCP Server Config>
IP> prompt:IP>dhs
DHCP Server>
Press Space twice after you type a command to display the available options for each command. Enter help for information about using the command line interface.
[C] means the command is available at the DHCP Server config> prompt.
[M] means the command is available at the DHCP Server> prompt.
| Command | Function |
|---|---|
| Add [C] [M] | Adds a fixed IP address assignment or an interface address range. |
| Clear-All [C] | Modifies information that you originally entered with the add and set commands. |
| Delete [C] [M] | Deletes DHCP configuration information that you entered with the add command. |
| Disable [C] [M] | Disables a DHCP interface. |
| Enable [C] [M] | Enables a DHCP interface. |
| Exit [C] [M] | Returns to the previous prompt. |
| Free [C] [M] | Frees up an individual DHCP IP address assignment or all DHCP IP address assignments. (Should rarely be needed.) |
| List [C] [M] | Lists configuration settings for a selected DHCP interface, a range of fixed or dynamic IP addresses, profile options, or non-assignable IP addresses. |
| Revert [M]] | Restores the configuration that is in permanent memory to the run-time configuration.. |
| Save [M] | Saves the current (running) configuration to permanent memory. |
| Set [C] [M] | Sets the configurable DHCP server parameters for the router. |
Changes you make at the Config> prompt do not take effect until you restart the router or enter revert at the DHCP Server> prompt.
Changes you make at the DHCP Server> prompt take effect immediately but do not survive a router restart unless you enter the save command first.
If you add a non-assignable range at the DHCP Server> prompt that includes currently bound addresses, the leases in that range are freed immediately and each client is assigned a new IP address when the original lease expires on the client.
To reset an IP address type parameter back to the automatic value, enter 0.0.0.0.
Interface [0]?
IP Address? 128.185.10.16
MAC Address? 000093B40014
Example: add non-assignable-range 0
First address of range [0.0.0.0] ?128.185.4.10
Last address of range [0.0.0.0] ?128.185.4.15
clear-all
Are you sure you want to delete all DHCP Server configuration (Yes or [No])?
delete fixed-assignment
Interface [0]?
IP Address? 128.185.10.16
delete non-assignable-range
Interface [0]?
First address of range [0.0.0.0] ?128.185.5.10
Last address of range [0.0.0.0] ?128.185.5.15
Syntax: disable interface number
Example:disable
Interface [0]?
Free your run-time in-memory config(Yes or [No]): yes
If you are not changing subnets while disabled, you do not need to free your leases.
If the disable time is longer than the lease time for bound IP addresses, you should free your leases.
This command by itself is sufficient to get the DHCP server going. The server derives default settings from the IP address configuration on the interface. However, the specified interface must have a fixed IP address configured.
Syntax: enable interface number
Example:enable 0
Exit [C] [M]
Returns to the previous prompt.
IP Config>
IP>
Example: free all-dynamic-assignments 0
one-dynamic-assignment interface number
Frees up the lease dynamically assigned to a particular IP address.
Example: free one-dynamic-assignment 0
IP address?128.185.11.17
Example: DHCP Server config>list all
Interface [5]?
Ifc State Assignable-IP-Address-Range
5 enabled *0.0.0.0-0.0.0.0 (*=automatically derived)
Option Profile: (*=automatically derived)
Subnet Mask: *255.255.0.0
Default Gateway: *162.6.0.34
DNS1: 162.6.0.2
DNS2: 0.0.0.0
DNS3: 0.0.0.0
Domain Name: nxnetworks
Lease Time: 360 seconds
Dynamic assignments:
IP Address MAC Address State BoundTime LeaseTime
162.6.0.1 000093B40014 Bound 0 360
DHCP Server>list all
Ifc State ClientsBound ServerId Assignable-IP-Address-Range
0 enabled 2 *162.6.0.2 *162.6.0.1-162.2.255.254
Option Profile (*=automatically derived):
Subnet Mask: *255.255.255.0
Default Gateway: *10.10.1.237
DNS1: 0.0.0.0
DNS2: 0.0.0.0
DNS3: 0.0.0.0
Domain Name: <none>
Lease Time: 14400 seconds
Non-assignable IP address ranges:
0.0.0.0-0.0.0.0
Dynamic assignments:
IP Address MAC Address State BoundTime LeaseTime
10.10.1.1 000093B4003C Bound 4137 14400
10.10.1.2 000093B8A878 Bound 2877 14400
|
State
| The server lease can be in one of the following states: |
dynamic-assignment interface number
Lists any IP address(es) dynamically assigned to the selected interface.
Example: list dynamic-assignment
Interface [5]?
Dynamic assignments:
IP Address MAC Address State BoundTime LeaseTime
162.6.0.1 000093B40014 Bound 0 360
Example: list fixed-assignment
Interface [0]?
Fixed assignments:
IP Address MAC Address State BoundTime LeaseTime
128.185.10.5 000093B40014 Bound 187 300
Example: DHCP Server Config>list interfaces
Ifc State Assignable-IP-Address-Range (*=automatically derived)
0 disabled *0.0.0.0-0.0.0.0
5 enabled *0.0.0.0-0.0.0.0
DHCP Server>list interfaces
Ifc State ClientsBound ServerId Assignable-IP-Address-Range
0 enabled-but interface has no fixed IP address-no run-time config
5 enabled 0 *162.6.0.34 *162.6.0.1 - 162.6.255.254
Example: list non-assignable-range
Interface [5]?
Non-assignable IP address ranges:
128.185.10.10 128.185.10.15
list profile options
Interface [5]?
Option Profile (*=automatically derived):
Subnet Mask: *255.255.0.0
Default Gateway: *162.6.0.34
DNS1: 162.6.0.2
DNS2: 0.0.0.0
DNS3: 0.0.0.0
Domain Name: nxnetworks
Lease Time: 360 seconds
Syntax: revert interface number
Example:revert
Interface [5]?
save
Interface [5]?
In most situations, you do not need to explicitly set this option. The DHCP server automatically sets the assignable-range to the full range of IP addresses of the subnet mask specified on the router's interface on which the server is running.
First address of range [0.0.0.0]? 128.185.19.1
Last address of range [0.0.0.0]? 128.185.19.5
In most situations, you do not need to explicitly set this option. The DHCP server automatically sets the default gateway value to be the same as the IP address on the router's interface on which the server is running.
Example: set default-gateway 0
Default Gateway (0.0.0.0 = automatic default) [0.0.0.0]?
DNS1 (0.0.0.0 = none) [0.0.0.0]? 128.185.7.8
Domain name? boston
lease time [14400]? 3600
In most situations, you do not need to explicitly set this option. The DHCP server automatically defaults the subnet mask value to be the same as the IP subnet mask on the router's LAN interface on which the server is running.
Subnet Mask (0.0.0.0 = automatic default) [0.0.0.0]?