文档库 最新最全的文档下载
当前位置:文档库 › RIP实验学习笔记

RIP实验学习笔记

RIP实验学习笔记
RIP实验学习笔记

RIP实验学习笔记

2009.6.5—6.10

一.实验目的

A.理解RIP的原理和操作;

B.清楚RIP注意问题;

C.熟悉RIP配置命令;

D.使用show和debug命令查看拓扑变化时收敛过程;

E.抓包分析RIP报文;

二.拓扑和要求

S1、R1、R2之间RIP采用MD5认证;

R1、R4之间RIP采用明文认证;

S2运行OSPF,R2从S2重发布,并在LAN上通告这些路由,用于演示RIP的下一条特性;

R5的帧中继配置在物理接口上,一边查看no ip split-horizon默认行为的效果;

三.实验过程

3.1 连通性配置

遇到的问题:

?1.R5路由器ping不通自己的S0/0接口地址172.31.25.1,能ping通R2的子接口s1/0.205地址172.31.25.2,从R2上却能ping通172.31.25.1;

R5>ping 172.31.25.1

Sending 5, 100-byte ICMP Echos to 172.31.25.1, timeout is 2 seconds:

.....

Success rate is 0 percent (0/5)

R5>ping 172.31.25.2

Sending 5, 100-byte ICMP Echos to 172.31.25.2, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 16/28/44 ms

R2#ping 172.31.25.1

Sending 5, 100-byte ICMP Echos to 172.31.25.1, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 28/36/48 ms

2.子接口水平分割缺省是enable的;但物理接口的水平分割缺省是disable的(配置了IP地址的FR封装的物理接口上水平分割缺省是disable的!);

R2#sh ip int s1/0.203

Serial1/0.203 is up, line protocol is up

Internet address is 172.31.23.2/30

Broadcast address is 255.255.255.255

Proxy ARP is enabled

Security level is default

Split horizon is enabled

R5#sh ip int s0/0

Serial0/0 is up, line protocol is up

Internet address is 172.31.25.1/30

Broadcast address is 255.255.255.255

Proxy ARP is enabled

Security level is default

Split horizon is disabled

2.traceroute的问题,从S1上traceroute 172.31.10

3.3

S1#traceroute 172.31.103.3

1 172.31.11.1 28 msec

172.31.11.2 32 msec

172.31.11.1 16 msec

2 172.31.23.1 52 msec

172.31.13.2 24 msec

172.31.23.1 20 msec

3. S2的loopback接口地址在路由条目里显示为172.31.221.202/32(从OSPF重发布来的),而S1的loopback接口地址路由条目显示为172.31.211.0/24(rip来)

3.2 基本rip配置

R1(config)#router rip

R1(config-router)#?

Router configuration commands:

address-family Enter Address Family command mode

auto-summary Enable automatic network number summarization

default Set a command to its defaults

default-information Control distribution of default information

default-metric Set metric of redistributed routes

distance Define an administrative distance

distribute-list Filter networks in routing updates

exit Exit from routing protocol configuration mode

flash-update-threshold Specify flash update threshold in second

input-queue Specify input queue depth

maximum-paths Forward packets over multiple paths

neighbor Specify a neighbor router

network Enable routing on an IP network

no Negate a command or set its defaults

offset-list Add or subtract offset from IGRP or RIP metrics

output-delay Interpacket delay for RIP updates

passive-interface Suppress routing updates on an interface

redistribute Redistribute information from another routing protocol

timers Adjust routing timers

traffic-share How to compute traffic share over alternate paths

validate-update-source Perform sanity checks against source address of routing updates

version Set routing protocol version

network命令注解

The RIP network command only allows for a classful network as a parameter, which in turn enables RIP on all of that router’s interfaces that are part of that network. Enabling RIP on an interface makes the router begin sending RIP updates, list ening for RIP updates (UDP port 520), and advertising that interface’s connected subnet.Because the RIP network command has no way to simply match one interface at a time, a RIP configuration may enable these three functions on an interface ,but some or all of these functions are not required. The three RIP functions can be

问题1.Ping 172.31.25.1(R5的物理串口地址)问题

(1)R6能ping通,R6路由表为:

R6>sh ip route

172.31.0.0/16 is variably subnetted, 2 subnets, 2 masks

C 172.31.16.0/24 is directly connected, Serial0/0.601

R 172.31.0.0/16 [120/1] via 10.1.26.2, 00:00:14, Serial0/0.602

10.0.0.0/8 is variably subnetted, 3 subnets, 2 masks

R 10.0.0.0/8 [120/3] via 10.1.26.2, 00:00:14, Serial0/0.602

C 10.1.26.0/24 is directly connected, Serial0/0.602

C 10.1.106.0/24 is directly connected, Loopback1

(2)R5自己ping不通25.1,能ping通172.31.25.2

(3)R4能ping通R5

(4)R3ping不通172.31.25.1,也ping不通172.31.25.2;(R3ping自己反应很慢,ping其他都ping不通,R1ping R3的103.3正常,但ping不通R3的13.2),

R3#ping 172.31.23.1

Sending 5, 100-byte ICMP Echos to 172.31.23.1, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 1612/1685/1752 ms

R3#ping 172.31.23.2

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 172.31.23.2, timeout is 2 seconds:

.....

Success rate is 0 percent (0/5)

R3路由表为:

172.31.0.0/16 is variably subnetted, 18 subnets, 2 masks

R 172.31.211.0/24 [120/6] via 172.31.23.2, 00:00:11, Serial0/0.302

R 172.31.223.0/24 [120/2] via 172.31.23.2, 00:00:11, Serial0/0.302

[120/2] via 172.31.13.1, 00:00:17, Serial0/0.301

R 172.31.16.0/24 [120/1] via 172.31.13.1, 00:00:17, Serial0/0.301

R 172.31.23.0/30 [120/2] via 172.31.13.1, 00:00:17, Serial0/0.301

C 172.31.23.0/24 is directly connected, Serial0/0.302

R 172.31.25.0/30 [120/1] via 172.31.23.2, 00:00:13, Serial0/0.302

R 172.31.24.0/30 [120/1] via 172.31.23.2, 00:00:13, Serial0/0.302

?问题2:从R2上PING172.31.13.1(R1接口)和172.31.13.2(R3接口),

如何解决???

R2#sh ip route

R 172.31.13.0/24 [120/1] via 172.31.23.1, 00:00:17, Serial1/0.203

R 172.31.13.0/30 [120/1] via 172.31.11.1, 00:00:09, FastEthernet0/0

R2#sh ip route 172.31.13.0

Routing entry for 172.31.13.0/30

Known via "rip", distance 120, metric 1

Redistributing via rip

Last update from 172.31.11.1 on FastEthernet0/0, 00:00:27 ago

Routing Descriptor Blocks:

* 172.31.11.1, from 172.31.11.1, 00:00:27 ago, via FastEthernet0/0

Route metric is 1, traffic share count is 1

R2#sh ip route 172.31.13.0 255.255.255.0

Routing entry for 172.31.13.0/24

Known via "rip", distance 120, metric 1

Redistributing via rip

Last update from 172.31.23.1 on Serial1/0.203, 00:00:19 ago

Routing Descriptor Blocks:

* 172.31.23.1, from 172.31.23.1, 00:00:19 ago, via Serial1/0.203

Route metric is 1, traffic share count is 1

3.3 认证配置

配置R1,R2在LAN上MD5认证

R1: 定义密钥链key chain keyLAN --–key 1--—key string ripv2;

Fa0/0接口上启用rip认证Ip rip authentication key-chain keyLAN ---ip rip authentication mode md5

R2:定义密钥链:key chain lankey--→key 1-→key-string ripv2-→key 2-→key-string ripv22

