Frame-relay帧中继配置,实现网络连接
实验要求:帧中继接入网络,实现网路连接。
实验拓扑图:
FR-SW1配置:
Router>enable
Router#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname FR-SW1
FR-SW1(config)#frame-relay switching
FR-SW1(config)#interface s2/0
FR-SW1(config-if)#encapsulation frame-relay ietf
FR-SW1(config-if)#no shutdown
FR-SW1(config-if)#
*Jun 11 02:57:29.322: %LINK-3-UPDOWN: Interface Serial2/0, changed state to up
FR-SW1(config-if)#
*Jun 11 02:57:40.325: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to up
*Jun 11 02:58:10.330: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to down
FR-SW1(config-if)#frame-relay route 102 interface s2/1 201
FR-SW1(config-if)#do sh frame route
Input Intf Input Dlci Output Intf Output Dlci Status
Serial2/0 102 Serial2/1 201 inactive
FR-SW1(config-if)#frame-relay route 103 interface s2/2 301
FR-SW1(config-if)#int e0/0
FR-SW1(config-if)#ip address 172.16.1.1 255.255.255.0
FR-SW1(config-if)#no shutdown
*Jun 11 03:05:22.669: %LINK-3-UPDOWN: Interface Ethernet0/0, changed state to up
*Jun 11 03:05:23.674: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/0, changed state to up
FR-SW1(config-if)#exit
FR-SW1(config)#interface tunnel 0
*Jun 11 03:09:42.938: %LINEPROTO-5-UPDOWN: Line protocol on Interface Tunnel0, changed state to down
FR-SW1(config-if)#tunnel source e0/0
FR-SW1(config-if)#no tunnel source e0/0
FR-SW1(config-if)#tunnel source 172.16.1.1
FR-SW1(config-if)#tunnel destination 172.16.1.2
*Jun 11 03:10:55.675: %LINEPROTO-5-UPDOWN: Line protocol on Interface Tunnel0, changed state to up
FR-SW1(config-if)#exit
FR-SW1(config)#interface s2/0
FR-SW1(config-if)#frame-relay route 104 interface tunnel 0 122
FR-SW1(config-if)#frame-relay intf-type dce
FR-SW1(config-if)#exit
FR-SW1(config)#interface s2/1
FR-SW1(config-if)#encapsulation fra
FR-SW1(config-if)#encapsulation frame-relay ietf
FR-SW1(config-if)#frame-relay intf-type dce
FR-SW1(config-if)#frame-relay route 201 interface s2/0 102
FR-SW2配置:
Router>enable
Router#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname FR-SW2
FR-SW2(config)#interface e0/0
FR-SW2(config-if)#ip address 172.16.1.2 255.255.255.0
FR-SW2(config-if)#no shutdown
FR-SW2(config-if)#exit
FR-SW2(config)#
*Jun 11 03:07:17.466: %LINK-3-UPDOWN: Interface Ethernet0/0, changed state to up
*Jun 11 03:07:18.470: %LINEPROTO-5-UPDOWN: Line protocol on Interface Ethernet0/0, changed state to up
FR-SW2(config)#do ping 172.16.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 172.16.1.1, timeout is 2 seconds:
.!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 1/1/1 ms
FR-SW2(config)#interface tunnel 0
*Jun 11 03:12:47.815: %LINEPROTO-5-UPDOWN: Line protocol on Interface Tunnel0, changed state to down
FR-SW2(config-if)#tunnel source 172.16.1.2
FR-SW2(config-if)#tunnel destination 172.16.1.1
FR-SW2(config-if)#exit
*Jun 11 03:13:08.619: %LINEPROTO-5-UPDOWN: Line protocol on Interface Tunnel0, changed state to up
FR-SW2(config)#frame-relay switching
FR-SW2(config)#interface s2/0
FR-SW2(config-if)#encapsulation frame-relay ietf
FR-SW2(config-if)#frame-relay route 401 interface tunnel 0 122
FR-SW2(config-if)#frame-relay intf-type dce
R1配置:
Router>enable
Router#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname R1
R1(config)#interface s2/0
R1(config-if)#encapsulation frame-relay ietf
R1(config-if)#frame-relay intf-type dte
R1(config-if)#no shutdown
*Jun 11 03:50:39.010: %LINK-3-UPDOWN: Interface Serial2/0, changed state to up
*Jun 11 03:50:50.020: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to up
R1(config)#interface s2/0.10 point-to-point
R1(config-subif)#ip address 10.1.1.1 255.255.255.0
R1(config-subif)#frame-relay interface-dlci 102
R1(config-fr-dlci)#exit
R1(config-subif)#exit
R1(config)#interface s2/0.20 multipoint
R1(config-subif)#ip address 20.1.1.1 255.255.255.0
R1(config-subif)#frame-relay map ip 20.1.1.3 103
R1(config-subif)#frame-relay map ip 20.1.1.4 104
R1(config-subif)#exit
R1(config-if)#exit
R1(config)#router ospf 1
R1(config-router)#router-id 1.1.1.1
R1(config-router)#network 192.168.1.0 0.0.0.255 area 0
R1(config-router)#network 10.1.1.0 0.0.0.255 area 0
R1(config-router)#network 20.1.1.0 0.0.0.255 area 0
R1(config-router)#exit
R1(config)#interface s2/0.10 point-to-point
R1(config-subif)#ip ospf network point-to-point
R1(config-subif)#exit
R1(config)#interface s2/0.20 multipoint
R1(config-subif)#ip ospf network point-to-multipoint
R2配置:
Router>enable
Router#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname R2
R2(config)#interface s2/1
R2(config-if)#encapsulation frame-relay ietf
R2(config-if)#frame-relay intf-type dte
R2(config-if)#ip address 10.1.1.2 255.255.255.0
*Jun 11 03:59:32.579: %LINK-3-UPDOWN: Interface Serial2/1, changed state to up
R2(config-if)#
*Jun 11 03:59:43.586: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/1, changed state to up
*Jun 11 04:00:13.591: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/1, changed state to down
R2(config-if)#frame-relay map ip 10.1.1.1 201 broadcast
R2(config-if)exit
R2(config)#router ospf 1
R2(config-router)#router-id 2.2.2.2
R2(config-router)#network 192.168.2.0 0.0.0.255 area 0
R2(config-router)#network 10.1.1.0 0.0.0.255 area 0
R2(config-router)#exit
R2(config)#interface s2/1
R2(config-if)#ip os
R2(config-if)#ip ospf net
R2(config-if)#ip ospf network po
R2(config-if)#ip ospf network point-to-p
R2(config-if)#ip ospf network point-to-point
R3配置
R3>enable
R3#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
R3(config)#hostname R3
R3(config)#interface s2/2
R3(config-if)#encapsulation frame-relay ietf
R3(config-if)#frame-relay intf-type dte
R3(config-if)#ip address 20.1.1.3 255.255.255.0
R3(config-if)#no shutdown
*Jun 11 04:17:29.215: %LINK-3-UPDOWN: Interface Serial2/2, changed state to up
*Jun 11 04:17:40.219: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/2, changed state to up
*Jun 11 04:18:10.223: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/2, changed state to down
R3(config-if)#frame-relay map ip 20.1.1.1 301 broadcast
R3(config-if)#exit
R3(config)#router ospf 1
R3(config-router)#router-id 3.3.3.3
R3(config-router)#network 192.168.3.0 0.0.0.255 area 0
R3(config-router)#network 20.1.1.0 0.0.0.255 area 0
R3(config-router)#exit
R3(config)#int s2/2
R3(config-if)#ip ospf network point-to-multipoint
R4配置
Router>enable
Router#configure
Configuring from terminal, memory, or network [terminal]?
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname R4
R4(config)#interface s2/0
R4(config-if)#encapsulation frame-relay ietf
R4(config-if)#frame-relay intf-type dte
R4(config-if)#ip address 20.1.1.4 255.255.255.0
R4(config-if)#no shutdown
R4(config-if)#
*Jun 11 04:22:02.944: %LINK-3-UPDOWN: Interface Serial2/0, changed state to up
*Jun 11 04:22:13.953: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to up
R4(config-if)#frame-relay map ip 20.1.1.1 401
*Jun 11 04:22:43.959: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial2/0, changed state to down
R4(config-if)#exit
R4(config)#router ospf 1
R4(config-router)#router-id 4.4.4.4
R4(config-router)#network 20.1.1.0 0.0.0.255 area 0
R4(config-router)#network 192.168.4.0 0.0.0.255 area 0
R4(config-router)#exit
R4(config)#int s2/0
R4(config-if)#ip ospf network point-to-multipoint