IS-IS

二、IS-IS中的DIS与OSPF中的DR

Level-1和Level-2的DIS是分别选举的,用户可以为不同级别的DIS选举设置不同的优先级。DIS的选举规则如下:DIS优先级数值最大的被选为DIS。如果优先级数值最大的路由器有多台,则其中MAC地址最大的路由器会成为DIS。DIS发送Hello PDU的时间间隔是普通路由器的1/3,这样可以确保DIS出现故障时能够被更快速地被发现。IS-IS中DIS与OSPF协议中DR(Designated Router)的区别:在IS-IS广播网中,优先级为0的路由器也参与DIS的选举,而在OSPF中优先级为0的路由器则不参与DR的选举。在IS-IS广播网中,当有新的路由器加入,并符合成为DIS的条件时,这个路由器会被选中成为新的DIS,原有的伪节点被删除。此更改会引起一组新的LSP泛洪。而在OSPF中,当一台新路由器加入后,即使它的DR优先级值最大,也不会立即成为该网段中的DR。在IS-IS广播网中,同一网段上的同一级别的路由器之间都会形成邻接关系,包括所有的非DIS路由器之间也会形成邻接关系。而在OSPF中,路由器只与DR和BDR建立邻接关系。

伪节点ID:当该参数不为零时,表示该LSP为伪节点生成。

CSNP包含该设备LSDB中所有的LSP摘要,路由器通过交互 CSNP来判断是否需要同步LSDB。在广播网络上,CSNP由DIS定期发送(缺省的发送周期为10秒)

三、实验配置

ISIS 刷新时间 15分钟

ISIS 老化时间 20分钟

level1路由计算:

R1是Level-1路由器,只维护Level-1 LSDB,该LSDB中包含同属一个区域的R2及R3以及R1自己产生的Level-1 LSP。

R1根据LSDB中的Level-1 LSP计算出Area 49.0123内的拓扑,以及到达区域内各个网段的路由信息。

R2及R3作为Area 49.0123内的Level-1-2路由器,会在它们向该区域下发的Level-1 LSP中设置ATT标志位,用于向区域内的Level-1路由器宣布可以通过自己到达其他区域。 R1作为Level-1路由器,会根据该ATT标志位,计算出指向R2或R3的默认路由。

python 复制代码
[r1]isis 100
[r1-isis-100]network-entity 49.0123.0000.0000.0001.00
[r1-isis-100]is-level level-1
[r1-isis-100]q
[r1]int  g0/0/0
[r1-GigabitEthernet0/0/0]isis enable  100
[r1-GigabitEthernet0/0/0]q
[r1]dis ip routing-table 
[R2]isis 100
[R2-isis-100]network-entity 49.0123.0000.0000.0002.00
[R2-isis-100]is-level level-1-2
[R2-isis-100]q
[R2]int g0/0/0
[R2-GigabitEthernet0/0/0]isis enable  100
[R2-GigabitEthernet0/0/0]q
[R2]int g0/0/1
[R2-GigabitEthernet0/0/1]isis enable 100
[R2-GigabitEthernet0/0/1]q
[R3]isis 100
[R3-isis-100]network-entity 49.0123.0000.0000.0003.00 
[R3-isis-100]is-level level-1-2
[R3-isis-100]q
[R3]int g0/0/0
[R3-GigabitEthernet0/0/0]isis enable  100
[R3-GigabitEthernet0/0/0]q
[R3]int g0/0/1
[R3-GigabitEthernet0/0/1]isis enable 100
[R3-GigabitEthernet0/0/1]q
[R4]isis 100
[R4-isis-100]network-entity 49.0045.0000.0000.0004.00
[R4-isis-100]is-level level-2
[R4-isis-100]q
[R4]int g0/0/0
[R4-GigabitEthernet0/0/0]isis enable 100
[R4-GigabitEthernet0/0/0]q
[R4]int g0/0/1
[R4-GigabitEthernet0/0/1]isis enable 100
[R4-GigabitEthernet0/0/1]q
[R4]int g0/0/2
[R4-GigabitEthernet0/0/2]isis enable 100
[R4-GigabitEthernet0/0/2]q
[R5]isis 100
[R5-isis-100]network-entity 49.0045.0000.0000.0005.00
[R5-isis-100]is-level level-2
[R5-isis-100]q
[R5]int g0/0/0
[R5-GigabitEthernet0/0/0]isis enable 100
[R5-GigabitEthernet0/0/0]q
[R5]isis 100
[R5-isis-100]import-route direct 
[R4]int  g0/0/1
[R4-GigabitEthernet0/0/1]isis cost 15  //修改接口cost值
[R4-GigabitEthernet0/0/1]q
[R4]dis ip routing-table 