Fa0/0接口上启用RIP认证:ip rip authentication mode md5→ip rip authentication key-chain lankey;

配置R1与R4明文认证

R1:

R4(config)#key chain withR2

R4(config-keychain)#KEY 1

R4(config-keychain-key)#key-string plaintext

R4(config-keychain-key)#exit

R4(config-keychain)#exit

R4(config)#int s0/0.401

R4(config-subif)#ip rip authentication key-chain withR2

3.4 水平分割和下一跳

水平分割缺省在每个接口上是ON的,除了配置了IP地址的FR封装的物理串口上(本例中的R5串口S0/0)

R5#sh ip int s0/0

Serial0/0 is up, line protocol is up

Split horizon is disabled

ICMP redirects are always sent

下一跳(next-hop)属性允许路由器对通告的路由下一跳指向其他路由器,而不是自己;本例中S2运行OSPF,R2将S2连接的网络通过重发布通告给其他路由器,由于R2/S2/R1连接在同一个LAN上,因此R2在向R1通告S2的路由的时候将下一条指向S2而不是R2自己

配置:

S2:router ospf 10→network 172.31.0.0 .0.0.255.255 area 0

R2:router ospf 20→network 172.31.0.0 0.0.255.255 area 0 ,network 10.1.26.0 0.0.0.255 area 0

Router rip-→redistribute ospf 20 metric 2

R1路由如下:

R1#show ip route 172.31.221.202

Routing entry for 172.31.221.202/32

Known via "rip", distance 120, metric 2

Redistributing via rip

Last update from 172.31.11.202 on FastEthernet0/0, 00:00:02 ago

Routing Descriptor Blocks:

* 172.31.11.202, from 172.31.11.2, 00:00:02 ago, via FastEthernet0/0

Route metric is 2, traffic share count is 1

R1#sh ip route

Gateway of last resort is not set

172.31.0.0/16 is variably subnetted, 14 subnets, 3 masks

C 172.31.16.0/24 is directly connected, Serial1/0.106

R 172.31.221.202/32 [120/2] via 172.31.11.202, 00:00:24, FastEthernet0/0

R 172.31.222.202/32 [120/2] via 172.31.11.202, 00:00:24, FastEthernet0/0

3.5 路由控制

Offset lists---改变metric值,对于匹配ACL的路由,接口通告的和接口接收到的;

R1上offset list配置

R1(config)#router rip

R1(config-router)#offset-list 10 out 8 s1/0.103

R1(config-router)#offset-list 10 out 8 s1/0.104

R1(config-router)#offset-list 10 out 8 s1/0.106

R1(config-router)#exit

R1(config)#access-list 10 permit172.31.208.0 0.0.7.255(匹配的地址范围???)

R2上offset list配置:

R2(config)#router rip

R2(config-router)#offset-list 12 in 4 fa0/0

R2(config-router)#exit

R2(config)#access-list 12 permit 172.31.208.0 0.0.7.255

R2(config)#

使用Distribute list过滤路由

匹配ACL和prefix list中deny的子网将被过滤

distribute-list {access-list-number | name} {in | out} [interface-type interface-number] distribute-list {prefix list-name} {in | out } [interface-type interface-number]

四.实验总结

RIP路由协议复杂的是,在路由失效拓扑收敛时为防止环路所使用的方法。

五.RIP基础知识复习

5.0 路由基础(routing basic)

A.IP Packet Header

IP Version numbers

TOS or DiffServ(DSCP)

Well-known protocol numbers:

ARP packet format

Common hardware type

C.ICMP

ICMP packet format

Debug ip icmp

D.路由基础

路由条目至少包含2条信息:一是目的地,一是指向目的地的指针(可以是路由器的某个接口(exit interface)或是下一条的IP地址(next hop));

路由器获得路由信息的三个方式:1.直连网络(directly connected);2.人为手工配置的静态路由(static),一是通过路由协议动态发现并共享信息来构建路由条目(dynamic)配置静态路由命令:

ip route prefix mask {address | interface [next-hop-address]} [distance] [permanent] [name name] [tag tag-number]

Floating static route

Load-sharing(equal cost path ,unequal cost path, cef, fast switching,)

Per destination load sharing distributes the load according to destination address. This is the default type of load sharing used by Cisco Express Forwarding (CEF). On most platforms, CEF is the default switching mode for IPv4, but not IPv6.

Per packet load sharing is another method available to CEF switched IPv4 packets. IPv6 CEF only supports per destination load sharing. Per packet load sharing may distribute the load more evenly than per destination load sharing, depending upon the number of different source-destination pairs, but because the packets to a given destination will be taking different paths, the packets are likely to arrive out of order, which is unacceptable for some applications, such as Voice over IP.

questions:

1What information must be stored in the route table?

2What does it mean when a route table says that an address is variably subnetted?

3What are discontiguous subnets?

4What IOS command is used to examine the IPv4 route table?

5What IOS command is used to examine the IPv6 route table?

6What are the two bracketed numbers associated with the nondirectly connected routes in the route table?

7When static routes are configured to reference an exit interface instead of a next-hop address, how will the route table be different?

8What is a summary route? In the context of static routing, how are summary routes useful?

9What is an administrative distance?

10What is a floating static route?

11What is the difference between equal-cost and unequal-cost load sharing?

12How does the switching mode at an interface affect load sharing?

13What is a recursive table lookup?

E.路由环路排查基本思路

Ping→>Trace→Show ip route→show arp→ARP静态条目

5.1 RIP 基础

A RIP message format

Features:

Transport: UDP, port 520.

Metric :Hop count, with 15 as the maximum usable metric, and 16 considered to be infinite.

Hello interval :None; RIP relies on the regular full routing updates instead.

Update destination: Local subnet broadcast (255.255.255.255) for RIPv1; 224.0.0.9 multicast for RIPv2.

Update interval :30 seconds.(interface)

Full or partial updates: Full updates each interval. For on-demand circuits, allows RIP to send full updates once, and then remain silent until changes occur, per RFC 2091. Full updates each interval. Triggered updates: Yes, when routes change.

Multiple routes to the same subnet:Allows installing 1 to 6 (default 4) equal-metric routes to the same subnet in a single routing table.

Authentication*:Allows both plain-text and MD5 authentication.

Subnet mask in updates*:RIPv2 transmits the subnet mask with each route, thereby supporting VLSM,making RIPv2 classless. This feature also allows RIPv2 to support discontiguous network s.

VLSM* Supported :as a result of the inclusion of subnet masks in the routing updates.

Route Tags* Allows RIP to tag routes as they are redistributed into RIP.

Next Hop field* Supports the assignment of a next-hop IP address for a route, allowing a router

to advertise a next-hop router that is different from itself.

RIP Convergence and loop prevention

Split horizon:

Triggered update :The immediate sending of a new update when routing information changes, instead of waiting for the Update timer to expire.

Route poisoning:The process of sending an infinite-metric (hop count 16) route in routing updates when that route fails.

Poison reverse :The act of advertising a poisoned route (metric 16) out an interface, but in reaction to receiving that same poisoned route in an update received on that same interface.

Update timer The timer that specifies the time interval over which updates are sent. Each interface uses an independent timer, defaulting to 30 seconds.

Holddown timer: A per-route timer (default 180 seconds) that begins when a route’s metric changes to a larger value. The router does not add an alternative route for this subnet to its routing table until the Holddown timer for that route expires.

Invalid timer A per-route timer that increases until it receives a routing update that confirms the route is still valid, upon which the timer is reset to 0. If the updates cease, the Invalid timer will grow until it reaches the timer setting (default 180 seconds), after which the route is considered invalid. Flush(Garbage) timer

A per-route timer that is reset and grows with the Invalid timer. When the Flush timer mark is reached (default 240 seconds), the router removes the route from the routing table and accepts new routes to the failed subnet.

