By Sheldon L | Published at 2020-05-14 | Updated at 2020-05-14 |
Corp# config t
Corp(config)# int s0/0/0
Corp(config-if)# encapsulation ?
atm-dxi ATM-DXI encapsulation
frame-relay Frame Relay networks
hdlc Serial HDLC synchronous
lapb LAPB (X.25 Level 2)
ppp Point-to-Point protocol
smds Switched Megabit Data Service (SMDS)
x25 X.25
data terminal equipment (DTE)
, and they connect into data communication equipment (DCE)
like a channel service unit/data service unit (CSU/DSU)
using a V.35 connector
.CSU/DSU
then plugs into a demarcation location (demarc)
and is the service provider’s last responsibility. Most of the time, the demarc is a jack that has an RJ45 (8-pin modular) female connector located in a telecommunications closet.DCE
device (CSU/DSU
) provides clocking to the DTE-connected interface
.clock rate
command.show controllers int
commandCorp# sh controllers s0/0/0
Interface Serial0/0/0
Hardware is PowerQUICC MPC860
DCE V.35, clock rate 2000000
SF# sh controllers s0/0/0
Interface Serial0/0/0
Hardware is PowerQUICC MPC860
DTE V.35 TX and RX clocks detected
The High-Level Data-Link Control (HDLC) protocol is a popular ISO-standard, bit-oriented, Data Link layer protocol. It specifies an encapsulation method for data on synchronous serial data links using frame characters and checksums.
HDLC is a point-to-point protocol used on leased lines. No authentication is provided by HDLC.
Bit-oriented protocols use single bits to represent the control information. Some common bit-oriented protocols are SDLC and HDLC. TCP and IP are byte-oriented protocols.
Cisco’s HDLC is proprietary, meaning it won’t communicate with any other vendor’s HDLC implementation. Indeed, everyone’s HDLC implementation is proprietary. If you have only one Cisco router and you need to connect to a non-Cisco router, you couldn’t use the default HDLC serial encapsulation. Instead, you would need to go with an option like PPP, an ISO-standard way of identifying the upper-layer protocols.
Cisco HDLC: Flag-Address-Control-Proprietary-Data-FCS-Flag
HDLC is the default encapsulation used by Cisco routers over synchronous serial links.
Corp(config)# int s0/0
Corp(config-if)# ip address 172.16.10.1 255.255.255.252
Corp(config-if)# no shut
Corp# sh int s0/0
Serial0/0 is up, line protocol is up
Hardware is PowerQUICC Serial
Internet address is 172.16.10.1/30
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation HDLC , loopback not set
Keepalive set (10 sec)
Corp# sh run | begin interface Serial0/0
interface Serial0/0
ip address 172.16.10.1 255.255.255.252
! If you don’t see an encapsulation type listed under a serial interface
! in the active configuration file, you know
! it’s running the default encapsulation of HDLC.
Point-to-Point Protocol (PPP)
is a Data Link layer protocol that can be used over either asynchronous serial (dial-up)
or synchronous serial (ISDN)
media.
It relies on Link Control Protocol (LCP)
to build and maintain data-link connections. Network Control Protocol (NCP)
enables multiple Network layer protocols (routed protocols)
to be used on a point-to-point connection.
The basic purpose of PPP is to transport layer 3 packets across a Data Link layer point-to-point link, and it’s nonproprietary. And it provide authentication, dynamic addressing, and callback. PPP could actually be the best encapsulation solution for you over HDLC anyway.
PPP contains four main components:
OSI layer
Upper-layer protocols
(such as IP and IPv6)
---------------------------------------------------
3 Network Control Protocol (NCP)
(specific to each Network layer protocol)
----------------------------------------------------
Link Control Protocol (LCP)
2
High-Level Data Link Control (HDLC)
---------------------------------------------------
1 Physical layer
(such as EIA/TIA-232, V.24, V.35, ISDN)
! PPP
Router# config t
Router(config)# int s0
Router(config-if)# encapsulation ppp
Router(config-if)# ^Z
! PPP Authentication: set username and password for the remote
Router# config t
Router(config)# hostname RouterA
! Username is hostname of the remote router
RouterA(config)# username RouterB password cisco
! password is plain text in running-config, need encryption.
RouterA# service password-encryption
! PPP Authentication: CHAP, PAP
RouterA# config t
RouterA(config)# int s0
RouterA(config-if)# ppp authentication chap pap
RouterA(config-if)# ^Z
RouterA#
! An other way to set PAP user and password
RouterA# config t
RouterA(config)# int s0
RouterA(config-if)# ppp pap sent-username <username> password <password>
!
RouterB# config t
RouterB(config)# int s0
RouterB(config-if)# ppp pap sent-username <username> password <password>
hostname | Pod1R1 | Pod1R2 |
---|---|---|
username/password | Pod1R2/cisco | Pod1R1/cisco |
interface | serial 0 | serial 0 |
ip address | 10.0.1.1 255.255.255.0 | 10.0.1.2 255.255.255.0 |
encapsulation | ppp | ppp |
clock rate | 64000 | DTE |
bandwidth | 512 | 512 |
ppp authentication | chap | chap |
! If successec
Pod1R1# sh int s0/0
Serial0/0 is up, line protocol is up**
Hardware is PowerQUICC Serial
Internet address is 10.0.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec,
reliability 239/255, txload 1/255, rxload 1/255
Encapsulation PPP**
loopback not set
Keepalive set (10 sec)
LCP Open**
Open: IPCP, CDPCP**
[output cut]
! If failed
Pod1R1# sh int s0/0
Serial0/0 is up, line protocol is down**
Hardware is PowerQUICC Serial
Internet address is 10.0.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec,
reliability 243/255, txload 1/255, rxload 1/255
Encapsulation PPP, loopback not set**
Keepalive set (10 sec)
LCP Closed**
Closed: IPCP, CDPCP*
! Debuging
Pod1R1# debug ppp authentication
! if the username and passwords aren’t configured exactly
! Mismatched WAN Encapsulations
Pod1R1# sh int s0/0
Serial0/0 is up, line protocol is down
Hardware is PowerQUICC Serial
Internet address is 10.0.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec,
reliability 254/255, txload 1/255, rxload 1/255
Encapsulation PPP , loopback not set
Keepalive set (10 sec)
LCP REQsent**
Closed: IPCP, CDPCP
! Because router Pod1R2 is using the HDLC encapsulation
!
! Set a Cisco serial interface back to the default of HDLC
Router(config)# int s0/0
Router(config-if)# no encapsulation
! Mismatched IP Addresses
Pod1R1# sh int s0/0
Serial0/0 is up, line protocol is up
Hardware is PowerQUICC Serial
Internet address is 10.0.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation PPP, loopback not set**
Keepalive set (10 sec)
LCP Open
Open: IPCP, CDPCP
!
Pod1R1# show ip route
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.2.1.2/32 is directly connected, Serial0/0**
C 10.0.1.0/24 is directly connected, Serial0/0
! OR show running-config, interfaces, ip interfaces brief in each other
! OR:
Pod1R1# sh cdp neighbors detail
! Notice that each serial connection is on a different subnet
Corp# show interfaces Serial0/0
Serial0/0 is up, line protocol is up
Hardware is M4T
Internet address is 172.16.10.1/30
MTU 1500 bytes, BW 1544 Kbit/sec, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation PPP, LCP Open
Open: IPCP, CDPCP, crc 16, loopback not set
!
Corp# show interfaces Serial1/1
Serial1/1 is up, line protocol is up
Hardware is M4T
Internet address is 172.16.10.9/30
MTU 1500 bytes, BW 1544 Kbit/sec, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation PPP, LCP Open
Open: IPCP, CDPCP, crc 16, loopback not set
! First remove your IP addresses off your physical interface
Corp# config t
Corp(config)# int Serial0/0
Corp(config-if)# no ip address
Corp(config-if)# int Serial1/1
Corp(config-if)# no ip address
Corp(config-if)# end
Corp#
SF# config t
SF(config)# int Serial0/0
SF(config-if)# no ip address
SF(config-if)# int Serial0/1
SF(config-if)# no ip address
SF(config-if)# end
SF#
! Create a multilink interface on both sides.
! Assign an IP address to this multilink interface.
! Add the MLP commands to enable the bundle.
Corp# config t
Corp(config)# interface Multilink1
Corp(config-if)# ip address 10.1.1.1 255.255.255.0
Corp(config-if)# ppp multilink
Corp(config-if)# ppp multilink group 1
Corp(config-if)# end
SF# config t
SF(config)# interface Multilink1
SF(config-if)# ip address 10.1.1.2 255.255.255.0
SF(config-if)# ppp multilink
SF(config-if)# ppp multilink group 1
SF(config-if)# exit
! that link won’t be allowed to join any other bundle group
! Verifying MLP
Corp# show ppp multilink
Corp# show int Multilink1
Used with ADSL (asymmetrical digital subscriber line) services, PPPoE (Point-to-Point Protocol over Ethernet) encapsulates PPP frames in Ethernet frames and uses common PPP features like authentication, encryption, and compression. But it can be trouble, which is especially true if you’ve got a badly configured firewall!
PPPoE is a tunneling protocol that layers IP and other protocols running over. PPP with the attributes of a PPP link.
Your ISP will typically provide you with a DSL (digital subscriber line) line and this will act as a bridge if your line doesn’t provided enhanced features. This means only one host will connect using PPPoE.
By using a Cisco router, you can run the PPPoE client IOS feature on the Cisco router, which will connect multiple PCs on the Ethernet segment that is connected to the router.
! Create a dialer interface
R1(config)# int dialer1
! Instruct the client to use an IP address provided by
! the PPPoE server with the ip address negotiated command.
R1(config-if)# ip address negotiated
! Set the encapsulation type to PPP.
R1(config-if)# encapsulation ppp
! Configure the dialer pool and number.
R1(config-if)# dialer pool 1
! Set PPPoE-client to dial pool
R1(config-if)# interface f0/1
R1(config-if)# no ip address
R1(config-if)# pppoe-client dial-pool-number 1
! verify the interface
R1# show ip int brief
R1# show pppoe session