路由渗透:

缺省情况下,Level-1-2路由器不会将到达其他区域的路由通告本Level-1区域中。通过路由渗透,可以将区域间路由通过Leve-1-2路由器传递到Level-1区域,此时Leve-1路由器可以学习到其他区域的详细路由,从而计算出最优路径。

python 复制代码
[R3]isis 100
[R3-isis-100]import-route isis level-2 into level-1 


[r1]dis isis brief 
ISIS Protocol Information for ISIS(100)
---------------------------------------
SystemId: 0000.0000.0001      System Level: L1    
Area-Authentication-mode: NULL
Domain-Authentication-mode: NULL
Ipv6 is not enabled
ISIS is in invalid restart status
ISIS is in protocol hot standby state: Real-Time Backup
Interface: 192.168.123.1(GE0/0/0)
Cost: L1 10        L2 10                Ipv6 Cost: L1 10   L2 10   
State: IPV4 Up                          IPV6 Down
Type: BROADCAST                         MTU: 1497      
Priority: L1 64   L2 64   
Timers:     Csnp: L1 10    L2 10    ,Retransmit: L12 5   , Hello: L1 10 L2 10  ,
Hello Multiplier: L1 3    L2 3     , LSP-Throttle Timer: L12 50  
[R2]dis isis peer 
Peer information for ISIS(100)
System Id   Interface    Circuit Id    State HoldTime Type     PRI
0000.0000.0001  GE0/0/0            0000.0000.0003.01         Up          22s                       L1           64 
0000.0000.0003  GE0/0/0            0000.0000.0003.01         Up            7s                       L1(L1L2)  64 
0000.0000.0003  GE0/0/0            0000.0000.0003.01           Up            8s                     L2(L1L2)  64 
0000.0000.0004  GE0/0/1            0000.0000.0004.01            Up            7s                     L2           64 
备注:查看ISIS 邻居关系的时候,circuit .id 为当前邻居关系中 DIS 
[r1]dis isis lsdb 
Database information for ISIS(100)
----------------------------------
Level-1 Link State Database
LSPID    Seq Num    Checksum   Holdtime   Length  ATT/P/OL
0000.0000.0001.00-00* 0x00000010   0xa07f          582           70      0/0/0   
0000.0000.0002.00-00  0x00000013   0xafb8          959           112     1/0/0   
0000.0000.0003.00-00  0x00000013   0xa1b7          879           86      1/0/0   
0000.0000.0003.01-00  0x0000000d   0x5697          879           66      0/0/0   
备注:systemID 后面的01 为非0时 ,表明此条LSP由 DIS产生 ,*表示当前设备自己产生的LSP
[R3]dis isis interface 
Interface information for ISIS(100)
-----------------------------------
Interface       Id      IPV4.State          IPV6.State      MTU  Type  DIS   
GE0/0/0         001         Up                 Down         1497 L1/L2 Yes/Yes
GE0/0/1         002         Up                 Down         1497 L1/L2 No/Yes
备注: 通过此条命令,能够看到当前接口在L1 邻居关系上是不是DIS  ,以及当前接口在L2邻居关系上是不是DIS  
配置DIS:
[r1]interface g0/0/0
[r1-GigabitEthernet0/0/0]isis dis-priority 127
[r1]dis isis interface 
Interface information for ISIS(100)
-----------------------------------
Interface       Id      IPV4.State          IPV6.State      MTU  Type  DIS   
GE0/0/0         001         Up                 Down         1497 L1/L2 Yes/No 
修改网络类型:
[R4]int g0/0/2
[R4-GigabitEthernet0/0/2]isis circuit-type p2p
[R4-GigabitEthernet0/0/2]q
[R4]dis isis brief 
ISIS Protocol Information for ISIS(100)
---------------------------------------
SystemId: 0000.0000.0004      System Level: L2    
Area-Authentication-mode: NULL
Domain-Authentication-mode: NULL
Ipv6 is not enabled
ISIS is in invalid restart status
ISIS is in protocol hot standby state: Real-Time Backup
Interface: 192.168.45.4(GE0/0/2)
Cost: L1 10        L2 10                Ipv6 Cost: L1 10   L2 10   
State: IPV4 Up                          IPV6 Down
Type: P2P                               MTU: 1497      
接口修改邻居关系: 
R2 和R3都是L1/2路由器类型,默认建立 L1/L2邻居关系  ,现在路由器类型不能表(因为为边界设备),R2和R3只想建立L1的邻居关系,可以修改接口的邻居关系
[R2]int g0/0/0
[R2-GigabitEthernet0/0/0]isis circuit-level level-1
[R3]int g0/0/0
[R3-GigabitEthernet0/0/0]isis circuit-level level-1
[R3]dis isis peer 

