tft每日頭條

 > 圖文

 > 銳捷路由器設置手冊

銳捷路由器設置手冊

圖文 更新时间:2024-07-21 23:18:54
一、路由器基本配置命令由遠程終端登錄路由器

Red-Giant>enable ——由用戶模式進入特權模式 Password:****** ——輸入密碼 Red-Giant#configure ——由特權模式進入全局配置模式 Configuring from terminal, memory, or network [terminal]? t ——輸入 t繼續 Red-Giant(config)#hostname Router ——修改路由器名稱

配置接口IP地址

Router(config)#interface fastethernet 0 ——進入以太網口 0接口模式 Router(config-if)#ip address 192.168.1.1 255.255.255.0 ——為其配置 IP地址 Router(config-if)#no shutdown ——啟用配置 Router(config-if)#exit ——退至配置模式 Router(config)#interface fastethernet 1 ——進入以太網口 0接口模式 Router(config-if)#ip address 192.168.2.1 255.255.255.0 ——為其配置 IP地址 Router(config-if)#no shutdown ——啟用配置 Router(config-if)#exit ——退至配置模式 Router(config)#interface serial 0 ——進入 Serial 0 接口模式 Router(config-if)#ip address 192.168.3.1 255.255.255.0 ——為其配置 IP地址 Router(config-if)#no shutdown ——啟用配置 Router(config-if)#exit ——退至配置模式 Router(config)#interface serial 1 ——進入 Serial 1 接口模式 Router(config-if)#ip address 192.168.4.1 255.255.255.0 ——為其配置 IP地址 router(config-if)#no shutdown ——啟用配置 Router(config-if)#end ——退至特權模式 Router#write ——保存配置信息 Router(config)#interface loopback 0 ——新建 Loopback 0 Router(config-if)#ip add 10.10.1.1 255.255.255.0 ——為其配置 IP地址 Router(config-if)#int Loopback 1 ——新建 Loopback 1 Router(config-if)#ip add 10.10.2.1 255.255.255.0 ——為其配置 IP地址 Router(config-if)#end——退至特權模式

查看路由器相關配置信息

Router#show ip interface brief ——查看配置狀态 Router#show version ——顯示路由器版本信息 Router#show ip interface fastethernet 0 ——查看以太網口 0接口配置狀态 Router#show running-config——顯示當前運行的配置參數 Router#show startup-config——顯示 NVRAM中中配置參數的副本 Router#copy running-config startup-config ——将當前運行的配置參數複制到 NVRAM Router#erase startup-config——清空 NVRAM中的配置參數 Router#reload——重新啟動路由器

配置console 登陸密碼

Router(config)#line console 0 Router(config-line)#login Router(config-line)#password star

配置VTY登陸密碼

Router(config)#line vty 0 4 Router(config-line)#login Router(config-line)#password star

配置特權模式登錄密碼

Router(config)#enable password star——配置明文密碼 Router(config)#enable secret star——配置的密碼不能與 password密碼相同

二、路由器密碼丢失的處理方法
  1. 關閉路由器,重新登錄超級終端,按默認方法設置;
  2. 啟動路由器,不停地按 Ctrl Pause Break,直至出現 Boot:提示符,輸入 Setup-Reg;

Boot:Setup-Reg

  1. 出現如下提示信息,按“ Y”回車确認:

Do you wish to change the configuration?y/n[n]:

  1. 出現提示如下信息,按“ Y”回車确認:

Enable“bypass the system configure file”y/n[n]:

  1. 出現提示如下信息,按“ N”回車确認:

Enable“debug mode?”y/n[n]:

  1. 出現提示如下信息,按“ N”回車确認:

Enable“user break/abort enabled?”y/n[n]:

  1. 出現提示如下信息,按“ N”回車确認:

Change console speed?y/n[n]:

  1. 出現提示如下信息,按“ N”回車确認:

Do you wish to change the configuration?y/n[n]:

  1. 出現提示符“Boot:”,輸入Reset;

