Multi-party research on CISCO router dhcp configuration (1)

Source: Internet
Author: User

In terms of routers, I believe everyone knows CISCO. Do you know about its DHCP server configuration? Here we will introduce in detail the dhcp configuration of the CISCO router. Configure the vrodhcp as a dhcp server to allocate IP addresses to the customer workstation connected to the vro 。

Solving instances

The following CISCO router dhcp configuration command can be used to configure a vrodhcp as a DHCP server to dynamically assign IP addresses to the DHCP client 。

 
 
  1. Router1 # configure terminal
  2. Enter configuration commands, one per line. End with CNTL/Z.
  3. Router1 (config) # service dhcp // enable DHCP service
  4. Router1 (config) # ip dhcp pool 172.25.1.0/24 // define the DHCP address pool
  5. Router1 (dhcp-config) # network 172.25.1.0 255.255.255.0 // use the network command to define the network address range
  6. Router1 (dhcp-config) # default-router 172.25.1.1 // defines the gateway address to be allocated
  7. Router1 (dhcp-config) # exit
  8. Router1 (config) # ip dhcp excluded-address 172.25.1.1 172.25.1.50 // ip addresses in this range cannot be allocated to clients
  9. Router1 (config) # ip dhcp excluded-address 172.25.1.200 172.25.1.255 // ip addresses in this range cannot be allocated to clients
  10. Router1 (config) # end
  11. Router1 #

Discussion on dhcp configuration of CISCO Routers

1 The CISCO router dhcp server function is also in ios 12.0 (1) T. this feature makes it unnecessary for us to configure another DHCP server in the center of a dedicated network (or enterprise headquarters), thus reducing network construction costs 。

2. configuring a dhcp server directly on a vro has its unique advantages over traditional dedicated servers 。
For example

A. Because the traditional construction method is to set up a dhcp server in the enterprise's headquarters, the branches can obtain the IP address through A router. Therefore, when the dhcp server encounters A problem, the entire enterprise's network will be affected. If the dhcp server function is configured on the routers of each branch, the DHCP server of a branch may be faulty, only the network of the branch can be affected, and other branches can be seen without any impact, thus realizing the localization of the problem 。

After B implements the DHCP server function on the routers of branches, a large number of DHCP UDP request packets will not be forwarded to the central organization through the wan link. Therefore, compared with the traditional method, it has the advantage of reducing Wan load 。

C. after implementing the DHCP server function on the routers of different branches, if a wide area network connection fails, the local LAN can still run normally.

D. vrodhcp-based DHCP has high manageability. It is easy to configure through the ios command interface 。

3. In the preceding configuration example, we use the ip dhcp exclude-address command to specify ip addresses that cannot be allocated. This configuration is often required (or even required, almost all of them; because some addresses are often used for other purposes, for example, we should at least keep the addresses of the routers themselves not allocated to the DHCP client, there are also some network servers, printers, and so on, and we often designate static addresses for them, so this part of the address. We do not allow the routes to be allocated. In the above example, the routes are between 172.25.1.1 and 172.25.1.50, the address between 172.25.1.200 and 172.25.1.255 is retained 。

4. After the vro dynamically assigns an address to the client, it binds the IP address assigned by the binding and the mac address of the client device, and stores the information in the vro configuration, so that the dhcp service can obtain the same IP address for the next request with the same mac address. The following example shows, use the show ip dhcp binding command to display the ip binding information. Lease expiration indicates the ip address, and the client can take up some time. (Of course, the client can send a dhcp request again before it expires, in fact, the dhcp specification also stipulates that dhcp requests will be issued when the lease period is about half the time. If the lease period fails to be updated, half the time will be saved, he also sends dhcp requests, and so on 。)

 
 
  1. Router1#show ip dhcp binding  
  2. IP address Hardware address Lease expiration Type  
  3. 172.25.1.51 0100.0103.85e9.87 Apr 10 2003 08:55 PM Automatic  
  4. 172.25.1.52 0100.50da.2a5e.a2 Apr 10 2003 09:00 PM Automatic  
  5. 172.25.1.53 0100.0103.ea1b.ed Apr 10 2003 08:58 PM Automatic  
  6. Router1# 


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.