Sign up and stay connected to your favorite communities.

sign uplog in
Posted by
10 days ago

(how to) Upgrade code on a 2960x?

Hey /r/networking!

So, my first time upgrading code on a cisco switch (single device in our lab/staging area). I've read a bunch of different ways to do this, and all seem to offer conflicting or assuming someone would know additional information.

I've downloaded the code to install (c2960x-universalk9-mz.152-2.E7.bin), and I have the tftp server running on my workstation. I'm just wanting to make sure I do this right.

Could someone give me a quick step-by-step guide I can walk through to make sure I don't hork it?

54% Upvoted
What are your thoughts? Log in or Sign uplog insign up

Very easy to do:

  • copy tftp:<file name> flash:<file name>

  • ip of tftp server

  • enter to keep file name same in flash

Once copied:

  • config t

  • boot system flash:<file name>

  • exit

  • write mem

  • reload

Switch will boot to new IOS, and you can remove the old IOS from flash after it boots up.

Original Poster1 point · 10 days ago

That's gloriously easy... wish that other walkthrough pages were that simple.

Thank you!

You’re welcome!

Original Poster1 point · 10 days ago

Question - do the 2960x's support USB copy of code files? I couldn't find much on the CLI or online that supports it; I can see the USB drive when I plug it in, just can't figure out how to copy or show a file list on it.

actually they do!

copy usbflash0:/image.bin flash:

Was this changed at some point in the 15.2 train? Haven’t tried it since 15.0, and it didn’t work back then. Awesome if they did add this.

CCNP R&S / CCNA Security
1 point · 9 days ago

They've had it for a while now actually; if it's got a USB Type A port you can copy the file over. Been doing it for ages with our 3750Xs.

Original Poster1 point · 10 days ago

well, shit it does... at least on the version I'm on now, I swore it wasn't there before... :: shrug ::

Yeah USB is much easier and 2960x is one of the easiest switches to upgrade.

No, they don’t. They support using a USB cable in place of the standard console cable, but they don’t mount a USB flash directory like the 3850 or 4500X to copy to onboard flash.

Original Poster1 point · 10 days ago

glar... I figured that was the answer.

So I'm doing the xfer now - this looks ... odd to me... ?

122185728 bytes total (98652160 bytes free)

ModelOp-2960#copy tftp flash:

Address or name of remote host []?

Source filename []? c2960x-universalk9-mz.152-2.E7.bin

Destination filename [c2960x-universalk9-mz.152-2.E7.bin]?

Accessing tftp://


Is there an issue with communicating with the tftp server? Looks like it continued eventually. If it fails, you may want to make sure there is enough space in flash for the new file.

Original Poster2 points · 10 days ago

Sorry for keeping this going - the MD5 hash checked out, and I'm reloading the switch after setting the boot system file. Thanks for the help on this again, hopefully all is good now :)

You’re welcome - happy to help!

Original Poster1 point · 10 days ago

it's still going, it's been xferring for the last 45 minutes... which shouldn't be me thinks. the devices are all on the same physical LAN, and routing is all there, so not sure why it's running so damn slow.

one thing I saw said to delete the old code before tftp'ing the new... if this fails, I'll try that next.

I wouldn’t do that. The 2960X can easily hold two versions. That was really only an issue on the 3750G, 3750V2.

Yes, that is a long time on what I assume is a 1G LAN.

Original Poster1 point · 10 days ago

so I killed the TFTP server and restarted it - either it was mostly done, or it grabbed and finished it fast. gonna MD5 that thing to confirm.

If something goes sideways, you can always just boot an image on the flash drive from rommon and then attempt the copy again.

Then we've been doing it wrong because we copy our IOS files over from a flash drive all the time.

I’d add that if they are in stack you can reduce downtime and pre copy the image to all the slave flashes instead of letting it do it during boot.

Show switch to find the master.

Copy flash:file flash2:file

Replacing the 2 for each switch number not the master.

Personally, I like the archive command:

archive download-sw { /directory | /force-reload | /imageonly | /leave-old-sw | /no-set-boot | /no-version-check | /destination-systemstack-member-number | /only-system-typesystem-type | /overwrite | /reload | /safe} source-url

Examples help:

archive download-sw /overwrite tftp://

Original Poster1 point · 9 days ago

Could you simplify this a bit? If we wanted to run the command on a remote switch to have it download the upgrade file, write mem, then reload on the new version?

archive download-sw /overwrite /reload tftp://

Original Poster1 point · 9 days ago

Bless you good sir (ma'am?)! much appreciated!

Make sure you save your config before you run it. Otherwise I think the reload aborts.

Original Poster1 point · 9 days ago

right - write mem and backup external copy before going forward! :)

FWIW, http will usually transfer quicker than tftp, but you need a webserver to host the bin. example: copy flash:

Original Poster1 point · 9 days ago

hmm... good to know!

Community Details





###Enterprise Networking Routers, switches and firewalls. Network blogs, news and network management articles. Cisco, Juniper, Brocade and more all welcome.

Create Post

r/networking Rules

Rule #1: No Home Networking.
Rule #2: No Certification Brain Dumps / Cheating.
Rule #3: No BlogSpam / Traffic re-direction.
Rule #4: No Low Quality Posts.
Rule #5: No Early Career Advice.
Rule #6: Educational Questions must show effort.
Cookies help us deliver our Services. By using our Services or clicking I agree, you agree to our use of cookies. Learn More.