Boot:reset

  1. 出現提示如下信息,按“ N”回車确認:

Would you like to enter the initial configuration dialog?[Yes]:

此時密碼及路由器信息被清除,你就可以順利進入路由器了⋯⋯ 可以歸納為“Setup-Reg,兩個Y五個N,Reset”。

三、靜态路由配置

兩台路由器,其中 :

Route A

  • S0:192.168.3.1 ,
  • F1:192.168.2.1 ,
  • Loopback 1:12.12.1.1 ,
  • Loopback 2:12.12.2.1

Route B

  • S0:192.168.3.2 ,
  • F0:192.168.5.1 ,
  • Loopback 3:10.10.1.1 ,
  • Loopback 4:10.10.2.1

具體配置如下:

銳捷路由器設置手冊(銳捷路由器配置命令大全)1

登錄路由器并配置 F0、F1、S0、S1的IP地址

Router>en Password: Router#con Configuring from terminal, memory, or network [terminal]? t Router(config-if)#ip address 192.168.1.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit Router(config)#int f1 Router(config-if)#ip address 192.168.2.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit Router(config)#int s0 Router(config-if)#ip address 192.168.3.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit Router(config)# Router(config)#int s1 Router(config-if)#ip address 192.168.4.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#end

新增Loopback1、Loopback2并為其配置 IP地址

Router#con Configuring from terminal, memory, or network [terminal]? t Router(config)#int loopback 1 Router(config-if)#ip address 12.12.1.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#int loopback 2 Router(config-if)#ip address 12.12.2.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit

指向下一跳 路由器

Router(config)#ip route 10.10.1.0 255.255.255.0 192.168.3.2 Router#show ip interface brief Router#interface serial 0

設置接口物理時鐘頻率

Router#show control Serial 0 ——查看Serial 0 接口型号 Router#configure Configuring from terminal, memory, or network [terminal]? t Router(config)#int s0 Router(config-if)#clock rate 64000 ——設置接口物理時鐘頻率為 64Kbps(DCE) Router(config-if)#no shutdown Router(config)#end

為Serial 0 封裝PPP協議

Router#configure Configuring from terminal, memory, or network [terminal]? t Router(config)#int s0 Router(config-if)#enca ppp ——為Serial 0 封裝PPP協議 Router(config-if)#end

測試路由配置信息及互聯互通

Router#show ip route Router#show ip interface brief Router#show running-config Router#Ping 192.168.3.1 Router#Ping 192.168.3.2 Router#Ping 10.10.1.1

接下來,在另一台路由器上進行相應配置,并測試互連互通。實驗完成!!!

四、RIP動态路由配置

配置步驟:

  1. 啟用RIP進程;
  2. 配置Network命令;
  3. 配置均載負衡(代價相等);
  4. 配置RIP發布初始度量值。
(一)配置命令

User Access Verification Password: Router>en Password: Router#con Configuring from terminal, memory, or network [terminal]? t Router(config)#router rip ——開啟路由功能 Router(config-router)#version 2 ——升級至版本 2 Router(config-router)#no auto-summary ——在主類邊界關閉自動彙總 Router(config-router)#network 192.168.1.0 ——配置 network命令 Router(config-router)#maximum-paths 4 ——配置均衡負載,缺省值為 4 Router(config-router)#default-metric 1 ——配置 RIP發布初始度量值,建議設置為 1 Router#show ip protocols ——驗證RIP的配置 Router#show ip route ——顯示路由表的信息 Router#clear ip route ——清除 IP路由表的信息 Router#debug ip rip ——在控制台顯示 RIP的工作狀态 Router#no debug all ——清除控制台顯示 RIP的工作狀态

(二)實驗模型

拓樸圖如下,用 RIP配置Route-A和Route-B之間的路由。

銳捷路由器設置手冊(銳捷路由器配置命令大全)2

配置F0、F1和S0端口IP地址

