cisco 2500,1600系列路由器在没有任何配置之前,可以自动启动autoinstall自动配置功能即路由器会自动地到tftp服务器中寻找配置文件,并下载运行。配置文件需要事先编辑好,并存放在tftp服务器的根目录下:
要启动自动配置功能,必须满足以下条件:
Cisco 2500,1600系列路由器的高速同步串口在缺省状态下
封装的协议为Cisco HDLC
注意:如果在HDLC封装的端口无法实现自动配置功能,则路由器会自动在该端口上封装帧中继。
frame-relay map ip新路由器的与该端口的IP地址,本地帧中继地址
自动配置工作过程,如图:

Router A的名字为Kim。
新路由器的名字-confg
这里Router A的配置文件名为Kim-confg
实例:
已配置好的路由器Router B的配置
kim#sho run
Building configuration…
Current configuration:
!
version 11.2
no service udp-small-servers
no service tcp-small-servers
!
hostname kim1
!
boot system flash
boot system rom
!
interface Ethernet0
ip address 10.1.1.1 255.255.255.0
no ip mroute-cache
no ip route-cache
!
internet Serial0
ip address 192.192.192.1 255.255.255.0
iup helper-address 10.1.1.33
!广播地址指向tftp服务器
no ip mroute-cache
no ip route-cache
!本实例用V.35 线缆直连模拟DDN专线,HDLC的配置请参照HDLC 配置章节
bandwidth 2000
! 带宽为2M
clockrate 2000000
!同步时钟
interface Serial1
no ip address
no ip mroute-cache
no ip route-cache
shutdown
!
no ip classless
!
line con 0
line 1 8
transport input all
line aux 0
transport input all
line vty 0 4
login
!
end
network-confg文件的内容:
ip host kim 192.192.192.2
!新路由器RouterA的高速同步串口1的地址与名字映射
ip host try 10.1.2.1
ip host try1 10.1.3.1
kim-confg文件的内容
int e0
ip add 193.1.3.1 255.255.255.0
int e1
ip add 192.1.2.1 255.255.255.0
ip route 0.0.0.0 0.0.0.0 192.192.192.1
RouterA的自动启动过程及启动后的执行配置
%SYS-5-RELOAD:Reload requested
System bootstrap,Version 11.2(10c),SOFTWARE
Copy right © 1986-1996 by cisco Systems
2500 processor with 2048Kbytes of main memory
Notioce:NVRAM invalid, possibly due to write erase.
F3:5173084+61848+255460 at 0x3000060
Restricted Rights Legend
Use,duplication,or disclosure by the Government is subject to restrictions as set forth in subparagraph (c) of the commercial Computer Software –Restricted Rights clause at FAR sec.52.227-19 and subparagraph (c)(1)(ii) of the Rights in Technial Data and Computer Software clause at DFARS sec.252.225-7013.
Cisco Systems,inc.
170 West Tasman Drive
San Jose,california 95134-1706
Cisco internetwork Operating System Software
IOS(tm) 2500 software (c2500-D-L), version 11.2(5),RELEASE SOFTWARE(fc1)
Copyright (c) 1986-1997 by cisco systems inc.
Compiled Mon 31-Mar-97 20:17 by ckralik
Image text-base:0x302a734 data-base:0x00001000
Cisco 2500 (68030) processor (revision L) with 2048K/2048K bytes of memory.
Processor board ID 06246045, with hardware revision 00000000
Bridging software.
X.25 software,version 2.0, NET2 BFE and GOSIP compliant.
2 Ethernet/IEEE 802.3 interface(s)
2 Serial network interface(s)
32K byte of non-volatile configuration memory.
8192K bytes of processor board system Flash (Read ONLY)
Notice: NVRAM invalid, possibly due to write erase.
SLARP: interface Serial resolved. This interface has been automatically resolved thru the SLARP process. The router will now attempt to retrieve its name and configuration file.
Loading network-config from 10.1.1.33 (via Serial1):!
!新路由器RouterA在tftp服务器中找到network-confg文件
[OK – 74/32723 bytes]
configuration mapped ip address 192.192.192.2 to kim
! 新路由器RouterA的名字为kim,地址为192.192.192.2
Loading kim-confg from 10.1.1.33 (via serial1):!
[OK –122/32723 bytes]
! 新路由器RouterA从tftp服务器中成功下载自己的配置文件,名为kim-confg
SETUP:new interface Serial0 placed in “shutdown” state
Press RETURN to get started!
%LINK – 5 –SLARP: Serial1 address 192.192.192.2, resolved by 192.192.192.1
%LINK – 3 –UPDOWN interface Ethernet0, changed state to up
%LINK – 3 –UPDOWN interface Ethernet1, changed state to up
%LINK – 3 –UPDOWN interface serial0, changed state to down
%LINK – 3 –UPDOWN interface serial1, changed state to up
%LINEPROTO-5-UPDOWN:line protocol on interface ethernet0,changed state to down
%LINEPROTO-5-UPDOWN:line protocol on interface ethernet1,changed state to down
%LINEPROTO-5-UPDOWN:line protocol on interface serial0,changed state to down
%LINEPROTO-5-UPDOWN:line protocol on interface serial1,changed state to up
%PARSER-4-BADCFG: Unexpected end of configuration file.
%SYS-5-CONFIG: Configuration from network-confg by console tftp from 10.1.1.33
%SYS-5-CONFIG: Configuration from kim-confg by console tftp from 10.1.1.33
%SYS-5-RESTART: System restarted –
cisco internet work Operating System Software
IOS (tm) 2500 software (C2500-D-L), Version 11.2(5), RELEASE SOFTWARE (fc1)
Copyright (c) 1986-1997 by cisco system, Inc.
Compiled Mon 31-Mar-97 20:17 by ckralik
%LINK
– 5 –CHANGED: interface Serial0, changed state to administratively downkim > en
!新路由器RouterA的配置
kim#sho run
Building configuration
…Current configuration:
!
version 11.2
no service udp-small-servers
no service tcp
–small-servers!
hostname kim
!
!
ip host kim 192.192.192.2
ip host try 10.1.2.1
ip host try1 10.1.3.1
!
interface Ethernet0
ip address 192.1.3.1 255.255.255.0
!
interface Ethernet1
ip address 192.1.2.1 255.255.255.0
!
interface Serial0
no ip address
shutdown
!
interface Serial1
ip address 192.192.192.2 255.255.255.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 192.192.192.1
!
line con 0
line aux 0
line vty 0 4
login
!
如果线路没有接好,或A
utoinstall功能被错误地启动,或错误启动自动下载配置文件功能时,路由器会不停地寻找几个文件。如下:%SYS-5-RELOAD:Reload requested
System Bootstrap.Version 11.0(10c),SOFTWARE
Copyright(c) 1986-1995 by cisco systems
2500 process with 2048 Kbytes of main memory
%SYS-4-CONFIG_NEWER: Configurations from version 11.2 may not be correctly under stood。
F3:5173084+61848+255460 at 0x3000060
Restricted rights legend
Use,duplication, or disclosure by the Government is subject to restrictions as set forth in subparagraph (c) of the Commercial Computer Software -Restricted Rights clause at FAR sec.52.227-19 and subparagraph (c) (1) (ii) of the Rights in Technical Data and Computer Software clause at DFARS sec.252.227-7013.
cisco Systems.Inc.
170 West Tasman Drive
San jose.California 95134-1706
Cisco Internet work Operating System Software
IOS (TM) 2500 Software (c2500-D-L),version 11.2(5),RELEASE SOFTWARE (fc1)
Copyright (c) 1986-1997 by cisco Systems.Inc.
Compiled Mon 31-Mar-97 20:17 by ckralik
Image test-base: 0x0302 A 734,data-base: 0x00001000
cisco 2509 (68030) processor (revision M)with 2048K/2048K bytes of memory.
Procesor board ID 06900170.with hardware revision 00000000
Bridging software.
X.25 software.Version 2.0,NET2, BFE and GOSIP compliant.
1 Ethernet/IEEE 802.3 interface(s)
2 Serial network interfaces
8 teminal line(s)
32K bytes of non-volatile configuration memory.
8192K bytes of processor board System flash (Read ONLY)
Loading network-confg[timed out]
Loading cisconet.cfg [timed out]
Loading kim-confg [timed out]
Loading kim.cfg [timed out]
这时应断掉所有线路,在没有封锁BREAK情况下,重新启动路由器并在WIN95或NT的超级终端下键入CTRL+BREAK键,进入RXBOOT模式,并修改寄存器值到0x42并重新初始化。(此上步骤与上面的处理口令丢失的步骤一样)可以将原有配置全部删掉。
在超级权限状态下
write erase 回车
并将寄存器值改回到0x2102,并重新启动或在全局设置模式下设置
no service config
cofing - register 0x2102 (疑应为config-register 0x2102,但原文如此)
之后重新启动。
命令行规则:
如:interface serial 0
完全可以写成 int s 0
2.在任何模式下,打一个
3.如果不会正确拼写某个命令,可以键盘入开始的几个字母,在其后紧跟一个问号,路由器即提示有什么样的命令与其匹配。
4.如不知道命令行后面的参数应为什么,可以在该命令的关键字后空一个格,键盘入
“?”,路由器即会提示你与“?”对应的位置的参数是什么。如:copy ? 或copy run ?
5.要去掉某条配置命令,在原配置命令前加一个no并空一个格,如要去掉前面提到的boot system flash,在相同模式下,可以键盘入no boot system flash。