Protocol or Feature Standard

RIP (Version 1) RFC 1058

RIP (Version 2) RFC 2453

RIP Update Authentication RFC 2082

RIP Triggered Extensions for On-Demand Circuits R FC 2091

RIP 配置命令

router rip Global config; puts user in RIP configuration mode

network ip-address RIP config mode; defines classful network, with all interfaces in that network sending and able to receive RIP advertisements

distribute-list [access-list-number |name | prefix name] | {in | out}[interface-type |

interface-number]

RIP config mode; defines ACL or prefix list to filter RIP updates

ip split-horizon Interface subcommand; enables or disables split horizon

passive-interface [default]{interface-type interface-number}

RIP config mode; causes RIP to stop sending updates on the specified interface

timers basic update invalid holddown flush

RIP config mode; sets the values for RIP timers

version {1 | 2} RIP config mode; sets the RIP version to version 1 or version 2

offset-list {access-list-number |access-list-name} {in | out} offset [interface-type interface-number] RIP config mode; defines rules for RIP to add to the metrics of particular routes

neighbor ip-address RIP config mode; identifies a neighbor to which unicast RIP updates will be sent

show ip route rip User mode; displays all routes in the IP routing table learned by RIP

show ip rip database User mode; lists all routes learned by RIP, even if a route is not

in the routing table because of a route with lower administrative distance

debug ip rip Enable mode; displays details of RIP processing

show ip protocols User mode; lists RIP timer settings, current protocol status, autosummarization actions, and update sources

clear ip route {network [mask] | *} Enable mode; clears the routing table entry, and with RIP, sends RIP requests, quickly rebuilding the routing table

show ip interface [type number] [brief]

User mode; lists many interface settings, including split horizon

key chain name-of-chain

Global config; defines name of key chain for routing protocol authentication

key key-id Key config mode; identifies a key by number

key string Key config mode; defines the text of the key

send-lifetime [start-time {infinite | end-time | duration seconds}]

Key config mode; defines when the key is valid to be used for sent updates

accept-lifetime [start-time {infinite | end-time | duration seconds}]

Key config mode; defines when the key is valid for received updates

ip rip authentication key-chain name-of-chain

Interface mode; enables RIP authentication on the interface

ip rip authentication mode {text | md5}

Interface mode; defines RIP authentication as clear text (default) or MD5

CCIE考试中涉及的RIP问题:

一,被动接口问题

技术的精髓就是体现一个效率,而RIP却天生具有没有效率的危险性。RIP生于一个有类路由协议的时代,所以,他的血液始终具有有类路由协议的烙印。所以,即使发展到RIP版本2,在思科的产品里,在发布一条路有的时候,还是不能携带类似于OSPF,EIGRP等协议具有的反掩吗,所以,具有这个主类网络的所有子网网段都将被发布,例如,发布,1.0.0.0,那么1.1.12.0 1.1.35.0等网络接口都将被发布,结果造成了滥杀无辜的场面。为了解决这个问题,思科提供了passive这个指令,就是不想要运行的接口,可以用这个命令,把它给被动掉,例如,passive int s0,但是,当需要被动的接口很多的时候,我们说这样一个一个做,很没有效率,所以,有一条指令就发挥出作用了,passive default,把全部接口进行

被动掉,对于不想被动掉的接口就用no passvie接口命令进行打开。

二,路由汇总问题

在距离矢量路由协议里,都有一个自动汇总问题,RIP,EIGRP,BGP都有这个问题。其实,自动汇总并不是坏事,有人总是看不得汇总的路由,具体的路由看不到,总是感觉到不舒服。呵呵,如果,路由条目比较少,这当然不是一个坏事。可是,如果路由条目庞大,那么汇总的优点就不言而喻了。

那么在CCIE的考试中,在RIP的配置下,到底什么时候需要关掉自动汇总呢?(默认是打开汇总的),我们知道,如果,你打开了路由汇总,那么通告路由的时候,只是通告一条按主类网络汇总过的路由,那么具体路由就不会发出,而关掉路由自动汇总,那么具体网段路由就会被通告,而汇总路由网段就不会被通告。在CCIE的考试中,特别要注意给出的地址属于哪个网段,还要注意他允许你通告的路由是多少位的掩码的。比如,你的网段是B类网段,他让你通告X.X.0.0/16的路由,所以,你就一定得打开自动汇总,否则根本不能通告汇总的路由。但是,如果你是A类的网络,它仍要你通告X.X.0.0/16的路由,那么一定要关掉路由自动汇总,然后在接口上使用ip summary-address rip这条指令了。

三,水平分割问题

要注意,在CCIE的考试中,有的时候,RIP是运行在帧中继链路下,而帧中继链路有一种特殊的拓扑,就是hub-spoke模式,在hub那端,是一个接口连接着几个点,如果不用子接口,就会产生一个问题,就是RIP用到的水平分割技术,水平分割有这样的特点,就是从一个接口学到的路由不能再从这个接口发出去(毒性逆转除外),所以,可能是RIP的开发者为了方便,默认就在帧中继环境上关闭了水平分割,让spoke 上的机器能顺利地学到路由。但是,如果环境变成点到点的,那么就可能就会产生环路,所以,要注意在点到点的环境下,关掉水平分割。

四,认证问题

RIP的认证和eigrp认证是一样的,是一种模块化的配置,密钥链的定义和协议无关,只需要在接口上启用就可以了。

RIP版本2支持明文和MD5加密口令的认证,默认的认证方式是明文口令。

配置命令如下:

1.定义钥匙链。

rt(config)#key chain {name}

2.定义密钥的号码,可以配置多个密钥号码,便于在更换密钥的时候,网络不中断。先使用号码底的密钥,如果,号码低的密钥出现问题,或者不再有效,那么就使用号码高的密钥。

rt(config-keychain)#key {number}

3.这个是非常不错的一个选项,定义密钥的开始使用时间,再订立多个密钥的情况下,可以让不同的密钥在不同的时间实效,有效,大大增强了方便性和安全性,注意,这两个密钥之间最好有30分钟的重叠时间。

https://www.wendangku.net/doc/ed17960630.html,(config-keychain-key)#accept-lifetime {start} {infinite|end|duration seconds}

rt(config-keychain-key)#send-lifetime {start} {infinite|end|duration seconds}

4.定义密钥

