ISIS实验教程
AR1配置
router id 1.1.1.1 isis 1 network-entity 49.0001.0000.0000.1111.00 interface GigabitEthernet0/0/0 ip address 13.1.1.1 255.255.255.0 isis enable 1 interface LoopBack0 ip address 1.1.1.1 255.255.255.255 isis enable 1
AR2配置
router id 2.2.2.2 isis 1 network-entity 49.0001.0000.0000.2222.00 interface Serial1/0/0 link-protocol ppp ip address 12.1.1.2 255.255.255.0 isis enable 1 interface GigabitEthernet0/0/0 ip address 24.1.1.2 255.255.255.0 isis enable 1 interface LoopBack0 ip address 2.2.2.2 255.255.255.255 isis enable 1
AR3配置
router id 3.3.3.3 isis 1 network-entity 49.0001.0000.0000.3333.00 interface GigabitEthernet0/0/0 ip address 13.1.1.3 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 35.1.1.3 255.255.255.0 isis enable 1 interface LoopBack0 ip address 3.3.3.3 255.255.255.255 isis enable 1
AR4配置
router id 4.4.4.4 isis 1 network-entity 49.0001.0000.0000.4444.00 interface GigabitEthernet0/0/0 ip address 24.1.1.4 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 45.1.1.4 255.255.255.0 isis enable 1 interface LoopBack0 ip address 4.4.4.4 255.255.255.255 isis enable 1
AR5配置
router id 5.5.5.5 isis 1 network-entity 49.0002.0000.0000.5555.00 interface GigabitEthernet0/0/0 ip address 35.1.1.5 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 45.1.1.5 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/2 ip address 56.1.1.5 255.255.255.0 isis enable 1 interface LoopBack0 ip address 5.5.5.5 255.255.255.255 isis enable 1
AR6配置
router id 6.6.6.6 isis 1 network-entity 49.0003.0000.0000.6666.00 interface GigabitEthernet0/0/0 ip address 56.1.1.6 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 67.1.1.6 255.255.255.0 isis enable 1 interface LoopBack0 ip address 6.6.6.6 255.255.255.255 isis enable 1
AR7配置
router id 7.7.7.7 isis 1 network-entity 49.0003.0000.0000.7777.00 interface GigabitEthernet0/0/0 ip address 67.1.1.7 255.255.255.0 isis enable 1 interface LoopBack0 ip address 7.7.7.7 255.255.255.255 isis enable 1
<AR5>dis isis peer Peer information for ISIS(1) System Id Interface Circuit Id State HoldTime Type PRI ------------------------------------------------------------------------------- 0000.0000.3333 GE0/0/0 0000.0000.5555.01 Up 28s L2(L1L2) 64 0000.0000.4444 GE0/0/1 0000.0000.5555.02 Up 24s L2(L1L2) 64 0000.0000.6666 GE0/0/2 0000.0000.5555.03 Up 30s L2(L1L2) 64 Total Peer(s): 3
<AR3>dis isis peer Peer information for ISIS(1) System Id Interface Circuit Id State HoldTime Type PRI ------------------------------------------------------------------------------- 0000.0000.1111 GE0/0/0 0000.0000.3333.01 Up 20s L1(L1L2) 64 0000.0000.1111 GE0/0/0 0000.0000.3333.01 Up 29s L2(L1L2) 64 0000.0000.5555 GE0/0/1 0000.0000.5555.01 Up 8s L2(L1L2) 64 Total Peer(s): 3
由于ISIS 路由器类型默认是L1/L2类型的,所以即可以和邻居建立Leve 1的邻居关系和leve 2的邻居关系。
<AR1>dis ip routing-table p isis Route Flags: R - relay, D - download to fib ------------------------------------------------------------------------------ Public routing table : ISIS Destinations : 11 Routes : 11 ISIS routing table status : <Active> Destinations : 11 Routes : 11 Destination/Mask Proto Pre Cost Flags NextHop Interface 2.2.2.2/32 ISIS-L1 15 10 D 12.1.1.2 Serial1/0/0 3.3.3.3/32 ISIS-L1 15 10 D 13.1.1.3 GigabitEthernet 0/0/0 4.4.4.4/32 ISIS-L1 15 20 D 12.1.1.2 Serial1/0/0 5.5.5.5/32 ISIS-L2 15 20 D 13.1.1.3 GigabitEthernet 0/0/0 6.6.6.6/32 ISIS-L2 15 30 D 13.1.1.3 GigabitEthernet 0/0/0 7.7.7.7/32 ISIS-L2 15 40 D 13.1.1.3 GigabitEthernet 0/0/0 24.1.1.0/24 ISIS-L1 15 20 D 12.1.1.2 Serial1/0/0 35.1.1.0/24 ISIS-L1 15 20 D 13.1.1.3 GigabitEthernet 0/0/0 45.1.1.0/24 ISIS-L1 15 30 D 12.1.1.2 Serial1/0/0 56.1.1.0/24 ISIS-L2 15 30 D 13.1.1.3 GigabitEthernet 0/0/0 67.1.1.0/24 ISIS-L2 15 40 D 13.1.1.3 GigabitEthernet 0/0/0 ISIS routing table status : <Inactive> Destinations : 0 Routes : 0 <AR1>
<AR1>dis isis lsdb Database information for ISIS(1) -------------------------------- Level-1 Link State Database LSPID Seq Num Checksum Holdtime Length ATT/P/OL ------------------------------------------------------------------------------- 0000.0000.1111.00-00* 0x00000009 0xf049 471 113 1/0/0 0000.0000.2222.00-00 0x0000000a 0xbf7b 600 113 1/0/0 0000.0000.2222.01-00 0x00000003 0x3f3d 600 55 0/0/0 0000.0000.3333.00-00 0x00000009 0x1876 662 102 1/0/0 0000.0000.3333.01-00 0x00000003 0x504e 662 55 0/0/0 0000.0000.4444.00-00 0x00000009 0x72e7 618 102 1/0/0 Total LSP(s): 6 *(In TLV)-Leaking Route, *(By LSPID)-Self LSP, +-Self LSP(Extended), ATT-Attached, P-Partition, OL-Overload Level-2 Link State Database LSPID Seq Num Checksum Holdtime Length ATT/P/OL ------------------------------------------------------------------------------- 0000.0000.1111.00-00* 0x00000010 0x8c5c 471 185 0/0/0 0000.0000.2222.00-00 0x00000011 0x37c1 596 185 0/0/0 0000.0000.2222.01-00 0x00000003 0x3f3d 596 55 0/0/0 0000.0000.3333.00-00 0x00000011 0xc030 662 185 0/0/0 0000.0000.3333.01-00 0x00000003 0x504e 662 55 0/0/0 0000.0000.4444.00-00 0x0000000f 0x4b8b 617 185 0/0/0 0000.0000.5555.00-00 0x0000000e 0x19fd 765 140 0/0/0 0000.0000.5555.01-00 0x00000003 0xc70a 765 55 0/0/0 0000.0000.5555.02-00 0x00000003 0x6b43 765 55 0/0/0 0000.0000.5555.03-00 0x00000003 0xb9af 765 55 0/0/0 0000.0000.6666.00-00 0x0000000c 0x888e 826 125 0/0/0 0000.0000.6666.02-00 0x00000002 0x7e86 826 55 0/0/0 0000.0000.7777.00-00 0x00000006 0xef84 793 110 0/0/0 Total LSP(s): 13 *(In TLV)-Leaking Route, *(By LSPID)-Self LSP, +-Self LSP(Extended), ATT-Attached, P-Partition, OL-Overload <AR1>
验证
<AR1>ping -a 1.1.1.1 7.7.7.7 PING 7.7.7.7: 56 data bytes, press CTRL_C to break Reply from 7.7.7.7: bytes=56 Sequence=1 ttl=252 time=90 ms Reply from 7.7.7.7: bytes=56 Sequence=2 ttl=252 time=50 ms Reply from 7.7.7.7: bytes=56 Sequence=3 ttl=252 time=40 ms Reply from 7.7.7.7: bytes=56 Sequence=4 ttl=252 time=40 ms Reply from 7.7.7.7: bytes=56 Sequence=5 ttl=252 time=30 ms --- 7.7.7.7 ping statistics --- 5 packet(s) transmitted 5 packet(s) received 0.00% packet loss round-trip min/avg/max = 30/50/90 ms <AR1>ping -a 1.1.1.1 6.6.6.6 PING 6.6.6.6: 56 data bytes, press CTRL_C to break Reply from 6.6.6.6: bytes=56 Sequence=1 ttl=253 time=60 ms Reply from 6.6.6.6: bytes=56 Sequence=2 ttl=253 time=40 ms Reply from 6.6.6.6: bytes=56 Sequence=3 ttl=253 time=30 ms Reply from 6.6.6.6: bytes=56 Sequence=4 ttl=253 time=30 ms Reply from 6.6.6.6: bytes=56 Sequence=5 ttl=253 time=40 ms --- 6.6.6.6 ping statistics --- 5 packet(s) transmitted 5 packet(s) received 0.00% packet loss round-trip min/avg/max = 30/40/60 ms <AR1>
测试一:检验路由器是否真的最多只能配置3个区域?
[AR1-isis-1]network-entity 49.0002.0000.0000.1111.00 [AR1-isis-1]network-entity 49.0003.0000.0000.1111.00 [AR1-isis-1]network-entity 49.0004.0000.0000.1111.00 Warning: The maximum allowed area address already configured. [AR1-isis-1] [AR1-isis-1]network-entity 49.0002.0000.0000.2222.00 Warning: The maximum allowed area address already configured.
结论:确实最多只能配置3个区域,超过3,会报错。每台路由器只能配置一个sysid。
测试二ISIS的骨干区域和非骨干区域
我们都知道,ISIS默认路由器类型是:L1/L2 类型。如果要进行区域规范,那么需要修改一下路由器类型,如下:
R1、R2、R7修改L1类型;R5修改L2类型,其他默认L1/L2类型。
isis 1 is-level level-1 network-entity 49.0001.0000.0000.1111.00
isis 1 is-level level-2 network-entity 49.0002.0000.0000.5555.00
AR1上查看路由
[AR1]dis ip routing-table p isis Route Flags: R - relay, D - download to fib ------------------------------------------------------------------------------ Public routing table : ISIS Destinations : 7 Routes : 7 ISIS routing table status : <Active> Destinations : 7 Routes : 7 Destination/Mask Proto Pre Cost Flags NextHop Interface 0.0.0.0/0 ISIS-L1 15 10 D 13.1.1.3 GigabitEthernet 0/0/0 2.2.2.2/32 ISIS-L1 15 10 D 12.1.1.2 Serial1/0/0 3.3.3.3/32 ISIS-L1 15 10 D 13.1.1.3 GigabitEthernet 0/0/0 4.4.4.4/32 ISIS-L1 15 20 D 12.1.1.2 Serial1/0/0 24.1.1.0/24 ISIS-L1 15 20 D 12.1.1.2 Serial1/0/0 35.1.1.0/24 ISIS-L1 15 20 D 13.1.1.3 GigabitEthernet 0/0/0 45.1.1.0/24 ISIS-L1 15 30 D 12.1.1.2 Serial1/0/0 ISIS routing table status : <Inactive> Destinations : 0 Routes : 0
路由条目少了,但是多了一条缺省路由。
R5上查看路由
[AR5]dis ip routing-table p isis Route Flags: R - relay, D - download to fib ------------------------------------------------------------------------------ Public routing table : ISIS Destinations : 10 Routes : 11 ISIS routing table status : <Active> Destinations : 10 Routes : 11 Destination/Mask Proto Pre Cost Flags NextHop Interface 1.1.1.1/32 ISIS-L2 15 20 D 35.1.1.3 GigabitEthernet 0/0/0 2.2.2.2/32 ISIS-L2 15 20 D 45.1.1.4 GigabitEthernet 0/0/1 3.3.3.3/32 ISIS-L2 15 10 D 35.1.1.3 GigabitEthernet 0/0/0 4.4.4.4/32 ISIS-L2 15 10 D 45.1.1.4 GigabitEthernet 0/0/1 6.6.6.6/32 ISIS-L2 15 10 D 56.1.1.6 GigabitEthernet 0/0/2 7.7.7.7/32 ISIS-L2 15 20 D 56.1.1.6 GigabitEthernet 0/0/2 12.1.1.0/24 ISIS-L2 15 30 D 35.1.1.3 GigabitEthernet 0/0/0 ISIS-L2 15 30 D 45.1.1.4 GigabitEthernet 0/0/1 13.1.1.0/24 ISIS-L2 15 20 D 35.1.1.3 GigabitEthernet 0/0/0 24.1.1.0/24 ISIS-L2 15 20 D 45.1.1.4 GigabitEthernet 0/0/1 67.1.1.0/24 ISIS-L2 15 20 D 56.1.1.6 GigabitEthernet 0/0/2 ISIS routing table status : <Inactive> Destinations : 0 Routes : 0 [AR5]