rip中的连续子网以及不连续子网
| RIPv1 | RIPv2 |
| 距离矢量2 | 距离矢量 |
| 最大跳计数15 | 最大跳计数15 |
| 有类的 | 无类的 |
| 基于广播的 | 基于组播224.0.09 |
| 不支持VLSM | 支持VLSM |
| 无认证 | 允许MD5认证 |
| 不支持不连续子网 | 支持不连续子网 |
下面我们来认识一下什么叫做有类以及无类,有类就是A类,B类,C类,D类网络,没有划分子网。无类就是划分了子网。
我们通过一个例子来说明,比如A类的地址1.1.1.1 子网掩码 255.255.255.0 这是子网,则它的有类网络是1.0.0.0 ,掩码255.0.0.0.无类网络就是1.1.1.0,掩码255.255.255.0.
不连续的子网?
什么叫做不连续的子网呢,不连续的子网就是,中间有其它网络来分开。比如下面该图所显示一样

在rip v1 关闭自动汇总,还是不能学习到172.16.10.1 和172.16.20.1的网络。
R7
!
interface Loopback0
ip address 172.16.10.1 255.255.255.0
!
interface GigabitEthernet0/0
ip address 192.168.1.1 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface GigabitEthernet0/2
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
network 172.16.0.0
network 192.168.1.0
no auto-summary
!
ip classless
!
ip flow-export version 9
!
!
!
!
!
!
!
line con 0
!
line aux 0
!
line vty 0 4
login
!
!
!
R6
ip cef
no ipv6 cef
!
!
!
!
license udi pid CISCO2911/K9 sn FTX1524JN31
!
!
!
!
!
!
!
!
!
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface Loopback0
ip address 1.1.1.1 255.255.255.0
!
interface GigabitEthernet0/
ip address 192.168.1.2 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
ip address 192.168.2.1 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
network 1.0.0.0
network 192.168.1.0
network 192.168.2.0
no auto-summary
!
ip classless
!
ip flow-export version
!
!
!
!
!
!
!
line con
!
line aux
!
line vty
login
!
!
!
end
R8
hostname Router
!
!
!
!
!
!
!
!
ip cef
no ipv6 cef
!
!
!
!
license udi pid CISCO2911/K9 sn FTX1524CD62
!
!
!
!
!
!
!
!
!
!
!
spanning-tree mode pvst
!
!
!
!
!
!
interface Loopback0
ip address 172.16.30.1 255.255.255.0
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface GigabitEthernet0/
ip address 192.168.2.2 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
network 172.16.0.0
network 192.168.2.0
no auto-summary
!
ip classless
!
ip flow-export version
!
!
!
!
!
!
!
line con
!
line aux
!
line vty
login
!
使用RIPv2 之后就可以支持不连续子网,这时候就能够学习到两边172.16.0.0 的子网了。
变为RIP v2的配置
R7
interface Loopback0
ip address 172.16.10.1 255.255.255.0
!
interface GigabitEthernet0/
ip address 192.168.1.1 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
version
network 172.16.0.0
network 192.168.1.0
no auto-summary
!
ip classless
!
ip flow-export version
!
!
!
!
!
!
!
line con
!
line aux
!
line vty
login
!
!
!
end
R6
interface Loopback0
ip address 1.1.1.1 255.255.255.0
!
interface GigabitEthernet0/
ip address 192.168.1.2 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
ip address 192.168.2.1 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
version
network 1.0.0.0
network 192.168.1.0
network 192.168.2.0
no auto-summary
!
ip classless
!
ip flow-export version
!
!
!
!
!
!
!
line con
!
line aux
!
R8
interface Loopback0
ip address 172.16.30.1 255.255.255.0
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface GigabitEthernet0/
ip address 192.168.2.2 255.255.255.0
duplex auto
speed auto
!
interface GigabitEthernet0/
no ip address
duplex auto
speed auto
shutdown
!
interface Vlan1
no ip address
shutdown
!
router rip
version
network 172.16.0.0
network 192.168.2.0
no auto-summary
!
ip classless
!
ip flow-export version
!
!
!
!
!
!
!
line con
这时候你再查看路由表就可以看到所有路由都能学习到了。
rip中的连续子网以及不连续子网的更多相关文章
- RIP协议两个版本对不连续子网的支持情况实验
一.连续子网与不连续子网 我们经常见到说RIPv1不支持不连续子网,仅支持连续子网,那么什么是连续子网,什么是不连续子网呢? l 不连续子网:指在一个网络中,某几个连续由同一主网划分的子网在中间被多 ...
- RIP协议两个版本号对不连续子网的支持情况实验
(增加时注明"会员咨询")
- K:求取数组中最大连续子序列和的四个算法
相关介绍: 求取数组中最大连续子序列和问题,是一个较为"古老"的一个问题.该问题的描述为,给定一个整型数组(当然浮点型也是可以的啦),求取其下标连续的子序列,且其和为该数组的所有 ...
- Light oj 1138 - Trailing Zeroes (III) 【二分查找 && N!中末尾连续0的个数】
1138 - Trailing Zeroes (III) problem=1138"> problem=1138&language=english&type=pdf&q ...
- 如何在DevOps中实施连续测试
在过去的十年中,对软件开发的需求已急剧发展.软件已成为公司获得竞争优势的关键优势,特别是如果您的公司属于SaaS范畴.通过在SDLC中实施瀑布等传统流程,组织现在正在向敏捷过渡,以便以更快的速度在市场 ...
- Vbox中多台虚拟机搭建简单子网
一.目标拓扑结构: 要使192.168.31.1和192.168.32.1互相ping通. 二.步骤及问题: 1.路由器配置 SEED_Router配置IP并开启路由转发协议: ifconfig et ...
- 简述ARP请求过程(同一子网和不同子网)
1. 同一子网 主机A在准备构造链路层以太网帧头时,首先根据目的IP去查找ARP表,如果找到对应项,则直接得到目的MAC地址,如果没有查到才执行上面所说的ARP广播请求.这样做是为了最大限度地减少广播 ...
- Hive中抽取连续多天登录用户
昨天群上有人发个阿里的面试题,题目描述大概如下: 数据源:用户登录表,只有俩个字段,uid和dt 试用HQL抽取出连续登录了K天的用户uid 第一个想法就是直接用一个UDF解决,按uid分组,把dt收 ...
- js返回一组日期中最近连续的天数
用js获取一组日期(并把当天算入)中连续的天数 刚开始可能想到单纯的比较日期大小判断连续, 而又有大小月,平闰年这些因素,还是时间戳来的安全; 首先得有一组日期,比如: var arr = [ '20 ...
随机推荐
- 根据不同浏览器使用不同的css文件
代码: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3. ...
- easyui更换主题之后出现validatebox的验证提示信息显示跑偏的解决方案
在easyui中更换主题为非default的主题,有的主题会出现如下图所示的情况,验证提示信息的提示内容跑到了下面. 现在说下原因和解决方案: 原因:原因是easyui对某些主题没有进行这个样式的设置 ...
- [Python爬虫] 之三:Selenium 调用IEDriverServer 抓取数据
接着上一遍,在用Selenium+phantomjs 抓取数据过程中发现,有时候抓取不到,所以又测试了用Selenium+浏览器驱动的方式:具体代码如下: #coding=utf-8import os ...
- FrameWork数据权限浅析1之基于手工修改模型实现行级数据安全
1:环境 Cognos10.2.0,Oracle 2:实现过程 在设置Framework数据级别权限的时候,通常用到的就是在FM的设置数据安全的地方添加安全过滤器,如下图 step1:选中部门维度表→ ...
- [React] Ensure all React useEffect Effects Run Synchronously in Tests with react-testing-library
Thanks to react-testing-library our tests are free of implementation details, so when we refactor co ...
- Visual Studio 2013 Update2
下载: http://download.microsoft.com/download/6/7/8/6783FB22-F77D-45C5-B989-090ED3E49C7C/vs2013.2.iso
- (剑指Offer)面试题42:翻转单词顺序
题目: 输入一个英文句子,翻转句子中单词的顺序,但单词内字符的顺序不变.为简单起见,标点符号和普通字母一样处理. 例如输入字符串“I am a student.”,则输出"student. ...
- C#基础视频教程3.2 常见控件类型和使用方法
这一部分我们介绍如何使用第三方的控件,我们前面一节介绍了使用微软提供的官方控件,比较中规中矩,而且也不用担心稳定性.但是很多时候我们还是会希望用第三方的控件让自己的软件更美观,更独特. 就单纯的按钮, ...
- UNIX网络编程读书笔记:pselect函数
函数原型 pselect函数是由POSIX发明的,其原型如下: #include <sys/select.h> #include <signal.h> #include < ...
- xmu 1125 越野车大赛(公式推导&&三分)(中等)
xmu 1125.越野车大赛 Description TheBeet正在參加一场越野车大赛.比赛的场地如右图:共分三块.每一块地面的长宽均为N与M,但地表情况不同.越野车在这段路面上的最快速度也不同. ...