rt((config-keychain-key)#key-string {password}

5.启用RIP认证,调用配置的密钥链

rt(config-if)#ip rip authentication key-chain {name }

6.定义认证方式,思科RIP支持明文和MD5 的认证,默认是明文认证

rt(config-if)#ip rip authentication mode {text|md5}

五、单播问题

我们说RiP版本1的通告是广播,而RIP版本2的通告是组播,应该说进步不少,但是,在多路访问网络里,比如说以太网,还是有滥杀无辜之嫌。你想想,只要交换机不划vlan,那么组播包还是要被所有的机器收到的。所以,如果只想多路访问网络里面跟某几台机器运行RIP协议,那么运行单播就会大大节省资源。

指令很简单

neighbor ip-address

注意,这条指令和被动接口指令要结合使用,因为,如果,如果不用被动接口,那么这个接口同时还要发广播或者组播,而被动接口命令对单播时没有作用的。

router rip

network 10.108.0.0

passive-interface ethernet 1

neighbor 10.108.20.4

六,版本问题

其实,这个越来越已经不成为问题,因为最新的CCIE大纲要求是只考版本2,但是以前考试的时候,这个曾经是大家考虑的重点。花香已随花落去,春燕总能伴春来!呵呵,这个谁又说的清呢?

如果你不配置任何东西,那么RIP默认的是既不是版本1,也不是版本2,而是具有这样的一个混杂特性。就是能接收版本1,版本2,但是只能发送版本1,如果,你配置了VER 1,那么,它只能接收和发送版本1,如果,你配置了VER 2,它只能接收和发送版本2了,但是,如果你在RIP模式下制定了版本号,但是在接口下还可以指定发送和接收的版本号,并且,接口上配置的版本号码,优先级要高于在全局模式下配置的版本号。

命令

RIP配置模式下

version {1 | 2}

接口配置模式下:

ip rip receive version [1] [2]

ip rip send version [1] [2]

七,偏移量问题

RIP对路径的衡量是按照跳数来计算的,这多少有点滑稽,2个大象等于2个蚂蚁,一个千兆链路,跳数有2跳,一个64K链路,跳数有2条,RIP认为这两个链路是一样的。所以,既然他是盲的,我们有必要搞一个导盲犬,offset list这个指令就可以完成这个功能,根据网络的实际情况,作出调整。

命令

offset-list {access-list-number | access-list-name} {in | out} offset [interface-type interface-number]

例子

offset-list 12 in 5 ethernet 0

QUESTIONS:

1What is a routing protocol?

2What basic procedures should a routing algorithm perform?

3Why do routing protocols use metrics?

4What is convergence time?

5What is load balancing? Name four different types of load balancing.

6What is a distance vector routing protocol?

7Name several problems associated with distance vector protocols.

8What are neighbors?

9What is the purpose of route invalidation timers?

10Explain the difference between simple split horizon and split horizon with poisoned reverse.

11What is the counting-to-infinity problem, and how can it be controlled?

12What are holddown timers, and how do they work?

13What are the differences between distance vector and link state routing protocols?

14What is the purpose of a topological database?

15Explain the basic steps involved in converging a link state network.

16Why are sequence numbers important in link state protocols?

17What purpose does aging serve in a link state protocol?

18Explain how an SPF algorithm works.

19How do areas benefit a link state network?

20What is an autonomous system?

21What is the difference between an IGP and an EGP?

1What port does RIP use?

2What metric does RIP use? How is the metric used to indicate an unreachable network?

3What is the update period for RIP?

4How many updates must be missed before a route entry will be marked as unreachable?

5What is the purpose of the garbage collection timer?

6Why is a random timer associated with triggered updates? What is the range of this timer?

7What is the difference between a RIP Request message and a RIP Response message?

8Which two types of Request messages does RIP use?

9Under what circumstances will a RIP response be sent?

10Why does RIP hide subnets at major network boundaries?

1Which three fields are new to the RIPv2 message format?

2Besides the extensions defined by the three fields of question 1, what are the other two major changes from RIPv1?

3What is the multicast address used by RIPv2? What is the advantage of multicasting messages over broadcasting them?

4What is the purpose of the Route Tag field in the RIPv2 message?

5What is the purpose of the Next Hop field?

6What is the UDP port number used by RIPv2?

7What is the UDP port number used by RIPng?

8Which one feature must a routing protocol have to be a classless routing protocol?

9Which one feature must a routing protocol have to use VLSM?

10Which two types of authentication are available with the Cisco RIPv2? Are they both defined in RFC 2453?

参考:

https://www.wendangku.net/doc/ed17960630.html,IE Professional Development--Routing TCP/IP,V1,Second Edition(CHM,2006,chapter1-6)

https://www.wendangku.net/doc/ed17960630.html,IE Professional Development--Troubleshooting IP Routing Protocols(PDF,2002,Chapter1-3)

https://www.wendangku.net/doc/ed17960630.html,IE Routing and Switching Official Exam Certification Guide 2nd Edition(PDF,2006,Chapter7-8)

https://www.wendangku.net/doc/ed17960630.html,

https://www.wendangku.net/doc/ed17960630.html,

https://www.wendangku.net/doc/ed17960630.html,/go/rip

7.4.1 启用RIP 路由进程和RIP 参数的配置步骤及示例 https://www.wendangku.net/doc/ed17960630.html, 2010-10-19 14:48 王达 华中科技大学出版社 我要评论(0) ? 摘要:《路由器配置与管理完全手册-Cisco 篇》第7章Cisco 路由器静态/RIP 和策略路由配置, 本章主要介绍的就是Cisco 路由器中的这两类比较简单的路由配置方法。并在本章最后介绍了Cisco 路由器中基于策略的路由配置方法。本节为大家介绍启用RIP 路由进程和RIP 参数的配置步骤及示例。 ? 标签:路由器 Cisco 路由器配置与管理完全手册-Cisco 篇 ?

以下示例是设置路由器应用一个值为10的度量偏移到流出路由度量中。 1.offset-list 21 out 10 以下示例是设置路由器应用一个值为10的度量偏移到从ethernet 0接口上学习到的路由度量上。

1.offset-list 21 in 10 ethernet 0 以下示例设置每隔5秒广播一次路由更新。如果一个路由器在15内没有被侦听到,则本地路由器将视为那个路由器不可达。再过15秒,就要发送抑制消息。在被抑制的最后,则到达那个路由器的路由将从路由表中删除。 1.router rip 2. timers basic 5 15 15 30 【经验之谈】表7-4所示的参数其实就是设置一个路由完整的生命周期中的各个阶段所需经过的时间值:路由的产生→路由的失效→路由的阻止→路由的删除。Update参数设置

的是路由更新包间发送的时间间隔,也就是每隔多少时间发送一次路由更新包。相当于路由的产生。Invalid参数设置的是在路由宣告无效后,可以继续用来转发数据包的时间段,相当于路由失效了。Holddown参数设置的是当路由过了无效期后,在不允许新的路由淹没原路由前所需等待的时间,相当于路由被阻止了。Flush参数是用来设置接受了新的更好的路由,在从路由表中删除原路由前所需等待的时间,相当于路由的删除。具体参见本章前面的7.3.2节。

二、RIP协议配置 1.实验内容:在H3C路由器上配置RIP协议 2.实验目的:掌握RIP协议的配置 3.实验环境: 4.实验步骤 此时再测试网络 在静态路由实验基础上,删除静态路由的配置之后再启动RIP协议,其配置命令和配置信息以及路由表信息如下: [RTA]undo ip route-static 202.0.1.0 255.255.255.0 192.0.0.2 [RTA]rip [RTA-rip]network all [RTB]undo ip route-static 202.0.0.0 255.255.255.0 192.0.0.1 [RTB]rip [RTB-rip]network all 查看RTA的配置信息和路由表,路由表显示如下: [RTA)display ip routing-table RoutingTables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBackO 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.1/0/24 Direct 0 0 192.0.0.2Serial0 192.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.2/32 Direct 0 0 192.0.0.2Serial0 202.0.0.1/0/24 Direct 0 0 202.0.0.1 Ethernet0

202.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 202.0.1.1/0/24 RIP 100 1 192.0.0.2Serial0 RTB路由器上的配置和RTA的配置相似。查看RTB的路由表信息如下: [RTB]display ip routing-table RoutingTables: Destination/Mask Proto Pref Metric Nexthop Interface 127.0.0.0/8 Direct 0 0 127.0.0.1 LoopBack0 127.0.0.1/32 Direct 0 0 127.0.0.1 LoopBack0 192.0.0.1/0/24 Direct 0 0 192.0.0.1 SerialO 192.0.0.1/32 Direct 0 0 192.0.0.1 SerialO 192.0.0.2/32 Direct 0 0 127.0.0.1 LoopBack0 202.0.0.1/0/24 RIP 100 1 192.0.0.1 Serial0 202.0.1.1/0/24 Direct 0 0 202.0.1.1 Ethernet0 202.0.1.1/32 Direct 0 0 127.0.0.1 LoopBack0 测试网络互通性,应该是全网互通的。如果不是,请检查配置。 现在我们可以看看RiP是怎样发现路由的,在系统视图下打开RiP协议调试开关,有如下信息在路由器之间传递,它们完成了路由的交换,并形成新的路由。 [RTA]info-center console //设置允许信息中心向Console口输出;[RTA]info-center console debugging //设置信息中心向Console口输出调试信息[RTA]debugging rip packet RIP:receive Response from l92.0.0.2 (Serial0) Packet:vers 1,cmd Response,length24 Dest 202.0.1.0,Metric 1 RIP:send from 202.0.0.1 t0 255.255.255.255(Ethemet0) Packet:vers 1,cmdResponse,length44 dest202.0.1·0,Metric2 dest 192.0.0.0,Metric 1 从上面的信息可以看到RIP协议版本为versionl,这是H3C路由器的默认版本。可以在接口视图下用rip version 2 multicast命令改变协议版本(注意:需要两端接口都执行该命令),再查看debug信息如下: [RTA]debugging rip packet RIP:sendfroml92.0.0.1t0224.0.0.9(Serial0) Packet:vers2,cmdResponse,length24 Dest 202.0.0.0 mask255.255.255.0 router 0.0.0.0 ,metric 1 RIP:receive Response from l92.0.0.2(Serial0) Packet:vers2,cmd Response,length24 Dest 202.0.1.0 mask 255.255.255.0,router0.0.0.0,metric 1 然后使用rip version 2 broadcast命令改变协议报文的发送方式为广播方式,查看debug 信息如下: [RTA]debugging rip packet RIP:send from l92.0.0.1t0255.255.255.255(Serial0) Packet:vers2,cmdResponse,length24 dest202.0.0.0 mask255.255.255.0,router0.0.0.0 ,metric 1

(华为)配置RIP版本示例 使用RIP之前,需要配置RIP的基本功能及版本。可以通过相关命令进行查看配置结果。 组网需求 如图1所示,要求在RouterA、RouterB、RouterC和RouterD的所有接口上使能RIP,并使用RIP-2进行网络互连。 图1 配置RIP版本组网图 配置思路 采用如下的思路配置RIP的版本: 1.配置各接口的IP地址,使网络可达。 2.在各路由器上使能RIP,配置RIP基本功能。 3.在各路由器上配置RIP-2版本,查看精确的子网掩码信息。 数据准备 为完成此配置例,需准备如下的数据: ?在RouterA上指定使能RIP的网段192.168.1.0。 ?在RouterB上指定使能RIP的网段192.168.1.0,172.16.0.0,10.0.0.0。 ?在RouterC上指定使能RIP的网段172.16.0.0。 ?在RouterD上指定使能RIP的网段10.0.0.0。 ?在RouterA、RouterB、RouterC和RouterD上配置RIP-2版本。 操作步骤 1.配置各接口的IP地址(略) 2.配置RIP基本功能 # 配置RouterA。

[RouterA-rip-1] network 192.168.1.0 [RouterA-rip-1] quit # 配置RouterB。 [RouterB] rip [RouterB-rip-1] network 192.168.1.0 [RouterB-rip-1] network 172.16.0.0 [RouterB-rip-1] network 10.0.0.0 [RouterB-rip-1] quit # 配置RouterC。 [RouterC] rip [RouterC-rip-1] network 172.16.0.0 [RouterC-rip-1] quit # 配置RouterD。 [RouterD] rip [RouterD-rip-1] network 10.0.0.0 [RouterD-rip-1] quit # 查看RouterA的RIP路由表。 [RouterA] display rip 1 route Route Flags: R - RIP A - Aging, S - Suppressed, G - Garbage-collect ------------------------------------------------------------------------- Peer 192.168.1.2 on GigabitEthernet1/0/0 Destination/Mask Nexthop Cost Tag Flags Sec 10.0.0.0/8 192.168.1.2 1 0 RA 14 172.16.0.0/16 192.168.1.2 1 0 RA 14 从路由表中可以看出,RIP-1发布的路由信息使用的是自然掩码。 3.配置RIP的版本 # 在RouterA上配置RIP-2。 [RouterA] rip [RouterA-rip-1] version 2 [RouterA-rip-1] quit # 在RouterB上配置RIP-2。

RIPv2配置实例 1.用户需求: 某企业总部计划和它的2个分公司联网。计划采用2条数字链路连接总部和分公司,并要求总部和分公司的IP网络段不能相同,并且划分广播域隔离广播;不采用三层交换设备;两个分公司联网后能够互相访问;总部和分公司联网后路由器能够自动学习。 2.方案分析与解决: 不采用三层交换技术,但要求采用数字链路,可以考虑用路由器。 3.网络拓扑: 4.规划网络地址: PC1:192.168.3.2 255.255.255.0 192.168.3.1 PC2:192.168.3.3 255.255.255.0 192.168.3.1 PC3:192.168.4.2 255.255.255.0 192.168.4.1 PC4:192.168.5.2 255.255.255.0 192.168.5.1 总部路由器A:F0/0:192.168.3.1 255.255.255.0 S1/0:192.168.1.1 255.255.255.0 S1/1:192.168.2.1 255.255.255.0 分公司路由器B:F0/0:192.168.4.1 255.255.255.0 S1/0:192.168.1.2 255.255.255.0 分公司路由器C:F0/0:192.168.5.1 255.255.255.0 S1/1:192.168.2.2 255.255.255.0 5.路由器配置: 总部A: Router>en Router#conf t Enter configuration commands, one per line. End with CNTL/Z. Router(config)#hostname routerA

教你如何轻松简单的配置动态路由RIP (利用packet tracer 5.0软件) 这是整个实验的拓补图: 接下来将讲解如何进行选择设备及连线,由于是基础教程,所以讲的比较详细,有基础的朋友可以直接跳过这几步 1.路由器的选择: 本实验中选择的事2811路由器,即如图所示: OK,用鼠标左键点击2811拖三个到操作台中(其实选择其他型号的路由器也行,不过这里选择比较通用的,每种路由器之间支持的功能其实还是有很大不同的,这里先不说~)

2.路由器串口的添加: 鼠标左键单击router0,在弹出的窗口中选择physical栏目组,选择win-2T项,如图所示: 此时窗口的右下方出现如图所示的串口接口 接下来将路由器的开关关上,开关如图所示:

然后就可以将右下方的串口拖到上方的空槽中去了,如上图所示: Ps:拖动至不同的空槽串口编号会有所不同,要注意 完成后就可以打开电源了。 将此步骤在router1,router2上复制两次就可以了,一个完整的实验用路由器就可以了 3.交换机的选择: 选295-24就可以了,如图所示: 先点击1框,在选择2框,

. 4.选择终端设备这里我们选择pc机吧~ 5.连线: (1)路由器间的连线:选择serial DTE 连接时就需要记住你说选择的接口编号了,因为等一下配置ip的时候要用到 (2)其他设备之间连线:采用直通线 6,.配端口: (1)路由器端口的配置:按照我拓补图上的ip或者自己定ip都可以,由于这里实在比较简单,就不详细说了,截个图形界面配置的截图给大家看看就ok了 如图所示:

将端口状态改为"on",如下图右上角

交换机路由协议——RIP配置 一组网需求: 1.所有设备运行RIP(Routing Information Protocol)路由协议,Pc-1和Pc-2之间可以互访; 2.此案例同时适用于以下产品: H3C 3500、3600、5600、5500-SI、3610、5510系列交换机。 二组网图: 三配置步骤: Switch-A配置: 1.创建(进入)vlan10,并将端口E0/2加入vlan10 [Switch-A]vlan 10 [Switch-A-vlan10]port Ethernet 0/2 2.创建(进入)vlan接口10,并配置IP地址 [Switch-A]interface Vlan-interface 10 [Switch-A-Vlan-interface10]ip add 10.1.1.2 255.255.255.0 3.指定vlan接口10的RIP协议版本为RIP-2 [Switch-A-Vlan-interface10]rip version 2 4.创建(进入)vlan100,并将端口E0/1加入vlan100 [Switch-A]vlan 100 [Switch-A-vlan100]port Ethernet 0/1 5.创建(进入)vlan接口100,并配置IP地址 [Switch-A]interface Vlan-interface 100 [Switch-A-Vlan-interface100]ip add 100.1.1.1 255.255.255.0

6.指定vlan接口100的RIP协议版本为RIP-2 [Switch-A-Vlan-interface100]rip version 2 7.启动并配置RIP协议 [Switch-A]rip [Switch-A-rip]network 10.1.1.0 [Switch-A-rip]network 100.1.1.0 8.关闭路由聚合功能 [Switch-A-rip]undo summary 9.向RIP协议中引入直连路由 [Switch-A-rip]import-route direct Switch-B配置: 1.创建(进入)vlan10,并将端口E0/2加入vlan10 [Switch-B]vlan 10 [Switch-B-vlan10]port Ethernet 0/2 2.创建(进入)vlan接口10,并配置IP地址 [Switch-B]interface Vlan-interface 10 [Switch-B-Vlan-interface10]ip add 10.1.1.1 255.255.255.0 3.指定vlan接口10的RIP协议版本为RIP-2 [Switch-B-Vlan-interface10]rip version 2 4.创建(进入)vlan200,并将端口E0/1加入vlan200 [Switch-B]vlan 200 [Switch-B-vlan200]port Ethernet 0/1 5.创建(进入)vlan接口200,并配置IP地址 [Switch-B]interface Vlan-interface 200 [Switch-B-Vlan-interface200]ip add 200.1.1.1 255.255.255.0 6.指定vlan接口100的RIP协议版本为RIP-2 [Switch-B-Vlan-interface200]rip version 2 7.启动并配置RIP协议 [Switch-B]rip [Switch-B-rip]network 10.1.1.0 [Switch-B-rip]network 200.1.1.0 8.关闭路由聚合功能

为路由器R1的 E0接口配置IP地址,SupapengR1>enable SupapengR1# SupapengR1#configure terminal Enter configuration commands, one per line. End with CNTL/Z. SupapengR1(config)#interface FastEthernet0/0 SupapengR1(config-if)#ip address 192.168.2.1 255.255.255.0 SupapengR1(config-if)#ip address 192.168.2.1 255.255.255.0 SupapengR1(config-if)# SupapengR2(config-if)#exit SupapengR2(config)#interface FastEthernet0/0 SupapengR2(config-if)#ip address 192.168.2.2 255.255.255.0 SupapengR2(config-if)#ip address 192.168.2.2 255.255.255.0 SupapengR2(config-if)# 为RT1和RT2配置动态路由协议rip SupapengR1# SupapengR1#configure terminal Enter configuration commands, one per line. End with CNTL/Z. SupapengR1(config)#router rip SupapengR1(config-router)#network 192.168.2.0 SupapengR1(config-router)#network 192.168.1.0 SupapengR1(config-router)# R2的rip配置: SupapengR2(config)#interface FastEthernet0/0 SupapengR2(config-if)# SupapengR2(config-if)#exit SupapengR2(config)#router rip

(华为)配置RIP 版本示例 使用RIP 之前,需要配置RIP 的基本功能及版本。可以通过相关命令进行查看配置结果。 组网需求 如图1所示,要求在 RouterA 、RouterB 、RouterC 和RouterD 的所有接口上使能 RIP ,并使用RIP-2 进行网络互连。 图1配置RIP 版本组网图 RoulerC GE2/0/0 172J6J 2/24 GE V-'C 担 R Q ut9 rB 192.168.1.1/24 GE2/0/0 GE3/0/0 172. W,1.1/24 10.1 1.2/24 配置思路 采用如下的思路配置RIP 的版本: 1. 配置各接口的IP 地址,使网络可达。 2. 在各路由器上使能RIP ,配置RIP 基本功能。 3. 在各路由器上配置RIP-2版本,查看精确的子网掩码信息。 数据准备 为完成此配置例,需准备如下的数据: ? 在RouterA 上指定使能RIP 的网段192.168.1.0 。 ? 在 RouterB 上指定使能 RIP 的网段 192.168.1.0,172.16.0.0,10.0.0.0 ? 在RouterC 上指定使能RIP 的网段172.16.0.0 。 ? 在RouterD 上指定使能RIP 的网段10.0.0.0 。 ? 在 RouterA 、RouterB 、RouterC 和 RouterD 上配置 RIP-2 版本。 操作步骤 1. 配置各接口的IP 地址(略) 2. 配置RIP 基本功能 # 配置 RouterA 。 [RouterA] rip [RouterA-rip-1] network 192.168.1.0 GE 1/0/0 192JSSJ.2/24 RouterA RouterD

1. 35配置RIP命令 1. 35.1配置相关命令 1. 35.1.1address-family(RIP) 要进入地址族子模式配置RIP等路由协议,使用地址族子模式命令 address-family,要删除配置路由协议的地址族子模式,使用该命令的 no形式。 address-family ipv4vrf vrf-name no address-family ipv4vrf vrf-name 【参数说明】 【缺省设置】 缺省不配置RIP协议的地址族。 【命令模式】 路由配置模式。 【使用指南】 使用address-family命令使设备进入地址族配置子模式(提示为: (config-router-af)#)。当第一次指定子模式关联的VRF时,RIP会创建 对应该VRF的RIP实例。在该子模式下,可以配置相应的VRF的RIP 路由信息。 要删除地址族配置子模式并返回路由配置模式,使用 exit-address-family或者exit命令。 【举例】 以下的配置例子,创建了一个名为vpn1的VRF,并为该vrf创建相应的 RIP实例。 Ruijie(config)# ip vrf vpn1 Ruijie(config-vrf)# exit Ruijie(config)# interface GigabitEthernet 1/0 Ruijie(config-if)# ip vrf forwarding vpn1

Ruijie(config-if)# ip address 192.168.1.1 255.255.255.0 Ruijie(config)# router rip Ruijie(config-router)# address-family ipv4 vrf vpn1 Ruijie(config-router-af)# network 192.168.1.0 Ruijie(config-router-af)# exit-address-family 【相关命令】 【平台说明】 【版本说明】 2. 35.1.2auto-summary (RIP) 要启用RIP路由自动汇总功能,用路由协议配置命令auto-summary。 该命令的no形式关闭路由自动汇总功能。 auto-summary no auto-summary 【参数说明】 无。 【缺省设置】 缺省启用自动汇总功能。 【命令模式】 路由进程配置模式。 【使用指南】 RIP路由自动汇总,就是当子网路由穿越有类网络边界时,将自动汇总成 有类网络路由。RIPv1和RIPv2缺省情况下将进行路由自动汇总。 RIP的路由自动汇总功能,提高了网络的伸缩性和有效性。如果有汇总路 由存在,在路由表中将看不到包含在汇总路由内的子路由,这样可以大大 缩小路由表的规模。 通告汇总路由会比通告单独的每条路由将更有效率,主要有以下因素: 当查找RIP数据库时,汇总路由会得到优先处理;

华为rip配置实例及使用filter-policy过滤路由 作者:救世主220 实验日期:2015.6.26 实验拓扑如下: AR1配置: [AR1]dis cur [V200R003C00] sysname AR1 # interface GigabitEthernet0/0/0 ip address 10.0.12.1 255.255.255.0 # interface LoopBack0 ip address 10.0.1.1 255.255.255.0 # rip 1 undo summary version 2 network 10.0.0.0 AR2配置 [AR2]dis current-configuration [V200R003C00] sysname AR2 # acl number 2000 rule 5 permit source 10.0.3.3 0 # interface GigabitEthernet0/0/0 ip address 10.0.12.2 255.255.255.0 # interface GigabitEthernet0/0/1 ip address 10.0.23.2 255.255.255.0 # interface LoopBack0

ip address 10.0.2.2 255.255.255.0 # rip 1 undo summary version 2 network 10.0.0.0 filter-policy 2000 import GigabitEthernet0/0/1 AR3配置: [AR3]dis current-configuration [V200R003C00] # sysname AR3 # interface GigabitEthernet0/0/0 ip address 10.0.23.3 255.255.255.0 # interface LoopBack0 ip address 10.0.3.3 255.255.255.0 # rip 1 undo summary version 2 network 10.0.0.0 测试结果: 注意:在AR2上做了过滤策略filter-policy前后AR1的路由表中路由条目的变化以及AR1与AR3的loopback 0的连通性。

案例18:配置RIP 1. 案例目标 通过本案例,你可以掌握如下技能: 1)理解RIP 2)掌握配置RIP的过程 3)掌握配置RIP的命令 4)学习观察调试信息 5)理解RIP路由协议的配置信息 2. 设备与拓扑 设备:4台PC-PT,1台2811路由器,3台1841路由器,1台AccessPoint-PT-N 无线访问点,3台Laptop-PT,1台Linksys-300WRN。 拓扑:如下图。