User Access Verification Password: Router>en Password: Router#con Configuring from terminal, memory, or network [terminal]? t Router(config)#int f0 Router(config-if)#ip add 192.168.1.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit Router(config)#int f1 Router(config-if)#ip add 192.168.2.1 255.255.255.0 Router(config-if)#no shutdown Router(config-if)#exit Router(config)#int s0 Router(config-if)#ip add 10.1.1.2 255.255.255.252 Router(config-if)#no shutdown Router(config-if)#exit

開啟RIP路由功能, 配置Network命令

Router(config)#router rip Router(config-router)#version 2 Router(config-router)#no auto-summary Router(config-router)#network 10.1.1.0 Router(config-router)#network 172.16.1.0 Router(config-router)#network 172.16.2.0 Router(config-router)#end

查看配置信息,并測試配置正确與否

Router#show ip route Router#show ip protocols Router#debug ip rip Router#no debug all Router#ping 192.168.1.1 Router#ping 172.16.1.1 Router#ping 172.16.2.1

接下來,在另一台路由器上進行相應配置,并測試互連互通。實驗完成!!!

五、交換機、路由器配置步驟簡要說明(一)配置說明
  1. 首先連接好設備,确保連接正确;
  2. 用超級終端進入路由器,如果忘記了密碼,請按密碼破解方法清除設置,還原默認設置;
  3. 查看各接口配置信息, “Show ip interface brief ” ,看以前的配置有沒有保存在機器裡面,視情進行清除設置;
  4. 查看交換機、路由器的配置, “show running -config”;
  5. 按自己的需要給交換機和路由器命名,以便于區分, “hostname XXXXXX”;
  6. 按照配置需求對交換機、路由器的各接口進行配置,配置之前最好查看一下接口時鐘類型:

show controllers serial 0 clock rate 64000 no shutdown

記住:對接口配置完退至上一級時一定要保存配置,即 “no shutdown”;

  1. 配置完畢後,退至特權模式下,檢查配置的正确與否。
(二)故障排除

如果兩台路由器或交換機之間不能互連互通,請按照下列步驟進行檢查:

  1. 檢查Serial 接口的時鐘頻率;
  2. 檢查同一介質上兩個接口的 IP地址是不是在同一網段;
  3. 配置完接口後有沒有 “no shutdwon”;
  4. 接口的封裝協議是否相同;
  5. 有沒有把 IP地址配置錯誤。
(三)三層交換機的有關說明
  1. 管理二層交換機的 IP地址隻有一個生效,且為最後一個 “no shutdown”;
  2. 創建一個 Vlan,至少一個,為了冗餘備份。
六、OSPF動态路由配置實驗

配置步驟:

  1. 确定Area 0;
  2. 激活進程号;
  3. 反向掩碼;
  4. 主幹鍊路區域為 0。

User Access Verification Password: router>en Password: router#con Configuring from terminal, memory, or network [terminal]? t router(config)#int f0 router(config-if)#ip add 192.168.8.1 255.255.255.0 router(config-if)#no shutdown router(config-if)#exit router(config)#int f1 router(config-if)#ip add 192.168.2.1 255.255.255.0 router(config-if)#no shutdown router(config-if)#exit router(config)#int s0 router(config-if)#ip add 192.168.1.2 255.255.255.0 router(config-if)#no shutdown router(config-if)#exit router(config)#int s1 router(config-if)#ip add 192.168.3.2 255.255.255.0 router(config-if)#no shutdown router(config-if)#int loopback 4 router(config-if)#ip add 12.12.1.1 255.255.255.0 router(config-if)#no shutdown router(config-if)#int loopback 5 router(config-if)#ip add 12.12.2.1 255.255.255.0 router(config-if)#no shutdown router(config-if)#int loopback 6 router(config-if)#ip add 12.12.3.1 255.255.255.0 router(config-if)#no shutdown router(config-if)#exit

配置OSPF路由協議