Isis 认证:

接口认证 :接口下做认证

Hello报文使用的认证密码保存在接口下,发送带认证TLV的认证报文,互相连接的路由器接口必须配置相同的口令。
区域认证 :区域内所有L1 路由器做认证

区域内的每一台L1路由器都必须使用相同的认证模式和具有共同的钥匙串。
路由域认证 :区域内所有L1/ L1/2路由器做认证

IS-IS域内的每一台L2和L1/L2类型的路由器都必须使用相同模式的认证,并使用共同的钥匙串。

对于区域和路由域认证,可以设置为SNP和LSP分开认证。

本地发送的LSP报文和SNP报文都携带认证TLV,对收到的LSP报文和SNP报文都进行认证检查。

本地发送的LSP报文携带认证TLV,对收到的LSP报文进行认证检查;发送的SNP报文携带认证TLV,但不对收到的SNP报文进行检查。

本地发送的LSP报文携带认证TLV,对收到的LSP报文进行认证检查;发送的SNP报文不携带认证TLV,也不对收到的SNP报文进行认证检查。

本地发送的LSP报文和SNP报文都携带认证TLV,对收到的LSP报文和SNP报文都不进行认证检查。

接口认证配置:

python 复制代码
[R4]INT G0/0/2
[R4-GigabitEthernet0/0/2]isis authentication-mode simple plain huawei
[R4-GigabitEthernet0/0/2]q
[R4]dis isis peer    //发现邻居关系没有啦 
Peer information for ISIS(100)
System Id     Interface          Circuit Id       State HoldTime Type     PRI
0000.0000.0002  GE0/0/0            0000.0000.0004.01 Up   21s      L2       64 
[R4]dis isis error 
Statistics of error packets for ISIS(100)
-----------------------------------------
LSP packet errors:
Longer LSP              : 0           Smaller LSP             : 0           
Mismatched Level        : 0           Invalid Sysid           : 0           
Zero Sequence Number    : 0           Illegal IS Type         : 0           
Zero Checksum           : 0           Incorrect Checksum      : 0           
Bad Authentication      : 0           Bad Auth Count          : 0           
More Protocol TLV       : 0           Bad Nbr TLV             : 0           
Bad Extended IS TLV     : 0           Bad IF Addr TLV         : 0           
Bad Reach TLV           : 0           Bad Inter Domain TLV    : 0           
Mismatched Area Id(L1)  : 0           Bad TLV Length          : 0          
Bad Alias TLV           : 0           Bad Area TLV            : 0           
Bad SRLG TLV            : 0           Unknown Adjacency       : 0           
Bad Protocol ID         : 0           Bad Version             : 0           
Zero Lifetime           : 4           Bad Ext Reach TLV       : 0           
Bad TE Router ID TLV    : 0           Bad TE Sub TLV          : 0           
Hello packet errors:
Bad Packet Length       : 0           Reserved CircType       : 0           
Repeated System ID      : 0           Bad Circuit Type        : 0           
Longer packet           : 0           More Area Addr          : 0           
Longer Area Addr        : 0           Bad Area Addr TLV       : 0           
More IF Addr            : 0           Bad Formatted IF TLV    : 0           
More Nbr SNPA(LAN)      : 0           Invalid Sysid           : 0           
Bad TLV Length          : 0           Zero HoldingTime        : 0           
Unusable IP Addr        : 0           Repeated IPv4 Addr      : 0           
Mismatched Area Addr(L1): 0           Mismatched Proto        : 0           
SNPA Conflicted(LAN)    : 0           Mismatched Level        : 0           
Mismatched Max Area Addr: 0           Bad Authentication      : 5           
More Auth TLV           : 0           3-Way Option Error(P2P) : 0           
No Area Addr TLV        : 0           Bad Protocol ID         : 0           
Bad Version             : 0           Invalid IPv6 Addr       : 0           
More IPv6 IF Addr       : 0           Duplicate IPv6 Addr     : 0           
More Optional Checksum  : 0           Bad Optional Checksum   : 0
[R5]int g0/0/0
[R5-GigabitEthernet0/0/0]isis authentication-mode simple plain huawei

