思科路由器的自動安裝 |
發布時間: 2012/7/11 13:41:15 |
Cisco 路由器的自動安裝
IOS的路由在啟動時,如果是一個空配置的狀態,那么其輝嘗試著去講以太網接口,串行接口打開I,進而通過RARP/BOOTP或者SLARP(串行鏈路ARP)獲得本段接口IP.在獲得接口IP地址之后,會發起TFTP廣播數據報文請求。 在以下實驗R2仿真為一臺TFTP server,任何R3作為1臺沒法通過console訪問的路由器。 R1(config)#interface loopback 0 R1(config-if)#ip address 1.1.1.1 255.255.255.0 R1(config-if)#ip ospf network point-to-point R1(config-if)#interface serial 1 R1(config-if)#ip address 13.1.1.1 255.255.255.0 R1(config-if)#clockrate 64000 R1(config-if)#interface serial 0 R1(config-if)#ip address 12.1.1.1 255.255.255.0 R1(config-if)#clock rate 64000 R1(config-if)#router ospf 10 R1(config-router)#network 0.0.0.0 255.255.255.255 area 0 R2(config)#interface serial 1 R2(config-if)#ip address 12.1.1.2 255.255.255.0 R2(config-if)#interface loo 0 R2(config-if)#ip address 2.2.2.2 255.255.255.0 R2(config-if)#ip ospf network point-to-point R2(config-if)#router ospf 10 R2(config-router)#network 0.0.0.0 255.255.255.255 area 0 我 們預計到R3重起之后,會通過SLARP獲得IP地址,之后R3會發出反駁地址請求TFTP服務器,要求下載配置文件,我們讓R1將廣播請求轉發給R2, 注意路由器(R3)會依次嘗試HDLC---PPP----Frame-relay封裝,如匹配對端鏈路協議UP,就發出SLARP,得到的IP為對端的 IP減1,如對端IP為最低位,則會加,這這個例子里,R1的IP為13.1.1.1,因此R3解析出自身的IP就是13.1.1.2. (1) 配置R1將將TFTP的廣播請求轉發給R2. R1(config-if)#ip helper-address 2.2.2.2 (2) 修改R3寄存器只,使之從NVRAM讀取配置文件,在R3配置為空的情況下,重起R3 R3(config)#config-register 0x2102 R3#erase startup-config Erasing the nvram filesystem will remove all configuration files! Continue? [con 本文出自:億恩科技【www.laynepeng.cn】 |