Chia Sẽ Kinh Nghiệm Về IT



Tìm Kiếm Với Google
-


8. Configure IP Routes (Static Route, DHCP, DNS) Static Route, Inter VLAN Roting Explain the operation and benefits of using DHCP and DNS, Configure, verify and troubleshoot, DHCP and DNS operation on a router.

Gởi Ðề Tài Mới  Gửi trả lời
 
Công Cụ Xếp Bài
Tuổi 11-08-2009, 10:55 PM   #1
adminphuong
Administrator
 
Avatar của adminphuong
 
Gia nhập: Jul 2009
Trả Lời: 152
Cấu hình định tuyến tĩnh
Cấu hình định tuyến tĩnh



Mô tả & yêu cầu

–Cấu hình static route trên các router A, router B và router C.
–RouterC hoạt động như DCE router, RouterA là DTE router.
–Từ các router, ta phải có thể ping được tất cả các địa chỉ trong mạng

Cấu hình
RouterA
!
hostname RouterA
no ip domain-lookup
!
interface s0
ip address 10.0.3.2 255.255.255.0
no shutdown
!
interface E0
ip address 10.0.2.2 255.255.255.0
no shutdown
!
end

RouterA
!
hostname RouterB
no ip domain-lookup
!
interface E0
ip address 10.0.2.1 255.255.255.0
no shutdown
!
ip route 10.0.3.0 255.255.255.0 e0
!
end

RouterC
!
hostname RouterC
no ip domain-lookup
!
interface s0
ip address 10.0.3.100 255.255.255.0
no shutdown
!
ip route 10.0.2.0 255.255.255.0 10.0.3.2
!
end

Các bước thực hiện
Bước 1: Cấu hình RouterA

RouterA(config)#hostname RouterA
RouterA(config)#no ip domain-lookup
RouterA(config)#interface s0
RouterA(config-if)#ip address 10.0.3.2 255.255.255.0
RouterA(config-if)#no shutdown

- Khi thực hiện lệnh no shutdown, sẽ hiện dòng thông báo

01:31:19: %LINK-3-UPDOWN: Interface Serial0/0, changed state to up

RouterA(config-if)#interface E0
RouterA(config-if)#ip address 10.0.2.2 255.255.255.0
RouterA(config-if)#no shutdown
01:34:38: %LINK-3-UPDOWN: Interface FastEthernet0/1, changed state to up
RouterA(config-if)#end
01:35:39: %SYS-5-CONFIG_I: Configured from console by console
RouterA#

Bước 2: Cấu hình RouterB

RouterB(config)#hostname RouterB
RouterB(config)#no ip domain-lookup
RouterB(config-if)#interface e0
RouterB(config-if)#ip address 10.0.2.1 255.255.255.0
RouterB(config-if)#no shut
01:44:38: %LINK-3-UPDOWN: Interface FastEthernet0/1, changed state to up
RouterB(config-if)#end
01:45:39: %SYS-5-CONFIG_I: Configured from console by console
RouterB#

Bước 3: Cấu hình cơ bản router RouterC

RouterC(config)#hostname RouterC
RouterC(config)#no ip domain-lookup
RouterC(config)#interface s0
RouterC(config-if)#ip address 10.0.3.100 255.255.255.0
RouterC(config-if)#no shutdown
01:51:19: %LINK-3-UPDOWN: Interface Serial0/0, changed state to up
RouterC(config-if)#end
01:51:39: %SYS-5-CONFIG_I: Configured from console by console
RouterC#

Bước 4: Kiểm tra kết nối giữa các router RouterA, RouterC và RouterB

RouterC#ping 10.0.3.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.3.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms

- Nếu không ping được, kiểm tra lại cấu hình bằng lệnh show running-config, show interface để đảm bảo cấu hình đúng, giải quyết sự cố nếu cần.

RouterB#ping 10.0.2.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.2.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms
RouterB#ping 10.0.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.2.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms

RouterA#ping 10.0.3.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.3.100, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms

RouterC#ping 10.0.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.2.1, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)

RouterB#ping 10.0.3.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.3.100, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)

–Trên router RouterC, xem bảng định tuyến bằng lệnh show ip route

RouterC#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

10.0.0.0/24 is subnetted, 1 subnets
C 10.0.3.0 is directly connected, Serial0/0

Bước 5: Cấu hình Static Routes
–Tại router RouterC, cấu hình static route đến router RouterB:

RouterC(config)#ip route 10.0.2.0 255.255.255.0 10.0.3.2
RouterC(config)#exit
02:06:37: %SYS-5-CONFIG_I: Configured from console by console

+ Khi cấu hình next hop router là địa chỉ IP thì AD = 0; ta cấu hình next hop router sử dụng outgoing interface thì AD = 1.

–Tại router RouterB, định tuyến static route đến router RouterC:

RouterB(config)#ip route 10.0.3.0 255.255.255.0 e0
RouterB(config)#exit
02:06:37: %SYS-5-CONFIG_I: Configured from console by console

–Tại router RouterC, ping router RouterB bằng lệnh ping 10.0.2.1

RouterC#ping 10.0.2.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.2.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms

–Tại router RouterB, ping router RouterC bằng lệnh ping 10.0.3.100

RouterB#ping 10.0.3.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.0.3.100, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/4/8 ms

–Xem bảng định tuyến trên router RouterC bằng lệnh show ip route:

RouterC#show ip route
...
Gateway of last resort is not set

10.0.0.0/24 is subnetted, 2 subnets
S 10.0.2.0 [1/0] via 10.0.3.2
C 10.0.3.0 is directly connected, Serial0/0

Chú ý: S biểu thị cho kết nối static với AD = 1 và hop count là 0 [1/0]

–Xem bảng định tuyến trên router RouterB:

RouterB#show ip route
...
Gateway of last resort is not set

10.0.0.0/24 is subnetted, 2 subnets
C 10.0.2.0 is directly connected, FastEthernet0/1
S 10.0.3.0 is directly connected, FastEthernet0/1

Chú ý AD = 0 khi ta chọn outgoing interface để cấu hình static route. Ở đây ta không thấy entry [1/0] trong cấu hình.
__________________
Theo: Viet Professionals Co. Ltd. VnPro ®

adminphuong vắng mặt   Trả lời ngay kèm theo trích dẫn này
Gửi trả lời


Công Cụ
Xếp Bài

Quyền Hạn Của Bạn
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is Mở
Hình Cảm xúc đang Mở
[IMG] đang Mở
Mã HTML đang Tắt




Bây giờ là 04:49 PM. Giờ GMT +7



Diễn đàn tin học QuantriNet
quantrinet.com | quantrimang.co.cc
Founded by Trương Văn Phương | Developed by QuantriNet's members.
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.