CISCO basic CDP

Source: Internet
Author: User

CDP

1.On the first router (Router1), enter the terminal configuration mode.

-Cl ick Here to View Answer-Router> enableRouter # conf tRouter (config )#

2.In Router1, change the nameR1

-Click Here to View Answer-Router (config) # hostname R1R1 (config )#

3.Modify the name of another router (Router4)R4

-Click Here to View Answer-Router> enableRouter # conf tRouter (config) # hostname R4R4 (config )#

Note: by default, all ports are in the shutdown status (that is, disabled)

4.Enable port Serial 0 on R1

-Click Here to View Answer-R1 (config) # interface Serial 0R1 (config-if) # no shutdown

5.Now port Serial 0 is enabled on R4

-Click Here to View Answer-R4 (config) # interface Serial 0R4 (config-if) # no shutdown

6. Good boy, obedient, good boy. Now enable Ethernet port 0 on R1 ~

-Click Here to View Answer-R1 (config) # interface Ethernet 0R1 (config-if) # no shutdown

CDP allows devices to share basic configuration information. CDP can act without configuring any specific protocol information, and is enabled on all ports by default. It also works on Layer 2 in the OSI reference model, that is, the data link layer protocol, which is very important for understanding CDP, because it is a non-routing protocol, it can only slide back and forth in the direct connection device.

7.On R1, enter the following command to display the status of all ports running CDP.

-Click Here to View Answer-R1 (config-if) # exitR1 (config) # exitR1 # show cdp interface

The following example shows that two ports have been up and CDP data packets are sent.


Serial0 is up, line protocol is up
Encapsulation HDLC
Sending CDP packets every 60 seconds
Holdtime is 180 seconds
<Output omitted>
R1 #

Now, the vro port is being broadcast and receives CDP updates, so we can use CDP to find our directly connected neighbors.

Note: neighbors are used to fight ~

8.Enter related commands on R1 to display information about neighbors.

-Click Here to View Answer-R1 # show cdp neighbors

The output is as follows:

Capability Codes: R-Router, T-Trans Bridge, B-Source Route Bridge
S-Switch, H-Host, I-IGMP, r-Repeater

Device ID Local Interface Holdtme Capability Platform Port ID
R4 Serial 0 148 R 1700 Serial 0
R1 #

[1] [2] [3] Next page

Article entry: csh responsible editor: csh

The first device listed on R1 is R4 connected through Searial0. R1 is receiving updates from R4, which tell R1 the total time of the holttime. This command shows that the update of R1 is still more than 148 seconds. If the update is not received at the expiration time, the record will be removed from the table of R1. The Platform parameter is displayed as 1700. It can be determined that R4 is a 1000 series router, and the last column is PortID, which is the sending port of the updated source device.

9.On R1, enter the following command to display more information about the directly connected neighbor.

-Click Here to View Answer-R1 # show cdp neighbors detail

Shown as follows:

Device ID: R4
Entry address (es ):
Platform: cisco 1000, Capabilities: Router
Interface: Serial0, Port ID (outgoing port): Serial0
Holdtime: 162 sec

Version:
Cisco Internetwork Operating System Software
Software, Version 12.0 (16), release software (fc2)
Copyright (c) 1986-2001 by cisco Systems, Inc.
Compiled Fri 02-Mar-01 :34 by dchih

Depend! You can call the version together. This command only displays one device at a time ~.

10.Enter a command on R1 to display the information of R4.

-Click Here to View Answer-R1 # show cdp entry R4

Shown below

Device ID: R4
Entry address (es ):
Platform: cisco 1000, Capabilities: Router
Interface: Serial0, Port ID (outgoing port): Serial0
Holdtime: 148 sec

Version:
Cisco Internetwork Operating System Software
Software, Version 12.0 (16), release software (fc2)
Copyright (c) 1986-2001 by cisco Systems, Inc.
Compiled Fri 02-Mar-01 :34 by dchih

R1 #

This command displays the same content as Show cdp neighbor, but it can be used to specify a specific device for display. In addition, it is a case-sensitive command.

11.On R1, enter the following command to display the update frequency sent by CDP and the Time Life of the received update holdtime.

-Click Here to View Answer-R1 # show cdp

Shown below

Global CDP information:
Sending CDP packets every 60 seconds
Sending a holdtime value of 180 seconds
Sending CDPv2 advertisements is enabled

12.Set the update interval to 45 seconds on R1.

-Click Here to View Answer-R1 # conf tR1 (config) # cdp timer 45

In addition to the update interval, the value of holdtime can also be adjusted.

Previous Page [1] [2] [3] Next page

Article entry: csh responsible editor: csh

13.Continue to trash R1 and set its holdtime value to 60

-Click Here to View Answer-R1 # conf tR1 (config) # cdp holdtime 60

14.Okay. Now let's take a look at the performance.

-Click Here to View Answer-R1 # show cdp

Shown as follows:

R1 # sh cdp
Global CDP information:
Sending CDP packets every 45 seconds
Sending a holdtime value of 60 seconds
Sending CDPv2 advertisements is enabled
R1 #

If no other device in the network is directly connected to a CISCO device, or you want to retain the bandwidth, CDP can be banned for "Internet thinking "~.

15.Do you want to discard it? Come on baby ~~~ Follow me!

-Click Here to View Answer-R1 # conf tR1 (config) # no cdp run

16.Are we so cruel? Jesus said to Buddha, "you do not go to hell. Who is going to hell. Now let's release CDP ~

-Click Here to View Answer-R1 # conf tR1 (config) # cdp run

In fact, sometimes we have reason not to let it finish playing on some ports. For example, if the family is poor, the bandwidth is low enough to squeeze out small and strong, or security factors.

17.Now on R1, remember that it performs CDP removal on Ethernet port 0.

-Click Here to View Answer-R1 (config) # interface Ethernet 0R1 (config-if) # no cdp enable

18.After the operation, you need to check whether the update is successful. Enter the command to check whether the update is no longer sent.

-Click Here to View Answer-R1 # show cdp interface

Shown below

R1 # show cdp interface
Serial0 is up, line protocol is up
Encapsulation HDLC
Sending CDP packets every 45 seconds
Holdtime is 60 seconds

Previous Page [1] [2] [3]

Article entry: csh responsible editor: csh

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.