试验34 PPP



R1配置
r1(config)#int s1/2
r1(config-if)#ip add 10.1.1.1 255.255.255.0
r1(config-if)#no sh

R2配置
r2(config)#int s2/1
r2(config-if)#ip add 10.1.1.2 255.255.255.0
r2(config-if)#no sh

查看接口默认封装格式

r1#sh int s1/2
Serial1/2 is up, line protocol is up
Hardware is M4T
Internet address is 10.1.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, rely 255/255, load 1/255
Encapsulation HDLC, crc 16, loopback not set, keepalive set (10 sec)
Last input 00:00:02, output 00:00:01, output hang never
Last clearing of “show interface” counters never
Input queue: 0/75/0 (size/max/drops); Total output drops: 0
Queueing strategy: weighted fair
Output queue: 0/1000/64/0 (size/max total/threshold/drops)
Conversations  0/1/256 (active/max active/max total)
Reserved Conversations 0/0 (allocated/max allocated)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
8 packets input, 983 bytes, 0 no buffer
Received 7 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
8 packets output, 945 bytes, 0 underruns
0 output errors, 0 collisions, 2 interface resets
0 output buffer failures, 0 output buffers swapped out
3 carrier transitions     DCD=up  DSR=up  DTR=up  RTS=up  CTS=up

默认的格式为HDLC
修改封装格式为PPP

r1(config)#int s1/2
r1(config-if)#en
r1(config-if)#encapsulation ppp
r1#sh int s1/2
Serial1/2 is up, line protocol is up
Hardware is M4T
Internet address is 10.1.1.1/24
MTU 1500 bytes, BW 1544 Kbit, DLY 20000 usec, rely 255/255, load 1/255
Encapsulation PPP, crc 16, loopback not set, keepalive set (10 sec)
LCP Open
Open: IPCP, CDPCP
Last input 00:00:06, output 00:00:06, output hang never
Last clearing of “show interface” counters never
Input queue: 0/75/0 (size/max/drops); Total output drops: 0
Queueing strategy: weighted fair
Output queue: 0/1000/64/0 (size/max total/threshold/drops)
Conversations  0/1/256 (active/max active/max total)
Reserved Conversations 0/0 (allocated/max allocated)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
79 packets input, 3737 bytes, 0 no buffer
Received 17 broadcasts, 0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
91 packets output, 3976 bytes, 0 underruns
0 output errors, 0 collisions, 4 interface resets
0 output buffer failures, 0 output buffers swapped out
5 carrier transitions     DCD=up  DSR=up  DTR=up  RTS=up  CTS=up

此时的已经成了PPP了
调试PPP

r1#debug ppp packet
PPP packet display debugging is on
r1#
00:10:14: Se1/2 PPP: O pkt type 0×0207, datagramsize 275
00:10:19: Se1/2 PPP: I pkt type 0xC021, datagramsize 16
00:10:19: Se1/2 LCP: I ECHOREQ [Open] id 30 len 12 magic 0×0004DB3D
00:10:19: Se1/2 LCP: O ECHOREP [Open] id 30 len 12 magic 0×0004FFAA
00:10:20: Se1/2 LCP: O ECHOREQ [Open] id 30 len 12 magic 0×0004FFAA
00:10:20: Se1/2 PPP: I pkt type 0xC021, datagramsize 16
00:10:20: Se1/2 LCP: I ECHOREP [Open] id 30 len 12 magic 0×0004DB3D
00:10:20: Se1/2 LCP: Received id 30, sent id 30, line up
00:10:29: Se1/2 PPP: I pkt type 0xC021, datagramsize 16
00:10:29: Se1/2 LCP: I ECHOREQ [Open] id 31 len 12 magic 0×0004DB3D
00:10:29: Se1/2 LCP: O ECHOREP [Open] id 31 len 12 magic 0×0004FFAA
00:10:30: Se1/2 LCP: O ECHOREQ [Open] id 31 len 12 magic 0×0004FFAA
00:10:30: Se1/2 PPP: I pkt type 0xC021, datagramsize 16
00:10:30: Se1/2 LCP: I ECHOREP [Open] id 31 len 12 magic 0×0004DB3D
00:10:30: Se1/2 LCP: Received id 31, sent id 31, line up

你可能感兴趣的:(职场,休闲,ppp)