Redistribute giữa RIP Ver2,OSPF và EIGRP I. Mô hình
II. Mục tiêu của bài lab
Đặt địa chỉ IP cho các interface trên các Router R1, R2,R3 và R4. Cấu hình định tuyến RIPv2, EIGRP, OSPF. Redistribute giữa các giao thức theo mô hình để các router này có thể liên lạc được với nhau.
1. Cấu hình khởi tạo cho các thiết bị mạng, cấu hình các interface của router.
- Đặt tên thiết bị.
- Cấu hình banner motd
- Cấu hình password cho console, telnet, Privileged, enable password, mã hóa mật khẩu file cấu hình.
- Cấu hình địa chỉ IP
- Cấu hình description
- Cấu hình enable các interface
2. Ping qua lại giữa các interface được kết nối trực tiếp với nhau.
3. Thiết lập giao thức định tuyến trên các router như mô hình trên.
4. Redistribute giữa các giao thức.
5. Xem bảng định tuyến (routing table).
6. Kiểm tra các router có thể ping qua lại lẫn nhau.
III. Cấu hình chi tiết
1. Cấu hình khởi tạo cho các thiết bị mạng, cấu hình các interface của router.
*Cấu hình trên R1
- Cấu hình đặt tên thiết bị
- Cấu hình Banner motdRouter>enable
Router#configure terminal
Router(config)#hostname R1
R1(config)#
- Cấu hình consoleR1(config)#banner motd "BACHKHOA-NPOWER"
- Cấu hình telnetR1(config)#line console 0
R1(config-line)#password cisco
R1(config-line)#loggin synchronous
R1(config-line)#exit
- Cấu hình password privilegedR1(config)#line vty 0 4
R1(config-line)#password cisco
R1(config-line)#login
R1(config-line)#exit
- Cấu hình enable passwordR1(config)#enable secret bachkhoa-npower
- Cấu hình mã hóa mật khẩu trong file cấu hìnhR1(config)#enable password cisco123
- Cấu hình các interface của routeR1(config)#service password-encryption
*Cấu hình trên R2R1(config)#interface serial 0/1
R1(config-if)#ip address 192.168.2.1 255.255.255.0
R1(config-if)#description "R1 Connection to R2"
R1(config-if)#no shut
R1(config-if)#clock rate 64000
R1(config-if)#exit
R1(config)#interface loopback 0
R1(config-if)#ip address 192.168.1.1 255.255.255.0
R1(config-if)#end
- Cấu hình đặt tên thiết bị
- Cấu hình Banner motdRouter>enable
Router#configure terminal
Router(config)#hostname R2
R2(config)#
- Cấu hình consoleR2(config)#banner motd "BACHKHOA-NPOWER"
- Cấu hình telnetR2(config)#line console 0
R2(config-line)#password cisco
R2(config-line)#loggin synchronous
R2(config-line)#exit
- Cấu hình password privilegedR2(config)#line vty 0 4
R2(config-line)#password cisco
R2(config-line)#login
R2(config-line)#exit
- Cấu hình enable passwordR2(config)#enable secret bachkhoa-npower
- Cấu hình mã hóa mật khẩu trong file cấu hìnhR2(config)#enable password cisco123
- Cấu hình các interface của routeR2(config)#service password-encryption
*Cấu hình trên R3R2(config)#interface serial 0/0
R2(config-if)#ip address 192.168.2.2 255.255.255.0
R2(config-if)#description "R2 Connection to R1"
R2(config-if)#no shut
R2(config-if)#exit
R2(config)#interface serial 0/1
R2(config-if)#ip address 192.168.3.1 255.255.255.0
R2(config-if)#description "R2 Connection to R3"
R2(config-if)#no shut
R2(config-if)#clock rate 64000
R2(config-if)#end
- Cấu hình đặt tên thiết bị
- Cấu hình Banner motdRouter>enable
Router#configure terminal
Router(config)#hostname R3
R3(config)#
- Cấu hình consoleR3(config)#banner motd "BACHKHOA-NPOWER"
- Cấu hình telnetR3(config)#line console 0
R3(config-line)#password cisco
R3(config-line)#loggin synchronous
R3(config-line)#exit
- Cấu hình password privilegedR3(config)#line vty 0 4
R3(config-line)#password cisco
R3(config-line)#login
R3(config-line)#exit
- Cấu hình enable passwordR3(config)#enable secret bachkhoa-npower
- Cấu hình mã hóa mật khẩu trong file cấu hìnhR3(config)#enable password cisco123
- Cấu hình các interface của routeR3(config)#service password-encryption
*Cấu hình trên R4R3(config)#interface serial 0/0
R3(config-if)#ip address 192.168.3.2 255.255.255.0
R3(config-if)#description "R3 Connection to R2"
R3(config-if)#no shut
R3(config-if)#exit
R3(config)#interface serial 0/1
R3(config-if)#ip address 192.168.4.1 255.255.255.0
R3(config-if)#description "R3 Connection to R4"
R3(config-if)#no shut
R3(config-if)# clock rate 64000
R3(config-if)#end
R3#
- Cấu hình đặt tên thiết bị
- Cấu hình Banner motdRouter>enable
Router#configure terminal
Router(config)#hostname R4
R4(config)#
- Cấu hình consoleR4(config)#banner motd "BACHKHOA-NPOWER"
- Cấu hình telnetR4(config)#line console 0
R4(config-line)#password cisco
R4(config-line)#loggin synchronous
R4 (config-line)#exit
- Cấu hình password privilegedR4(config)#line vty 0 4
R4(config-line)#password cisco
R4(config-line)#login
R4(config-line)#exit
- Cấu hình enable passwordR4(config)#enable secret bachkhoa-npower
- Cấu hình mã hóa mật khẩu trong file cấu hìnhR4(config)#enable password cisco123
- Cấu hình các interface của routeR4(config)#service password-encryption
2. Ping qua lại giữa các interface được kết nối trực tiếp với nhau.R4(config)#interface serial 0
R4(config-if)#ip address 192.168.4.2 255.255.255.0
R4(config-if)#description "R4 Connection to R3"
R4 (config-if)#no shut
R4(config-if)#end
R4 (config)#interface loopback 0
R4(config-if)#ip address 192.168.5.1 255.255.255.0
R4(config-if)#exit
*Trên Router R1:
*Trên Router R2:R1#ping 192.168.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/3/5 ms
R1#
*Trên Router R3:R2#ping 192.168.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/4/8 ms
R2#ping 192.168.3.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/3/6 ms
R2#
*Trên Router R4:R3#ping 192.168.3.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/3/5 ms
R3#ping 192.168.4.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/4/6 ms
R3#
3. Thiết lập giao thức định tuyến EIGRP trên các router.R4#ping 192.168.4.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/4/6 ms
R4#
*Trên Router R1:
*Trên Router R2:R1#configure terminal
R1(config)#router rip
R1(config-router)#version 2
R1(config-router)#network 192.168.1.0
R1(config-router)#network 192.168.2.0
R1(config-router)#no auto-summary
R1(config-router)#end
R1#
*Trên Router R3:R2#configure terminal
R2(config)#router rip
R2(config-router)#version 2
R2(config-router)#network 192.168.2.0
R2(config-router)#no auto-summary
R2(config-router)#exit
R2(config)#router eigrp 10
R2(config-router)#network 192.168.3.0
R2(config-router)#no auto-summary
R2(config-router)#exit
R2(config)#
*Trên Router R4:R3#configure terminal
R3(config)#router eigrp 10
R3(config-router)#network 192.168.3.0
R3(config-router)#no auto-summary
R3(config-router)#exit
R3(config)#
R3(config)#router ospf 1
R3(config-router)#network 192.168.4.0 0.0.0.255 area 0
R3(config-router)#exit
R3(config)#
4. Redistribute giữa các mạngR4#configure terminal
R4(config)#router ospf 1
R4(config-router)#network 192.168.4.0 0.0.0.255 area 0
R4(config-router)#network 192.168.5.0 0.0.0.255 area 0
R4(config-router)#end
R4#
*Trên Router R2:
*Trên Router R3:R2(config)#router rip
R2(config-router)#redistribute eigrp 10 metric 1
R2(config-router)#exit
R2(config)#router eigrp 10
R2(config-router)#redistribute rip metric 1000000 10 255 1 1500
R2(config-router)#end
R2#
5. Xem bảng định tuyến (routing table).R3(config)#router eigrp 10
R3(config-router)#redistribute ospf 1 metric 1000000 10 255 1 1500
R3(config-router)#exit
R3(config)#router ospf 1
R3(config-router)#redistribute eigrp 10 metric 1 subnets
R3(config-router)#end
*Trên Router R1:
*Trên Router R2:R1#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
C 192.168.1.0/24 is directly connected, Loopback0
C 192.168.2.0/24 is directly connected, Serial0/1
R 192.168.3.0/24 [120/1] via 192.168.2.2, 00:00:05, Serial0/1
R 192.168.4.0/24 [120/1] via 192.168.2.2, 00:00:05, Serial0/1
192.168.5.0/32 is subnetted, 1 subnets
R 192.168.5.1 [120/1] via 192.168.2.2, 00:00:05, Serial0/1
R1#
*Trên Router R3:R2#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
R 192.168.1.0/24 [120/1] via 192.168.2.1, 00:00:23, Serial0/0
C 192.168.2.0/24 is directly connected, Serial0/0
C 192.168.3.0/24 is directly connected, Serial0/1
D EX 192.168.4.0/24 [170/2172416] via 192.168.3.2, 00:02:23, Serial0/1
192.168.5.0/32 is subnetted, 1 subnets
D EX 192.168.5.1 [170/2172416] via 192.168.3.2, 00:02:23, Serial0/1
R2#
*Trên Router R4R3#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
D EX 192.168.1.0/24 [170/2172416] via 192.168.3.1, 00:05:42, Serial0/0
D EX 192.168.2.0/24 [170/2172416] via 192.168.3.1, 00:05:42, Serial0/0
C 192.168.3.0/24 is directly connected, Serial0/0
C 192.168.4.0/24 is directly connected, Serial0/1
192.168.5.0/32 is subnetted, 1 subnets
O 192.168.5.1 [110/65] via 192.168.4.2, 00:08:47, Serial0/1
R3#
6. Kiểm tra các router có thể ping qua lại lẫn nhau.R4#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
O E2 192.168.1.0/24 [110/1] via 192.168.4.1, 00:02:38, Serial0/0
O E2 192.168.2.0/24 [110/1] via 192.168.4.1, 00:02:38, Serial0/0
O E2 192.168.3.0/24 [110/1] via 192.168.4.1, 00:02:38, Serial0/0
C 192.168.4.0/24 is directly connected, Serial0/0
C 192.168.5.0/24 is directly connected, Loopback0
R4#
*Trên Router R2:*Trên Router R1:
R1#ping 192.168.3.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/4/5 ms
R1#ping 192.168.3.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 5/8/11 ms
R1#ping 192.168.4.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/6/8 ms
R1#ping 192.168.4.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 11/12/14 ms
R1#ping 192.168.5.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.5.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/10/15 ms
R1#
*Trên Router R3:R2#ping 192.168.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/3/5 ms
R2#ping 192.168.4.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/5 ms
R2#ping 192.168.4.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.4.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 5/7/10 ms
R2#ping 192.168.5.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.5.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/6/10 ms
R2#
*Trên Router R4:R3#ping 192.168.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 6/8/10 ms
R3#ping 192.168.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 7/9/11 ms
R3#ping 192.168.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/4/5 ms
R3#ping 192.168.5.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.5.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/3/6 ms
R3#
R4#ping 192.168.1.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 5/7/10 ms
R4#ping 192.168.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 7/10/16 ms
R4#ping 192.168.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/11 ms
R4#ping 192.168.3.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/6/10 ms
R4#ping 192.168.3.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.3.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/3/6 ms
R4#
Xem bài viết liên quan cùng chuyên mục:
![]()
Redistribute giữa RIP Ver2,OSPF và EIGRP 30/12/2011 ![]()
Redistribute EIGRP OSPF 30/12/2011 ![]()
Redistribute RIP OSPF 30/12/2011 ![]()
Redistribute RIP EIGRP 30/12/2011 ![]()
Định tuyến OSPF 30/12/2011 ![]()
Cấu hình định tuyến EIGRP 30/12/2011 ![]()
Định Tuyến RIP 30/12/2011 ![]()
Định Tuyến Tĩnh 30/12/2011
Nhấn nút "Thích" để nhận tin tức thường xuyên từ BKNP trên FB nhé bạn.


LinkBack URL
About LinkBacks


Trả lời kèm Trích dẫn


