资源描述
RIPv2手动汇总
RIPV2支持手动汇总
拓扑如下:
配置如下:
R1:
interface Ethernet0/0
ip address 192.168.1.1 255.255.255.0
router rip
version 2
network 192.168.1.0
no auto-summary
---------------------
R2:
interface Ethernet0/0
ip address 192.168.1.2 255.255.255.0
interface Ethernet0/1
ip address 192.168.2.2 255.255.255.0
router rip
version 2
network 192.168.1.0
network 192.168.2.0
no auto-summary
---------------------
R3:
interface Loopback 0
ip address 3.3.0.1 255.255.255.0
interface Loopback 1
ip address 3.3.1.1 255.255.255.0
interface Loopback 2
ip address 3.3.2.1 255.255.255.0
interface Loopback 3
ip address 3.3.3.1 255.255.255.0
interface Ethernet0/0
ip address 192.168.2.1 255.255.255.0
ip summary-address rip 3.3.0.0 255.255.252.0
router rip
version 2
network 3.0.0.0
network 192.168.2.0
no auto-summary
手动汇总应用在路由更新的出接口方向上
在R1上查看路由表:
汇总成为了/22的路由了,这样减小了路由条目,这样也同时减轻了路由器的负担。
-----------------------------------------------------------------------------------------------------------------------------------------------------
还有一种情况 拓扑:
R1的配置
interface Loopback0
ip address 192.168.96.1 255.255.255.0
interface Loopback1
ip address 192.168.97.1 255.255.255.0
interface Loopback2
ip address 192.168.98.1 255.255.255.0
interface Loopback3
ip address 192.168.99.1 255.255.255.0
router rip
version 2
redistribute static
network 192.168.1.0
network 192.168.96.0
network 192.168.97.0
network 192.168.98.0
network 192.168.99.0
no auto-summary
exit
ip route 1 92.168.96.0 255.255.252.0 null 0
用静态路由的方式进行重发布,在接口上做的话提示:
表示汇总后的掩码要大于等于主类网络的掩码长度,所以写一条静态路由指向空接口,然后在RIP路由进程中进行重发布的方法来实现。RIPV2不支持CIDR汇总,但传递CIDR汇总。 查看R3的路由表,看到最后一条
展开阅读全文