router(config)#router ospf 11 ——激活進程号 router(config-router)#network 192.168.1.0 0.0.0.255 area 0 ——申明自治區域 0 router(config-router)#network 12.12.1.0 0.0.0.255 area 1 ——申明自治區域 1 router(config-router)#network 12.12.2.0 0.0.0.255 area 1 router(config-router)#network 12.12.3.0 0.0.0.255 area 1 router(config-router)#end router#show ip protocols router#show ip interface brief router#show ip ospf neighbor

七、訪問控制列表

銳捷路由器設置手冊(銳捷路由器配置命令大全)3

Router#conConfiguring from terminal, memory, or network [terminal]? t 讓用戶D不能遠程登錄 A Router(config)#access-list 103 deny tcp host 192.168.3.139 host 192.168.5.165eq 23Router(config)#access-list 103 permit ip any anyRouter(config)#int Serial 0Router(config-if)#ip access-group 103 out 記用戶A不能問網絡,而用戶 B能夠訪問網絡 Router(config)#access-list 12 deny 192.168.5.0 0.0.0.255Router(config)#access-list 12 permit 192.168.6.0 0.0.0.255Router(config)#int serial 0Router(config-if)#ip access-group 12 outRouter(config-if)#no shutdownRouter(config-if)#endRouter#show ip access-list 八、封裝 PPP協議驗證 User Access VerificationPassword:router>enPassword:router#conConfiguring from terminal, memory, or network [terminal]? tRed-Giant(config)#hostname RouterRouter(config)#enable password starRouter(config)#line vty 0 4Router(config-line)#loginRouter(config-line)#password starRouter(config-line)#endRouter#show ip in b Router#conConfiguring from terminal, memory, or network [terminal]? tRouter(config)#int f0Router(config-if)#ip add 192.168.2.1 255.255.255.0Router(config-if)#no shRouter(config-if)#exitRouter(config)#int f1Router(config-if)#ip add 192.168.3.1 255.255.255.0Router(config-if)#no shuRouter(config)#int s0Router(config-if)#clock rate 64000Router(config-if)#ip add 192.168.1.1 255.255.255.0Router(config-if)#no shuRouter(config-if)#end Router#conConfiguring from terminal, memory, or network [terminal]? tRouter(config)#router ospf 11Router(config-router)#network 192.168.1.0 0.0.0.255 area 0Router(config-router)#network 192.168.2.0 0.0.0.255 area 1Router(config-router)#network 192.168.3.0 0.0.0.255 area 1Router(config-router)#endRouter#show ip ospf neighborRouter#show ip interface briefRouter#ping 192.168.1.2Router#show ip protocolsRouter#show ip inter s0Router#ping 192.168.1.2 Router#conConfiguring from terminal, memory, or network [terminal]? tRouter(config)#int loopback 1Router(config-if)#ip add 11.1.1.1 255.255.255.0Router(config-if)#no shRouter(config-if)#exitRouter(config)#in loopback 2Router(config-if)#ip add 11.1.2.1 255.255.255.0Router(config-if)#endRouter#show ip interface brief Router#conConfiguring from terminal, memory, or network [terminal]? t 将Serial 0 封裝PPP Router(config)#int s0Router(config-if)#enca pppRouter(config-if)#exitRouter(config)#hostname AA(config)#username A password star ——此處用戶名和密碼由服務器端定義,用于客戶端驗證A(config)#int s0 封裝類型為 PAP A(config-if)#ppp authentication papA(config-if)#ppp pap sent-username A password star ——發送服務端提供的用戶名和密碼 封裝類型為 CHAP A(config-if)#ppp authentication chapA(config-if)#ppp chap hostname AA(config-if)#ppp chap password starA(config-if)#endA#show inter s0A#show run

,

更多精彩资讯请关注tft每日頭條,我们将持续为您更新最新资讯!

查看全部

相关圖文资讯推荐

热门圖文资讯推荐

网友关注

Copyright 2023-2024 - www.tftnews.com All Rights Reserved