DEV Community

esmeralda
esmeralda

Posted on

Configuring HDLC on a Cisco router

Hello!

How are you doing?

The objective of this post is to practice how to configure HDLC on the network using Cisco routers.

You can better understand this configuration if you already know WAN (Wide Area Network) and point-to-point protocols (PPP), for instance.

Cisco defines HDLC (High-level Data Link Control) as a group of data link (Layer 2) protocols used to transmit synchronous data packets between point-to-point nodes.

HDLC is a bit-oriented protocol that helps to transmit data reliably and efficiently. However, companies prefer PPP over Cisco HDLC for many reasons, including that the latter is Cisco proprietary and creates limitations when working with non-cisco devices. Also, even though today there are other methods to transmit data more securely, HDLC is still used and certifications such as CCNA request that you have some knowledge.

Today, we will configure HDLC in a simple network with 2 routers.

Let’s go!

Image description

1- Assign IP addresses to the router serial interfaces and turn them on with the command <no shut>.

Router 1:
R1#conf t
R1(config)#int serial 2/0
R1(config-if)#ip address 10.1.1.1 255.255.255.0
R1(config-if)#no shut

Router 2:
R2#conf t
R2(config)#int serial 2/0
R2(config-if)#ip address 10.1.1.2 255.255.255.0
R2(config-if)#no shut

2- Check if both routers can ping each other.

Image description

Image description

Yes, they can ping each other.

3- If you run the command show int serial 2/0, you will see that HDLC is enabled by default on the interface on Cisco routers, therefore, it is not needed to add any additional command.

Image description

However, if you find issues on your network and while troubleshooting you find that one serial interface is using HDLC encapsulation and the other interface is running PPP, you can enable HDLC manually. You can do that in interface config mode with the command .

Example:

Router#conf t
Router(config)#int serial 2/0
Router(config-if)#encapsulation hdlc

4- Running <sh run> we can see that a clock rate is already assigned. We only need to enable the clock rate when we are using a back-to-back cable, and it is enabled on the DCE (Data Communication Equipment) side.

Router 1:

Image description

Router 2:

Image description

That was simple, wasn’t it?

Thank you for reading!

Top comments (0)