#

Wednesday, July 26, 2017

Correct Way to Factory Reset Cisco AP (Clear Configurations Completely)

If you have tried to clear old configurations / reset using mode button of a Cisco Lightweight AP and tried to join it to a new WLC, you may have experienced that it is not clearing it's old configurations completely. May be it will join the previous controller again. Sometimes only IP address is clearing, primary controller address is still visible in SET variables. Well, this is the correct way to completely reset it..


The AP I am using is a Cisco 2602i which is a very common AP.

01. First console the AP and log in with username and password, go to privilege mode..

Default Username: Cisco
Default Password: Cisco
Default Enable Password: Cisco

02. Unlock hidden commands..

Because erase command is hidden, you will need to unlock it by the following command.
AP#debug capwap console cli

Note:- 

This command can be used to go to config mode of a Cisco Lightweight AP too.

03. Erase NVRAM.

NVRAM is where the startup configuration file is located and where the AP maintains the list of previously learned WLC IPs.






Hit the following command to erase the nvram..
AP#erase /all nvram:

After erasing nvram, it will be like this..




04. Delete the Flash or env_vars file in Flash..

Hit a dir flash:/ to see what is inside it..















If you really want to get your AP to fresh factory reset, you will issue the following command to erase full flash with all the files in it. But proceed with caution because it wipes out the OS too.

Hit the following command to delete flash..
AP#delete /force /recursive flash:

Note:- 

Flash is where the IOS image and the recovery OS image are stored. If you issue the above command it will wipe out both images. So you will have to upload the recovery image from a TFTP server (your PC) after doing this in rommon mode. If you want to know how to do it please refer this.

A brand new AP comes with a recovery image only. It will download the IOS image from the WLC after it joined one.

So if you don't want to delete the OS, but if you need to clear all the old configurations, hit the following command to delete the SET variables.. (you can delete these files in rommon mode too)
AP#delete flash:/env_vars

To delete usernames/passwords (you can delete these files in rommon mode too)
AP#delete flash:/private-multiple-fs

This file is where the set variables are stored. If you don't delete this some of the set variables will be intact even after you reset pushing the mode button.

05. Reset AP using the Mode button

Unplug and plug again the power source of the AP holding the mode button..
Release it after the LED turns steady red.. (about 10 seconds)

Now issue set command and you can see all the set variables are also cleared..
If you did not delete the entire Flash, you can give the following command to set the IOS image to bootup instead of recovery image.

ap:set BOOT flash:/<image-directory>/<image>

In my case it is set BOOT flash:/ap3g2-k9w8-mx.153-3.JBB1/ap3g2-k9w8-mx.153-3.JBB1

6 comments:

  1. Hi colleagues, its fantastic post about teachingand entirely explained,
    keep it up all the time.

    ReplyDelete
  2. Appгeciate tһe recommendation. Willl tгy іt out.

    ReplyDelete
  3. I’m not that much of a internet reader to be honest but your
    sites really nice, keep it up! I'll go ahead and bookmark
    your website to come back later. Cheers

    ReplyDelete
  4. Hello this is kind of of off topic but I was wondering
    if blogs use WYSIWYG editors or if you have to
    manually code with HTML. I'm starting a blog soon but have no coding experience so
    I wanted to get advice from someone with experience.
    Any help would be greatly appreciated!

    ReplyDelete
  5. I have learn several excellent stuff here.
    Definitely worth bookmarking for revisiting. I
    wonder how much effort you place to create this
    sort of excellent informative site.

    ReplyDelete
  6. My spouse and I stumbled over here from a different webb pae and tthought I might as well check thinngs out.
    I like what I see so i am just following you. Look forward to exploring your web page repeatedly.

    ReplyDelete