Cisco 2960X交換機支援多少條靜態路由

funnycoffee123發表於2020-09-30

最多支援16條靜態路由
交換機型號如下:

Switch#sh inventory 
NAME: "1", DESCR: "WS-C2960X-48FPS-L"
PID: WS-C2960X-48FPS-L , VID: V02  , SN: FOC1849S5YM

> 這裡是引用
關於型號的說明:
WS-C:cisco交換機字首```
2960X: 2960X系列
FP: Full POE供電  740W,埠POE功率支援15W和30W (802.3af, 803.at)
S:uplink為4個SFP介面
L:LAN-Base

以下是配置靜態路由步驟
配置多於16條並不會報錯,但多於16條以上的配置會直接丟失
以下以刷入20條為例, 刷完後我們看實際生效幾條

```bash
Switch(config)#ip route 1.1.1.1 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.2 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.3 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.4 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.5 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.6 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.7 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.8 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.9 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.10 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.11 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.12 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.13 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.14 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.15 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.16 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.17 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.18 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.19 255.255.255.255 192.168.0.100
Switch(config)#ip route 1.1.1.20 255.255.255.255 192.168.0.100

檢視實際生效的靜態條目數量, 16條

Switch#sh ip route static 
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area 
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       a - application route
       + - replicated route, % - next hop override, p - overrides from PfR

Gateway of last resort is not set

      1.0.0.0/32 is subnetted, 16 subnets
S        1.1.1.1 [1/0] via 192.168.0.100
S        1.1.1.2 [1/0] via 192.168.0.100
S        1.1.1.3 [1/0] via 192.168.0.100
S        1.1.1.4 [1/0] via 192.168.0.100
S        1.1.1.5 [1/0] via 192.168.0.100
S        1.1.1.6 [1/0] via 192.168.0.100
S        1.1.1.7 [1/0] via 192.168.0.100
S        1.1.1.8 [1/0] via 192.168.0.100
S        1.1.1.9 [1/0] via 192.168.0.100
S        1.1.1.10 [1/0] via 192.168.0.100
S        1.1.1.11 [1/0] via 192.168.0.100
S        1.1.1.12 [1/0] via 192.168.0.100
S        1.1.1.13 [1/0] via 192.168.0.100
S        1.1.1.14 [1/0] via 192.168.0.100
S        1.1.1.15 [1/0] via 192.168.0.100
S        1.1.1.16 [1/0] via 192.168.0.100
Switch# 
Switch# sh ip route summary 
IP routing table name is default (0x0)
IP routing table maximum-paths is 32
Route Source    Networks    Subnets     Replicates  Overhead    Memory (bytes)
connected       0           6           0           432         1104
static          0           **16**          0           1152        2944
ospf 100        0           0           0           0           0
  Intra-area: 0 Inter-area: 0 External-1: 0 External-2: 0
  NSSA External-1: 0 NSSA External-2: 0
internal        4                                               2136
Total           4           22          0           1584        6184
Switch#


Switch#sh run | in ip r
ip routing
 no ip route-cache
ip route 1.1.1.1 255.255.255.255 192.168.0.100
ip route 1.1.1.2 255.255.255.255 192.168.0.100
ip route 1.1.1.3 255.255.255.255 192.168.0.100
ip route 1.1.1.4 255.255.255.255 192.168.0.100
ip route 1.1.1.5 255.255.255.255 192.168.0.100
ip route 1.1.1.6 255.255.255.255 192.168.0.100
ip route 1.1.1.7 255.255.255.255 192.168.0.100
ip route 1.1.1.8 255.255.255.255 192.168.0.100
ip route 1.1.1.9 255.255.255.255 192.168.0.100
ip route 1.1.1.10 255.255.255.255 192.168.0.100
ip route 1.1.1.11 255.255.255.255 192.168.0.100
ip route 1.1.1.12 255.255.255.255 192.168.0.100
ip route 1.1.1.13 255.255.255.255 192.168.0.100
ip route 1.1.1.14 255.255.255.255 192.168.0.100
ip route 1.1.1.15 255.255.255.255 192.168.0.100
ip route 1.1.1.16 255.255.255.255 192.168.0.100
Switch# 

當前這臺硬體為LAN-base,如果是LanLite硬體,則完全不支援靜態路由。

另外LAN-BASE與LAN-LITE可以通過換IOS而實現功能互換嗎?
沒戲,硬體寫死的,換不了

link

Cisco Catalyst 2960-X Series FAQ

https://www.cisco.com/c/en/us/products/collateral/switches/catalyst-2960-x-series-switches/datasheet_c78-728232.html

相關文章