Chinaunix首页 | 论坛 | 博客
  • 博客访问: 321957
  • 博文数量: 41
  • 博客积分: 1606
  • 博客等级: 上尉
  • 技术积分: 535
  • 用 户 组: 普通用户
  • 注册时间: 2007-12-28 18:20
文章分类

全部博文(41)

文章存档

2013年(1)

2012年(8)

2011年(4)

2010年(8)

2009年(2)

2008年(18)

我的朋友

分类: 系统运维

2008-05-21 10:07:35

     以下操作在Cisco Catalyst 3560上操作通过,对于Cisco 两层及三层交换机都有效。    
     一、准备工作:
1.我们首先用console线连接到交换机机,超级终端设置如下:
    Bits per second (baud): 9600
    Data bits: 8
    Parity: None
    Stop bits: 1
    
2.启动交换机,并按下前面板MODE按键(大概十五秒),此时"sys"指示灯会不停地闪,直到"sys"常绿的时候松手,然后可以从终端中看到我们已经进入了switch:模式了.
   二、以下七步完成操作:
1.下面我们首先要加载flash_init
    命令如下:
    switch: flash_init
    Initializing Flash...
    flashfs[0]: 143 files, 4 directories
    flashfs[0]: 0 orphaned files, 0 orphaned directories
    flashfs[0]: Total bytes: 3612672
    flashfs[0]: Bytes used: 2729472
    flashfs[0]: Bytes available: 883200
    flashfs[0]: flashfs fsck took 86 seconds
    ....done Initializing Flash.
    Boot Sector Filesystem (bs: ) installed, fsid: 3
    Parameter Block Filesystem (pb: ) installed, fsid: 4
    switch:
    
2.输入load_helper
    命令如下:
    switch: load_helper
    switch:
    
3.我们来看一下flash:
    switch: dir flash:
    Directory of flash:/
    2 -rwx 1803357 c3500xl-c3h2s-mz.120-5.WC7.bin
    
    !--- This is the current version of software.
    
    4 -rwx 1131 config.text
    
    这时候大家看到有一个config.text文件.接下来我们就需要对它进行修改为:config.old(当然改成其它名字也行)
    
    命令如下:
    switch: rename flash:config.text flash:config.old
    switch:
        
4.修改基本完成.下面我启动IOS一下
    命令如下:
    switch: boot
    Loading "flash:c3500xl-c3h2s-mz.120-5.WC7.bin"...###############################
    ################################################################################
    ######################################################################
    File "flash:c3500xl-c3h2s-mz.120-5.WC7.bin" uncompressed and installed, entry po
    int: 0x3000
    executing...
    
5.启动后.你会看到熟悉的Continue with configuration dialog? [yes/no]:
填写n后.进入交换机.
    Switch>en
    Switch#
    
6.完成密码修改:
6.1 将刚才改的config.old改回来.
    命令如下:
    Switch#rename flash:config.old flash:config.text 
6.2 覆盖当前密码,命令如下:
    Switch# conf t
    !--- 覆盖secret密码
     Switch(config)#enable secret
       !--- 覆盖enable密码
    Switch(config)#enable password
       !--- 覆盖vty密码
    Switch(config)#line vty 0 15
    Switch(config-line)#password
    Switch(config-line)#login
       !--- 覆盖console密码
       Switch(config-line)#line con 0
      Switch(config-line)#password
7.保存设置:
      Switch#write memory
      Building configuration...
      [OK]
      Switch#

 
Cisco参考链接:

 
 
阅读(1112) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~