<acronym id="s8ci2"><small id="s8ci2"></small></acronym>
<rt id="s8ci2"></rt><rt id="s8ci2"><optgroup id="s8ci2"></optgroup></rt>
<acronym id="s8ci2"></acronym>
<acronym id="s8ci2"><center id="s8ci2"></center></acronym>
0
  • 聊天消息
  • 系統消息
  • 評論與回復
登錄后你可以
  • 下載海量資料
  • 學習在線課程
  • 觀看技術視頻
  • 寫文章/發帖/加入社區
創作中心

完善資料讓更多小伙伴認識你,還能領取20積分哦,立即完善>

3天內不再提示

Cisco配置靜態路由

馬哥Linux運維 ? 來源:稀土掘金技術社區 ? 2023-12-03 09:43 ? 次閱讀

實驗拓撲

a2dc4bc2-90f6-11ee-939d-92fbcf53809c.jpg

配置R1


Router(config)




R1(config)
R1(config-if)
R1(config-if)




R1(config-if)
R1(config-if)
R1(config-if)




R1(config)
R1(config)

查看接口ip


R1
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                192.168.12.1    YES manual up                    up      
Ethernet0/1                192.168.1.254   YES manual up                    up      
Ethernet0/2                unassigned      YES unset  administratively down down    
Ethernet0/3                unassigned      YES unset  administratively down down    
Serial1/0                  unassigned      YES unset  administratively down down    
Serial1/1                  unassigned      YES unset  administratively down down    
Serial1/2                  unassigned      YES unset  administratively down down    
Serial1/3                  unassigned      YES unset  administratively down down 

查看R1路由表


R1
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


      192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.1.0/24 is directly connected, Ethernet0/1
L        192.168.1.254/32 is directly connected, Ethernet0/1
S     192.168.3.0/24 [1/0] via 192.168.12.2
      192.168.12.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.12.0/24 is directly connected, Ethernet0/0
L        192.168.12.1/32 is directly connected, Ethernet0/0
S     192.168.23.0/24 [1/0] via 192.168.12.2

配置R2


Router>enable
Router
Router(config)




R2(config)
R2(config-if)
R2(config-if)




R2(config-if)
R2(config-if)
R2(config-if)




R2(config)
R2(config)

查看接口ip


R2
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                192.168.12.2    YES manual up                    up      
Ethernet0/1                192.168.23.2    YES manual up                    up      
Ethernet0/2                unassigned      YES unset  administratively down down    
Ethernet0/3                unassigned      YES unset  administratively down down    
Serial1/0                  unassigned      YES unset  administratively down down    
Serial1/1                  unassigned      YES unset  administratively down down    
Serial1/2                  unassigned      YES unset  administratively down down    
Serial1/3                  unassigned      YES unset  administratively down down

查看路由


R2
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


S     192.168.1.0/24 [1/0] via 192.168.12.1
S     192.168.3.0/24 [1/0] via 192.168.23.3
      192.168.12.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.12.0/24 is directly connected, Ethernet0/0
L        192.168.12.2/32 is directly connected, Ethernet0/0
      192.168.23.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.23.0/24 is directly connected, Ethernet0/1
L        192.168.23.2/32 is directly connected, Ethernet0/1

配置R3


Router>enable 
Router
Router(config)
R3(config)


R3(config)
R3(config-if)
R3(config-if)


R3(config-if)
R3(config-if)
R3(config-if)


R3(config)
R3(config)

查看接口ip


R3
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                192.168.23.3    YES manual up                    up      
Ethernet0/1                192.168.3.254   YES manual up                    up      
Ethernet0/2                unassigned      YES unset  administratively down down    
Ethernet0/3                unassigned      YES unset  administratively down down    
Serial1/0                  unassigned      YES unset  administratively down down    
Serial1/1                  unassigned      YES unset  administratively down down    
Serial1/2                  unassigned      YES unset  administratively down down    
Serial1/3                  unassigned      YES unset  administratively down down   

查看路由


R3
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


S     192.168.1.0/24 [1/0] via 192.168.23.2
      192.168.3.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.3.0/24 is directly connected, Ethernet0/1
L        192.168.3.254/32 is directly connected, Ethernet0/1
S     192.168.12.0/24 [1/0] via 192.168.23.2
      192.168.23.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.23.0/24 is directly connected, Ethernet0/0
L        192.168.23.3/32 is directly connected, Ethernet0/0

配置vpc4


VPCS> ip 192.168.1.2/24 192.168.1.254
Checking for duplicate address...
VPCS : 192.168.1.2 255.255.255.0 gateway 192.168.1.254

配置vpc5


VPCS> ip 192.168.3.2/24 192.168.3.254
Checking for duplicate address...
VPCS : 192.168.3.2 255.255.255.0 gateway 192.168.3.254

在vpc4上ping vpc5測試連通性


VPCS> ping 192.168.3.2


84 bytes from 192.168.3.2 icmp_seq=1 ttl=61 time=0.958 ms
84 bytes from 192.168.3.2 icmp_seq=2 ttl=61 time=0.785 ms
84 bytes from 192.168.3.2 icmp_seq=3 ttl=61 time=1.050 ms
84 bytes from 192.168.3.2 icmp_seq=4 ttl=61 time=0.823 ms
84 bytes from 192.168.3.2 icmp_seq=5 ttl=61 time=0.827 ms

審核編輯:湯梓紅