备注:

数据传输:

simple 明文认证

MD5 密文认证

本地存储:

plain 明文

cipher 密文

**实验: ISIS 和OSPF 引入 **

整体思路:

1,配置ISIS

2, 配置OSPF

3, 配置OSPF 与ISIS 互相引入

拓扑1:

ISIS 配置:

**R1: **

isis 100

is-level level-1

network-entity 49.0123.0000.0000.0001.00

interface GigabitEthernet0/0/0

ip address 192.168.123.1 255.255.255.0

isis enable 100

isis dis-priority 127

R2配置:

isis 100

network-entity 49.0123.0000.0000.0002.00

is-level level-1-2

interface GigabitEthernet0/0/0

ip address 192.168.123.2 255.255.255.0

isis enable 100

isis circuit-level level-1

R4配置:

isis 100

is-level level-2

network-entity 49.0045.0000.0000.0004.00

interface GigabitEthernet0/0/0

ip address 192.168.24.4 255.255.255.0

isis enable 100

interface GigabitEthernet0/0/2

ip address 192.168.45.4 255.255.255.0

isis enable 100

isis circuit-type p2p

isis authentication-mode simple plain huawei

R5配置:

isis 100

is-level level-2

network-entity 49.0045.0000.0000.0005.00

interface GigabitEthernet0/0/0

ip address 192.168.45.5 255.255.255.0

isis enable 100

isis circuit-type p2p

isis authentication-mode simple plain huawei

OSPF 配置:

R6配置:

ospf 1 router-id 6.6.6.6

area 0.0.0.0

network 192.168.4.0 0.0.0.255

network 192.168.5.0 0.0.0.255

R1配置:

[r1]ospf 1 router-id 1.1.1.1

[r1-ospf-1]area 0

[r1-ospf-1-area-0.0.0.0]network 192.168.4.0 0.0.0.255

配置ISIS 与OSPF 互相引入:

[r1]ospf 1

[r1-ospf-1]default-route-advertise //将ISIS 里默认路由引进来

[r1-ospf-1]q

[r1]isis 100

[r1-isis-100]import-route ospf 1 level-1 //将OSPF 进程1 的路由引入到ISIS 的L1 路由表 (默认引入到L2)

[r1-isis-100]q

拓扑2:

python 复制代码
ISIS 配置同上。
R7的OSPF 配置:
ospf 1 router-id 7.7.7.7 
area 0.0.0.0 
network 192.168.2.0 0.0.0.255 
network 192.168.3.0 0.0.0.255 
R5的OSPF配置:
ospf 1 router-id 5.5.5.5 
import-route isis 100   //将 Isis 100  引入到 OSPF 
area 0.0.0.0 
network 192.168.2.0 0.0.0.255 
[R5]isis 100
[R5-isis-100]import-route ospf  1  //将OSPF 1  路由引入到默认 ISIS  L2 路由表
相关推荐
网安CILLE7 分钟前
2024年某大厂HW蓝队面试题分享
网络·安全·web安全
沐风ya13 分钟前
Reactor介绍,如何从简易版本的epoll修改成Reactor模型(demo版本代码+详细介绍)
网络
SUGERBOOM16 分钟前
【网络安全】网络基础第一阶段——第一节:网络协议基础---- OSI与TCP/IP协议
网络·网络协议·web安全
petaexpress33 分钟前
常用的k8s容器网络模式有哪些?
网络·容器·kubernetes
m0_609000423 小时前
向日葵好用吗?4款稳定的远程控制软件推荐。
运维·服务器·网络·人工智能·远程工作
suifen_6 小时前
RK3229_Android9.0_Box 4G模块EC200A调试
网络
铁松溜达py6 小时前
编译器/工具链环境:GCC vs LLVM/Clang,MSVCRT vs UCRT
开发语言·网络
衍生星球10 小时前
【网络安全】对称密码体制
网络·安全·网络安全·密码学·对称密码
掘根10 小时前
【网络】高级IO——poll版本TCP服务器
网络·数据库·sql·网络协议·tcp/ip·mysql·网络安全