3. 操作步骤 步骤1:此案例是案例17的继续,请打开案例17保存的拓扑文件。 步骤2:配置Corp路由器 1)配置RIPv1 Corp#conf t Enter configuration commands, one per line. End with CNTL/Z. Corp(config)#router rip Corp(config-router)#network 10.0.0.0 Corp(config-router)#end %SYS-5-CONFIG_I: Configured from console by console Corp# //注意:此时其他路由器尚未启动RIP,故Corp路由器中不会有RIP路 //由。 2)验证路由表 Corp#sh ip ro //输出从略 步骤3:配置R1 1)配置RIPv1 R1#conf t Enter configuration commands, one per line. End with CNTL/Z. R1(config)#router rip R1(config-router)#network 10.0.0.0 R1(config-router)#end %SYS-5-CONFIG_I: Configured from console by console R1# 2)验证路由表 R1#sh ip ro …… 10.0.0.0/24 is subnetted, 12 subnets

实验十四 RIP路由配置 动态路由协议是指各路由器间通过路由选择算法动态地交互学习的路由信息,动态地生成、维护相应的路由表。动态路由协议按照算法的不同有很多种,能适应的网络规模也不尽相同。在中小规模的网络中,最常见的是使用距离矢量算法的RIP协议。 RIP的全称是Routing Information Protocol,属IGP(内部网关协议),采用Bellman-Ford算法。RIP version 1标准文件是RFC1058,RIP Version 2的标准文档是RFC2453。 一、实验目的 1. 了解RIP协议的工作原理 2. 掌握RIP协议的配置方法 二、原理概述 RIP(Routing Information Protocol)协议的中文名称是路由信息协议,采用距离矢量算法,是一个比较早期的路由协议,最大的特点是配置和管理非常简单,在中小规模的网络中比较常见。它只根据经过路由器的跳数(HOP)来计算机路由的花费,而不考虑链路的带宽、时延、流量等复杂的因素。RIP通过广播UDP报文来交换路由信息,每30秒发送一次路由信息更新。RIP协议的路由范围有限,只能支持直径为15个路由器的网络内进行路由。 RIP协议有两个版本RIP v1和RIP v2。RIP v1属于有类路由协议,不支持VLSM (变长子网掩码),RIP V1是以广播的形式进行路由信息的更新的;RIP v2属于无类路由协议,支持VLSM (变长子网掩码);RIP v2是以组播的形式进行路由信息的更新的,组播地址是224.0.0.9。RIPv2还支持基于端口的认证,提高网络的安全性。 RIP的基本配置命令: ip classless //让路由器支持无类编址,RIPv1是不支持无类IP 编址的。 show ip route //显示路由表信息 show ip protocol //查看路由器中所启用的路由计算协议 no network // 从RIP协议中移除某个网络