聲明:本文內容及配圖由入駐作者撰寫或者入駐合作網站授權轉載。文章觀點僅代表作者本人,不代表電子發燒友網立場。文章及其配圖僅供工程師學習之用,如有內容侵權或者其他違規問題,請聯系本站處理。 舉報投訴
  • 接口
    +關注

    關注

    33

    文章

    7761

    瀏覽量

    148763
  • CISCO
    +關注

    關注

    1

    文章

    64

    瀏覽量

    24574
  • 靜態路由
    +關注

    關注

    0

    文章

    17

    瀏覽量

    8546

原文標題:Cisco配置靜態路由

文章出處:【微信號:magedu-Linux,微信公眾號:馬哥Linux運維】歡迎添加關注!文章轉載請注明出處。

收藏 人收藏

    評論

    相關推薦

    Cisco路由器網絡設計

    Cisco路由器網絡設計相關知識,拓展網絡知識。
    發表于 06-04 19:42 ?29次下載

    CISCO路由配置實例

    Cisco 路由器的基本配置百余例目錄1.用戶通過DDN專線接入ISP 2.遠程用戶撥號連入局域網 3.遠程用戶間對撥 4.Cisco 
    發表于 08-31 09:46 ?46次下載

    Cisco路由安全性分析和改進

    路由器安全在網絡安全領域占有非常重要的地位,針對互聯網中使用最為廣泛的Cisco路由器,從3個方面出發分別說明了Cisco路由器所面臨的各種
    發表于 11-24 18:41 ?15次下載

    靜態路由協議配置

    實驗十、靜態路由協議配置 一、實驗原理1.1 路由協議路由器依據路由表進行轉發。
    發表于 09-24 13:48 ?4604次閱讀
    <b class='flag-5'>靜態</b><b class='flag-5'>路由</b>協議<b class='flag-5'>配置</b>

    配置靜態路由

    配置靜態路由 用戶可以在全局配置模式下通過命令 ip route
    發表于 06-09 23:51 ?772次閱讀
    <b class='flag-5'>配置</b><b class='flag-5'>靜態</b><b class='flag-5'>路由</b>

    靜態路由配置舉例

    靜態路由配置舉例 在這個例子中使用 IP ROUTE 命令來配置靜態路由:ip route
    發表于 06-09 23:52 ?1091次閱讀
    <b class='flag-5'>靜態</b><b class='flag-5'>路由</b><b class='flag-5'>配置</b>舉例

    CISCO系列路由器密碼恢復匯總

    CISCO系列路由器密碼恢復匯總   密碼恢復原理(1)Cisco路由器保存了幾種不同的配置參數,并存放在不
    發表于 01-13 13:03 ?839次閱讀

    CISCO路由器初始配置手冊

    CISCO路由器初始配置手冊 很多初學路由器知識的網友對路由器的初始配置可能感到很陌生,本人在
    發表于 04-01 11:49 ?782次閱讀

    CISCO路由器之廣域網協議設置

    CISCO路由器之廣域網協議設置 一、HDLC HDLC是CISCO路由器使用的缺省協議,一臺新路由器在未指定封裝協議時默認使用H
    發表于 04-01 13:42 ?3295次閱讀

    CISCO與華為3COM路由器的比較分析

    剖析CISCO與華為3COM路由器的區別,熟練掌握下面涉及到的CISCO與華為3COM路由器知識,很多方法都會使你豁然開朗的。華為路由器與同
    發表于 02-26 10:22 ?1130次閱讀

    Cisco路由器流量采集軟件的研制_張欣

    Cisco路由器流量采集軟件的研制_張欣
    發表于 03-19 11:26 ?0次下載

    怎么樣配置Cisco單臂路由?關鍵步驟解析

    單臂路由,即在路由器上設置多個邏輯子接口,每個子接口對應一個vlan。在每個子接口的數據在物理鏈路上傳遞都要標記封裝。Cisco設備支持ISL和802.1q(dot1Q)協議。華為只支持802.1q。
    發表于 12-05 13:38 ?1566次閱讀
    怎么樣<b class='flag-5'>配置</b><b class='flag-5'>Cisco</b>單臂<b class='flag-5'>路由</b>?關鍵步驟解析

    思科路由配置基礎_7個方面詳解cisco路由配置

    大家一定對Cisco路由器并不陌生,作為第一個入行的國際化企業而言,它的產品眾所周知,但也正因為如此讓大家對于一些有關它的配置有所困惑,本文主要介紹的是思科路由
    發表于 05-14 09:32 ?1.6w次閱讀

    詳解交換機與路由器的配置,如何配置靜態路由

    一種路由的方式,路由項由手動配置,而非動態決定。與動態路由不同,靜態路由是固定的,不會改變,即使
    的頭像 發表于 01-03 10:19 ?2418次閱讀

    靜態路由是什么?靜態路由如何配置?

    靜態路由是一種路由的方式,路由項由手動配置,而非動態決定。與動態路由不同,
    的頭像 發表于 10-07 10:48 ?9279次閱讀
    <b class='flag-5'>靜態</b><b class='flag-5'>路由</b>是什么?<b class='flag-5'>靜態</b><b class='flag-5'>路由</b>如何<b class='flag-5'>配置</b>?
    亚洲欧美日韩精品久久_久久精品AⅤ无码中文_日本中文字幕有码在线播放_亚洲视频高清不卡在线观看
    <acronym id="s8ci2"><small id="s8ci2"></small></acronym>
    <rt id="s8ci2"></rt><rt id="s8ci2"><optgroup id="s8ci2"></optgroup></rt>
    <acronym id="s8ci2"></acronym>
    <acronym id="s8ci2"><center id="s8ci2"></center></acronym>