• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.
Xin chào ! Nếu đây là lần đầu tiên bạn đến với diễn đàn, xin vui lòng danh ra một phút bấm vào đây để đăng kí và tham gia thảo luận cùng VnPro.

Announcement

Collapse
No announcement yet.

Lab 3-6: Cấu hình IGRP cơ bản

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Lab 3-6: Cấu hình IGRP cơ bản

    Lab 3-6: Cấu hình IGRP cơ bản




    Mô tả & yêu cầu

    –Router 1, router 2 sử dụng IGRP để quảng cáo thông tin định tuyến
    –Router 1 hoạt động như DCE cung cấp xung clock cho router 2
    –Các router cấu hình IGRP và quảng cáo tất cả các mạng nối trực tiếp.
    –Từ router 1, router 2 ping được hết các địa chỉ trong mạng.

    Cấu hình

    Router R1

    hostname R1
    !
    enable password cisco
    !
    ip subnet-zero
    no ip domain-lookup
    !
    interface Loopback0
    ip address 192.168.4.1 255.255.255.0
    !
    interface Loopback1
    ip address 192.168.5.1 255.255.255.0
    !
    interface Loopback2
    ip address 192.168.6.1 255.255.255.0
    !
    interface Ethernet0
    ip address 192.168.1.1 255.255.255.0
    !
    interface Serial0
    ip address 192.168.3.1 255.255.255.0
    clock rate 64000
    !
    router igrp 234
    network 192.168.1.0
    network 192.168.3.0
    network 192.168.4.0
    network 192.168.5.0
    network 192.168.6.0
    !
    end

    Router R2
    !
    hostname R2
    !
    enable password cisco
    !
    ip subnet-zero
    no ip domain-lookup
    !
    interface Loopback0
    ip address 192.168.7.1 255.255.255.0
    !
    interface Loopback1
    ip address 192.168.8.1 255.255.255.0
    !
    interface Loopback2
    ip address 192.168.9.1 255.255.255.0
    !
    interface Ethernet0
    ip address 192.168.2.1 255.255.255.0
    !
    interface Serial0
    ip address 192.168.3.2 255.255.255.0
    !
    router igrp 234
    network 192.168.2.0
    network 192.168.3.0
    network 192.168.7.0
    network 192.168.8.0
    network 192.168.9.0
    !
    end


    Các bước thực hiện

    1. Đặt hostname, cấu hình cho các cổng loopback, ethernet và serial trên router R1


    Router> en
    Router# conf t
    Router(config)# hostname R1
    R1(config)# no ip domain-lookup
    R1(config)# int e0
    R1(config-if)#ip addr 192.168.1.1 255.255.255.0
    R1(config-if)#no keepalive ← cho phép cổng Ethernet vẫn up khi không kết nối với bên ngoài
    R1(config-if)# no shut
    %LINK-3-UPDOWN: Interface Ethernet0, changed state to up
    %LINK-5-UPDOWN: Line protocol on Interface Ethernet0, changed state to up
    R1(config-if)# exit


    R1(config)# int lo0 ← Định nghĩa cổng ảo để làm điểm kiểm tra
    R1(config-if)# ip addr 192.168.4.1 255.255.255.0
    R1(config-if)# int lo1
    R1(config-if)# ip addr 192.168.5.1 255.255.255.0
    R1(config-if)# int lo2
    R1(config-if)# ip addr 192.168.6.1 255.255.255.0
    R1(config-if)# exit

    R1(config-if)# int s0
    R1(config-if)# ip addr 192.168.3.1 255.255.255.0
    R1(config-if)# clock rate 64000 ← hoạt động như DCE cung cấp xung clock
    R1(config-if)# no shut


    2. Đặt hostname, cấu hình cho các cổng loopback, ethernet và serial trên router R2


    Router> en
    Router# conf t
    Router(config)# hostname R2
    R2(config)# no ip domain-lookup

    R2(config)#int e0
    R2(config-if)# ip addr 192.168.2.1 255.255.255.0
    R2(config-if)# no shut
    R2(config-if)# int lo0
    R2(config-if)# ip addr 192.168.7.1 255.255.255.0
    R2(config-if)# int lo1
    R2(config-if)# ip addr 192.168.8.1 255.255.255.0
    R2(config-if)# int lo2
    R2(config-if)# ip addr 192.168.9.1 255.255.255.0

    R2(config-if)# int s0
    R2(config-if)# ip addr 192.168.3.2 255.255.255.0
    R2(config-if)# no shut


    3. Cấu hình giao thức định tuyến IGRP và sau đó lưu cấu hình vào NVRAM trên router R1


    R1(config)# router igrp 234 ← kích hoạt quá trình định tuyến IGRP trên router
    R1(config-router)# network 192.168.1.0 ← chỉ ra mạng sẽ quảng cáo và xác định cổng nào sẽ gởi và nhận thông tin định tuyến RIP
    R1(config-router)# network 192.168.3.0
    R1(config-router)# network 192.168.4.0
    R1(config-router)# network 192.168.5.0
    R1(config-router)# network 192.168.6.0
    R1(config-router)# end
    R1#copy run start


    4. Cấu hình giao thức định tuyến IGRP và sau đó lưu cấu hình vào NVRAM trên router R2

    R2(config)# router igrp 234
    R2(config-router)# network 192.168.2.0
    R2(config-router)# network 192.168.3.0
    R2(config-router)# network 192.168.7.0
    R2(config-router)# network 192.168.8.0
    R2(config-router)# network 192.168.9.0
    R2(config-rputer)# end
    R2# copy run start

    5. Kiểm tra và giải quyết sự cố


    Dùng lệnh clear ip route * để xoá toàn bộ route từ bảng định tuyến.

    R1# clear ip route *

    Xem quá trình gửi nhận thông tin định tuyến IGRP bằng lệnh debug ip igrp events, debug ip igrp transactions.

    R1# debug ip igrp events
    IGRP event debugging is on
    R1# debug ip igrp transactions
    IGRP protocol debuging is on
    R1#
    IGRP: received update from 192.168.3.2 on R2
    IGRP: Update contains 0 interior, 4 system, and 0 exterior routes.
    IGRP: Total routes in update: 4

    Tắt chế độ debug bằng lệnh undebug all.


    R1# undebug all
    All possible debugging has been turned off


    Xem bảng định tuyến trên R1 và R2 bằng lệnh show ip route.

    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, * - candidate default
    U - per-user static route, o - ODR
    Gateway of last resort is not set

    I 192.168.9.0/24 [100/8976] via 192.168.3.2, 00:00:46, Serial0
    I 192.168.8.0/24 [100/8976] via 192.168.3.2, 00:00:46, Serial0
    C 192.168.3.0/24 is directly connected, Serial0
    I 192.168.2.0/24 [100/8576] via 192.168.3.2, 00:00:46, Serial0
    C 192.168.1.0/24 is directly connected, Ethernet0
    I 192.168.7.0/24 [100/8976] via 192.168.3.2, 00:00:47, Serial0
    C 192.168.6.0/24 is directly connected, Loopback2
    C 192.168.5.0/24 is directly connected, Loopback1
    C 192.168.4.0/24 is directly connected, Loopback0


    Từ R1, bạn có thể thấy có 4 route IGRP học từ next-hop 192.168.3.2 và đi qua cổng S0. Chú ý số AD trong trường hợp IGRP là 100(RIP là 120 và OSPF là 110). I có nghĩa là IGRP.


    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, * - candidate default
    U - per-user static route, o - ODR
    Gateway of last resort is not set
    I 192.168.4.0/24 [100/8976] via 192.168.3.1, 00:00:46, Serial0
    I 192.168.5.0/24 [100/8976] via 192.168.3.1, 00:00:46, Serial0
    C 192.168.3.0/24 is directly connected, Serial0
    I 192.168.1.0/24 [100/8576] via 192.168.3.1, 00:00:46, Serial0
    C 192.168.2.0/24 is directly connected, Ethernet0
    I 192.168.6.0/24 [100/8976] via 192.168.3.1, 00:00:47, Serial0
    C 192.168.9.0/24 is directly connected, Loopback2
    C 192.168.8.0/24 is directly connected, Loopback1
    C 192.168.7.0/24 is directly connected, Loopback0
    Email : vnpro@vnpro.org
    ---------------------------------------------------------------------------------------------------------------
Trung Tâm Tin Học VnPro
149/1D Ung Văn Khiêm P25 Q.Bình thạnh TPHCM
Tel : (08) 35124257 (5 lines)
Fax: (08) 35124314

Home page: http://www.vnpro.vn
Support Forum: http://www.vnpro.org
- Chuyên đào tạo quản trị mạng và hạ tầng Internet
- Phát hành sách chuyên môn
- Tư vấn và tuyển dụng nhân sự IT
- Tư vấn thiết kế và hỗ trợ kỹ thuật hệ thống mạng

Network channel: http://www.dancisco.com
Blog: http://www.vnpro.org/blog

  • #2
    Hình như bác add nhầm file ảnh của RIP và IGRP rùi. hii
    :66::66:

    Comment

    • Working...
      X