使用RIP之前,需要配置RIP的基本功能及版本。可以通过相关命令进行查看配置结果。 组网需求 如图1所示,要求在Router A、Router B、RouterC和RouterD的所有接口上使能RIP,并使用RIP-2进行网络互连。 图1配置RIP版本组网图 配置思路 采用如下的思路配置RIP的版本: 1.配置各接口的IP地址,使网络可达。 2.在各路由器上使能RIP,配置RIP基本功能。 3.在各路由器上配置RIP-2版本,查看精确的子网掩码信息。 数据准备 为完成此配置例,需准备如下的数据: 在RouterA上指定使能RIP的网段192.168.1.0。 在RouterB上指定使能RIP的网段192.168.1.0,172.16.0.0,10.0.0.0。 在RouterC上指定使能RIP的网段172.16.0.0。 在RouterD上指定使能RIP的网段10.0.0.0。 在Router

A、Router B、RouterC和RouterD上配置RIP-2版本。操作步骤 1.配置各接口的IP地址(略) 2.配置RIP基本功能 #配置RouterA。 [RouterA] rip #配置RouterB。 [RouterB] rip [RouterB-rip-1] quit #配置RouterC。 [RouterC] rip [RouterC-rip-1] quit #配置RouterD。 [RouterD] rip [RouterD-rip-1] quit #查看RouterA的RIP路由表。[RouterA]display rip 1 route Route Flags:

