show run
Building configuration...

Current configuration : 645 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r1
!
boot-start-marker
boot-end-marker
!
enable secret 5 $1$vMtl$vyIqgd.05F/mZXt4J9d/r/
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
ip host r2 172.16.3.2
!
ip cef
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/0
 description link to r2
 ip address 172.16.3.1 255.255.255.252
 duplex half
!
router rip
 network 172.16.0.0
!
ip classless
no ip http server
!
!
!
!
!
!
!
!
!
gatekeeper
 shutdown
!
banner motd ^CWelcome to r1^C
!
line con 0
 stopbits 1
line aux 0
line vty 0 4
 no login
!
!
end

r1#show ip route
Codes: C - connected, S - static, 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
       i - IS-IS, su - IS-IS summary, 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

     172.16.0.0/30 is subnetted, 2 subnets
R       172.16.3.4 [120/1] via 172.16.3.2, 00:00:07, FastEthernet0/0  // 这条没有被汇总成172.16.3.0 是因为它与出站接口在同一个主网,而且使用了相同的掩码.
C       172.16.3.0 is directly connected, FastEthernet0/0
R    10.0.0.0/8 [120/1] via 172.16.3.2, 00:00:07, FastEthernet0/0
r1#r2
Translating "r2"
Trying r2 (172.16.3.2)... Open
Welcome to r2
r2>en
Password:
r2#show run
Building configuration...

Current configuration : 977 bytes
!
version 12.3
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname r2
!
boot-start-marker
boot-end-marker
!
enable secret 5 $1$KhLx$ZAmF3HwWijRxDdjh4.bf10
!
no aaa new-model
ip subnet-zero
!
!
no ip domain lookup
ip host r1 172.16.3.1
!
ip cef
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface Loopback0
 description test ip
 ip address 10.1.0.1 255.255.0.0
!
interface Loopback1
 description test ip
 ip address 10.2.1.1 255.255.255.0
!
 interface Loopback2
 description test ip
 ip address 10.3.0.1 255.255.255.0
!
interface Loopback3               //如果我将这个测试IP改成非30位的掩码. 那么在 r1 的IP地址中就只有一条直连的 172.16.3.0 的路由.因为跟出站掩码不同.这         

                                    条路由本应该被汇总显示为 R 172.16.0.0 /16 .但是因为有更好的 C 172.16.3.0 /24 .所以 R 的会被屏蔽掉.只留下直连的路由条目.
 description test ip
 ip address 172.16.3.5 255.255.255.252
!
interface FastEthernet0/0
 description link to r1
 ip address 172.16.3.2 255.255.255.252
 duplex half
!
router rip
 network 10.0.0.0
 network 172.16.0.0
!
ip classless
no ip http server
!
!
!
!
!
!
!
!
!
gatekeeper
 shutdown
!
banner motd ^CWelcome to r2^C
!
line con 0
 stopbits 1
line aux 0
line vty 0 4
 no login
!
!
end

r2#show ip route
Codes: C - connected, S - static, 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
       i - IS-IS, su - IS-IS summary, 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

     172.16.0.0/30 is subnetted, 2 subnets
C       172.16.3.4 is directly connected, Loopback3
C       172.16.3.0 is directly connected, FastEthernet0/0
     10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
C       10.3.0.0/24 is directly connected, Loopback2
C       10.2.1.0/24 is directly connected, Loopback1
C       10.1.0.0/16 is directly connected, Loopback0
r2#

 

IGRP 的似乎都不见了. router igrp 好像没有.呵呵. 这个试验没法做了.