"Mert a csomagok sosem hazudnak."

IOS frissítés – ha nincs elég hely a flash-en

IOS-t frissíteni (szerintem) egyszerű. TFTP-ről átteszed flash-re, boot system-et beállítod, megboot-olod, és kész. De mi van, ha nincs elég hely a flash-en?

Trying 10.10.10.10...
Connected to C3750S
Escape character is '^]'.

C3750S line 1 telnet
Username: fecogee
Password:
C3750S#sh flash:
Directory of flash:/
2 -rwx 744 Oct 10 2011 15:03:55 +02:00 vlan.dat
 3 -rwx 5 Jul 30 2012 14:15:39 +02:00 private-config.text
 4 -rwx 1048 Jul 30 2012 14:15:39 +02:00 multiple-fs
 5 drwx 192 Mar 1 1993 01:06:46 +01:00 c3750-ipservices-mz.122-35.SE5
 510 -rwx 11172 Jul 30 2012 14:15:39 +02:00 config.text
15998976 bytes total (5476864 bytes free)

5,47 MB. Nem elég egy új 3750 IOS-hez (~ 8 MB). Törölni kell a régit, feltenni az újat, és beállítani a boot-ot.

3750S#sh ver
Cisco IOS Software, C3750 Software (C3750-IPSERVICES-M), Version 12.2(35)SE5, RELEASE SOFTWARE (fc1)
Copyright (c) 1986-2007 by Cisco Systems, Inc.
Compiled Thu 19-Jul-07 19:15 by nachen
Image text-base: 0x00003000, data-base: 0x01280000
ROM: Bootstrap program is C3750 boot loader
BOOTLDR: C3750 Boot Loader (C3750-HBOOT-M) Version 12.2(25r)SEE3, RELEASE SOFTWARE (fc1)
C3750S uptime is 15 weeks, 8 hours, 57 minutes
System returned to ROM by power-on
System restarted at 06:47:34 CET-DST Thu May 3 2012
System image file is "flash:c3750-ipservices-mz.122-35.SE5/c3750-ipservices-mz.122-35.SE5.bin"
........

Switch Ports Model SW Version SW Image 
------ ----- ----- ---------- ---------- 
* 1 12 WS-C3750G-12S 12.2(35)SE5 C3750-IPSERVICES-M

Configuration register is 0xF

Töröljük az image-t:

C3750S#delete flash:c3750-ipservices-mz.122-35.SE5/c3750-ipservices-mz.122-35.SE5.bin
Delete filename [c3750-ipservices-mz.122-35.SE5/c3750-ipservices-mz.122-35.SE5.bin]? 
Delete flash:c3750-ipservices-mz.122-35.SE5/c3750-ipservices-mz.122-35.SE5.bin? [confirm]

Töröljük a könyvtárát:

C3750S#delete /force /recursive q   flash:c3750-ipservices-mz.122-35.SE5

Nézzük meg a flash tartalmát és a szabad helyet:

C3750S#sh flash:
Directory of flash:/
2 -rwx 744 Oct 10 2011 15:03:55 +02:00 vlan.dat
 3 -rwx 5 Jul 30 2012 14:15:39 +02:00 private-config.text
 4 -rwx 1048 Jul 30 2012 14:15:39 +02:00 multiple-fs
 510 -rwx 11172 Jul 30 2012 14:15:39 +02:00 config.text
15998976 bytes total (15983616 bytes free)

Ez már elég hely.

Másoljuk fel az új IOS-t:

C3750S#copy tftp://10.10.10.1/IOS-NXOS/SSH/c3750-ipservicesk9-mz.122-35.SE5.bin flash:c3750-ipservicesk9-mz.122-35.SE5.bin
Destination filename [c3750-ipservicesk9-mz.122-35.SE5.bin]? 
Accessing tftp://10.10.10.1/IOS-NXOS/SSH/c3750-ipservicesk9-mz.122-35.SE5.bin...
Loading IOS-NXOS/SSH/c3750-ipservicesk9-mz.122-35.SE5.bin from 10.10.10.1 (via GigabitEthernet1/0/11): !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!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!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
[OK - 8638247 bytes]
8638247 bytes copied in 125.267 secs (68959 bytes/sec)

Ellenőrizzük, hogy nem sérült -e:

C3750S#verify flash:c3750-ipservicesk9-mz.122-35.SE5.bin
Verified flash:c3750-ipservicesk9-mz.122-35.SE5.bin

Állítsuk be a boot-hoz az új IOS-t:

C3750S#conf t
Enter configuration commands, one per line. End with CNTL/Z.
C3750S(config)#boot system flash:c3750-ipservicesk9-mz.122-35.SE5.bin
C3750S(config)#^Z

Ellenőrizzük, hogy érvényesült-e:

C3750S#sh fla boot
BOOT path-list : flash:c3750-ipservicesk9-mz.122-35.SE5.bin
Config file : flash:/config.text
Private Config file : flash:/private-config.text
Enable Break : no
Manual Boot : no
HELPER path-list : 
Auto upgrade : yes
Auto upgrade path :

Mentsünk:

C3750S#wr
Building configuration...
[OK]!

Most pedig:

reload

és már az új IOS-szel indul a switch!

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.