实验5 动态路由协议RIP与OSPF的配置 实验学时:2 一、实验目的 1、熟悉CISCO IOS和CLI命令模式的使用; 2、了解和掌握路由器基本配置命令的使用; 3、掌握动态路由协议的配置; 4、掌握VLAN中路由器的设置; 3.掌握RIP与OSPF路由协议及其配置。 二、实验设备与环境 Windows 2000 Server/Advance Server主机局域网、CISCO Catalyst 2950交换机和2600系列路由器,Cisco Packet Tracer 7.0软件。 三、预备知识 3.1动态路由配置 两个重要的命令用于配置动态路由:router和network。Router命令启动一个路由选择进程,格式:router(config)#router protocol [keywork],network命令是每个IP路由选择进程所需要的。 router(config-router)#network network-number 参数如下表: 3.2 RIP协议配置 RIP的关键特点如下: ·它是一个距离矢量路由选择协议; ·选用跳计数作为路由选择的度量标准; ·跳计数允许的最大值是15; 缺省情况下,路由选择的更新数据每30秒种广播一次。第一版本不支持子网划分,如使用子网划分应使用第二版本(命令:version 2)。 router rip命令选择RIP作为路由协议: Router(config)#router rip network命令指定基于NIC网络号码,选择直连的网络: Router(config-router)#network network-number 路由选择进程将接口与适合的地址相关联,并且开始在规定的网络上处理数据包。

华为配置R I P版本示例 Document serial number【UU89WT-UU98YT-UU8CB-UUUT-UUT108】

(华为)配置RIP版本示例 使用RIP之前,需要配置RIP的基本功能及版本。可以通过相关命令进行查看配置结果。组网需求 如图1所示,要求在RouterA、RouterB、RouterC和RouterD的所有接口上使能RIP,并使用RIP-2进行网络互连。 图1 配置RIP版本组网图 配置思路 采用如下的思路配置RIP的版本: 1.配置各接口的IP地址,使网络可达。 2.在各路由器上使能RIP,配置RIP基本功能。 3.在各路由器上配置RIP-2版本,查看精确的子网掩码信息。 数据准备 为完成此配置例,需准备如下的数据:

在RouterA上指定使能RIP的网段。 在RouterB上指定使能RIP的网段,,。 在RouterC上指定使能RIP的网段。 在RouterD上指定使能RIP的网段。 在RouterA、RouterB、RouterC和RouterD上配置RIP-2版本。操作步骤 1.配置各接口的IP地址(略) 2.配置RIP基本功能 # 配置RouterA。 [RouterA] rip [RouterA-rip-1] network [RouterA-rip-1] quit # 配置RouterB。 [RouterB] rip [RouterB-rip-1] network [RouterB-rip-1] network [RouterB-rip-1] network [RouterB-rip-1] quit # 配置RouterC。

拓扑图: RTA RTB Lookback0 192.168.0.1/24 首先配置RTA : [RTA]interface LoopBack 0 [RTA-LoopBack0]ip address 192.168.0.1 32 [RTA-LoopBack0]quit [RTA]interface Serial 1/0 [RTA-Serial1/0]ip address 192.168.1.1 24 [RTA-Serial1/0]quit [RTA]rip [RTA-rip-1]version 2 [RTA-rip-1]undo summary [RTA-rip-1]network 192.168.0.0 [RTA-rip-1]network 192.168.1.0 [RTA-rip-1]quit [RTA]interface Serial 1/0 [RTA-Serial1/0]rip authentication-mode m [RTA-Serial1/0]rip authentication-mode md5 ? rfc2082 RFC 2082 MD5 authentication packet format type rfc2453 RFC 2453 MD5 authentication packet format type [RTA-Serial1/0]rip authentication-mode md5 rfc24 [RTA-Serial1/0]rip authentication-mode md5 rfc2453 ? STRING<1-16>/<24> Plain text<1-16>/cipher<24> text password string [RTA-Serial1/0]rip authentication-mode md5 rfc2453 abcdef 接着配置RTB : [RTB]interface LoopBack 0 [RTB-LoopBack0]ip address 192.168.2.1 32 [RTB-LoopBack0]quit [RTB]interface Serial 1/0 [RTB-Serial1/0]ip address 192.168.1.2 24 [RTB-Serial1/0] %Oct 11 13:18:55:297 2011 RTB IFNET/4/UPDOWN: Protocol PPP IPCP on the interface Serial0/2/0 is UP [RTB-Serial1/0]quit [RTB]rip [RTB-rip-1]version 2

A 区:A1与A2使用静态路由,A2/A3/A4/A5/A6/A7A 使用OSPF ,A2把静态路由重分布到OSPF 。 B 区:B1/B2/B3/B4/B5使用RIP ,B5与B6使用OSPF 。互联:A7与B6使用BGP 1.网络概况:A 区使用OSPF ,B 区使用RIP(packet tracer 中rip 不支持redistribute BGP ,增加一台路由器,在边界使用OSPF 过渡,A 区与B 区之间使用BGP 。 2.IP 地址分布: 区域设备名称IP 地址loopback 地址 接口区域设备名称IP 地址loopback 地址 接口A A1 172.30.100.1/24 E1/0 B B1 172.30.200.1/24 E1/0 A A110.1.1.1/30E1/1 B B110.10.2.1/30E1/1A A210.10.1.2/30 2.2.2.2E1/0B B210.10.2.2/30E1/0A A2 10.10.1.9/30 2.2.2.2 E1/1 B B2 10.10.2.5/30 E1/1 A A210.10.1.5/30 2.2.2.2E1/2 B B210.10.2.9/30E1/2A A310.10.1.6/30 3.3.3.3E1/0B B310.10.2.6/30E1/0A A3 10.10.1.13/30 3.3.3.3 E1/1 B B3 10.10.2.13/30 E1/1 A A410.10.1.10/30 4.4.4.4E1/0 B B410.10.2.10/30E1/0A A410.10.1.17/30 4.4.4.4E1/1B B410.10.2.17/30E1/1A A5 10.10.1.14/30 5.5.5.5 E1/0 B B5 10.10.2.14/30 E1/0 A A510.10.1.21/30 5.5.5.5E1/1 B B510.10.2.18/30E1/1A A510.10.1.25/30 5.5.5.5E1/2B B510.10.2.21/309.9.9.9E1/2A A6 10.10.1.18/30 6.6.6.6 E1/0 B B6 10.10.2.22/30 8.8.8.8 E1/1 A A610.10.1.22/30 6.6.6.6E1/1 B B610.10.1.30/308.8.8.8E1/0 A A710.10.1.26/307.7.7.7E1/0A A7 10.10.1.29 7.7.7.7 E1/1 3.网络拓扑图: 4.设备配置A 区:A1: Router>en Router#config Configuring from terminal, memory, or network [terminal]? Enter configuration commands, one per line. End with CNTL/Z.Router(config)#hostname a1 A1(config)#interface ethernet 1/0 A1(config-if)#ip add 172.30.100.1 255.255.255.0A1(config-if)#no shutdown A1(config-if)#exit CISCO-OSPF-RIP-BGP 2016年11月13日 10:33

目录 1 RIP配置................................................................................................................................................ 1-1 1.1 简介 .................................................................................................................................................. 1-1 1.1.1 RIP工作机制 .......................................................................................................................... 1-1 1.1.2 RIP的启动和运行过程............................................................................................................ 1-2 1.1.3 RIP的版本.............................................................................................................................. 1-3 1.1.4 RIP的报文格式....................................................................................................................... 1-3 1.1.5 支持的RIP特性..................................................................................................................... 1-5 1.1.6 协议规范 ................................................................................................................................ 1-5 1.2 配置RIP的基本功能 ........................................................................................................................ 1-5 1.2.1 配置准备 ................................................................................................................................ 1-5 1.2.2 配置RIP的基本功能.............................................................................................................. 1-5 1.3 配置RIP路由特性............................................................................................................................ 1-7 1.3.1 配置接口附加度量值 .............................................................................................................. 1-7 1.3.2 配置RIP-2路由聚合.............................................................................................................. 1-8 1.3.3 禁止RIP接收主机路由.......................................................................................................... 1-9 1.3.4 配置RIP发布缺省路由.......................................................................................................... 1-9 1.3.5 配置RIP对接收/发布的路由进行过滤 ................................................................................. 1-10 1.3.6 配置RIP协议优先级............................................................................................................ 1-11 1.3.7 配置RIP引入外部路由........................................................................................................ 1-11 1.4 调整和优化RIP网络 ...................................................................................................................... 1-11 1.4.1 配置RIP定时器................................................................................................................... 1-11 1.4.2 配置水平分割和毒性逆转..................................................................................................... 1-12 1.4.3 配置最大等价路由条数......................................................................................................... 1-13 1.4.4 配置RIP-1报文的零域检查 ................................................................................................. 1-13 1.4.5 配置源地址检查.................................................................................................................... 1-13 1.4.6 配置RIP-2报文的认证方式 ................................................................................................. 1-14 1.4.7 配置RIP邻居....................................................................................................................... 1-14 1.4.8 配置RIP和MIB绑定........................................................................................................... 1-15 1.4.9 配置RIP报文的发送速率 .................................................................................................... 1-15 1.5 RIP显示和维护 ............................................................................................................................... 1-15 1.6 RIP典型配置举例............................................................................................................................ 1-16 1.6.1 配置RIP的版本................................................................................................................... 1-16 1.6.2 配置RIP引入外部路由........................................................................................................ 1-18 1.6.3 配置RIP接口附加度量值 .................................................................................................... 1-20 1.6.4 配置RIP发布聚合路由........................................................................................................ 1-22 1.7 常见配置错误举例........................................................................................................................... 1-24 1.7.1 收不到邻居的RIP更新报文................................................................................................. 1-24 1.7.2 RIP网络发生路由振荡.......................................................................................................... 1-24

相关文档
相关文档 最新文档