Factory Reset

Factory reset procedures

A factory reset procedure is a device restoration method that

  • erases all customer-specific data stored in a device

  • restores the device to its original configuration at the time of shipping, and

  • removes configurations, log files, boot variables, core files, and credentials such as FIPS-related keys.

Data erased and retained during factory reset

The factory reset process is used in the following scenarios:

  • Return Material Authorization (RMA) for a device: If you have to return a device to Cisco for RMA, remove all the customer-specific data before obtaining an RMA certificate for the device.

  • Recovering a compromised device: If the key material or credentials that are stored on a device are compromised, reset the device to the factory configuration, and then reconfigure the device.

During a factory reset, the device reloads and enters ROMMON mode. After the factory reset, the device removes all its environment variables, including the MAC_ADDRESS and the SERIAL_NUMBER variables, which are required to locate and load the software. Perform a reset in ROMMON mode to automatically set the environment variables. The BAUD rate environment variable returns to its default value after a factory reset. Make sure that the BAUD rate and the console speed are the same at all times. Otherwise, the console becomes unresponsive.

After the system reset in ROMMON mode is complete, add the Cisco IOS image either through an USB or TFTP.

Table 1. Data erased and retained during factory reset

Data erased

Data retained

All Cisco IOS images, including the current boot image

Data from remote field-replaceable units (FRUs)

Crash information and logs

Value of the configuration register.

User data, startup and running configuration, and contents of removable storage devices, such as SERIAL Advanced Technology Attachment (SATA), Solid State Drive (SSD), or USB

Credentials such as FIPS-related keys

Credentials such as Secure Unique Device Identifier (SUDI) certificates, and public key infrastructure (PKI) keys.

Onboard Failure Logging (OBFL) logs

Licenses

ROMMON variables added by a user.


Note


When you perform a factory reset, none of the memory components on a line card are erased. This means the system software, OBFL, bootloader, and environmental variables on the line card, remain as is.


Restrictions for performing a factory reset

  • Software patches, if installed on the device, are not restored after the factory reset process.

  • If the factory-reset command is issued through a VTY session, the session is not restored after completion of the factory reset process.

Secure data wipes

A secure data wipe is a device storage sanitization method that

  • removes software images, device configuration, software logs, and operational history

  • eliminates customer-specific data, including network architecture and design, and

  • renders information unrecoverable by following NIST SP 800-88 PURGE guidelines.

Secure data wipe reference information

The all secure option in the factory-reset command performs data sanitization and securely resets the device. After data sanitization, the device reloads and boots with the software image present in flash.

Secure data wipe feature implements guidelines for media sanitization as described in NIST SP 800-88 Rev. 1. NIST 800-88 is a standard published by the National Institute of Standards and Technology (NIST) that provides guidelines for media sanitization. The PURGE standard within NIST 800-88 specifies methods to render data on storage media unrecoverable using laboratory techniques. When a device is sanitized using NIST 800-88 PURGE method, data cannot be recovered through simple non-invasive data recovery techniques or advanced laboratory techniques.

Configure factory reset

Performing a factory reset erases all configuration and user data from your Switch, restoring it to its original shipping state.

Use this procedure when you need to completely erase all configurations, images, and user data from your switch, such as before decommissioning, repurposing, OR troubleshooting persistent issues.

This process is applicable to standalone, stacked, and StackWise Virtual enabled Switchs.

Before you begin

  • Ensure that all the software images, including the current image, configurations, and personal data are backed up before you begin the factory reset process.

  • Ensure that there is uninterrupted power supply when the factory reset process is in progress.

  • Ensure that In-Service Software Upgrade (ISSU) or In-Service Software Downgrade (ISSD) are not in progress before you begin the factory reset process.

Perform these steps to perform a factory reset:

Procedure


Step 1

Use the enable command to enable privileged EXEC mode.

Example:

Switch> enable

Enter your password, if prompted.

Step 2

Use the factory-reset command to perform factory reset to reset the switch to its configuration at the time of its shipping.

Example:

Switch# factory-reset all

OR

Switch# factory-reset switch 1 all config

OR

Switch# factory-reset all secure

The available options are:

  • all : Erases all the content from the NVRAM, all the Cisco IOS images, including the current boot image, boot variables, startup and running configuration data, and user data. We recommend that you use this option.

  • all secure : Performs data sanitization and securely resets the Switch.

    Note

     
    • You can use the all secure option only on standalone Switchs.

    • This option implements guidelines for media sanitization as described in NIST SP 800-88 Rev. 1.

    • The factory-reset all secure command initiates data sanitization. The booted image of the Switch is retained.

    • When data sanitization is completed, the Switch reloads, and the Switch image is retained in flash if it was booted with an image from the flash.

  • secure 3-pass : Erases all the content from the Switch with 3-pass overwrite.

    • Pass 1: Overwrites all addressable locations with binary zeroes.

    • Pass 2: Overwrites all addressable locations with binary ones.

    • Pass 3: Overwrites all addressable locations with a random bit pattern.

    Note

     

    This option takes approximately thrice the time taken to perform any other option.

  • config : Resets the startup configurations.

  • boot-vars : Resets the user-added boot variables.

  • switch {switch-number | all} :

    • switch-number : Specifies the switch number. The range is from 1 to 16.

    • all : Selects all the switches in the stack.

Note

 
The factory reset operation permanently erases all device configurations and security keys (including FIPS keys), restoring the device to its original factory-default state. Reload the switch after the execution of factory-reset config command.

After the factory reset process is successfully completed, the switch reboots and enters ROMmon mode.

Step 3

(Optional) Use the show platform software factory-reset secure log command to verify the data sanitization report after factory reset.

Example:

Switch# show platform software factory-reset secure log
Factory reset log:
#CISCO xxxxx DATA SANITIZATION REPORT#
START : 18-09-2022, 06:18:44
END : 18-09-2022, 06:23:36
-MTD-
PNM : nor
NIST : PURGE
-eMMC-
MID : 'Micron'
PNM : 'Q2J55L'
SN : 0x00000001
NIST : PURGE

Feature history for factory reset

This table provides release and related information for features explained in this module.

These features are available on all releases subsequent to the one they were introduced in, unless noted otherwise.

Release

Feature

Feature Information

Cisco IOS XE 26.1.1

Factory reset

Factory reset restores the switch to its original shipping state by erasing customer-specific data, configurations, logs, boot variables, and credentials such as FIPS-related keys.

Use Cisco Feature Navigator to find information about platform and software image support. To access Cisco Feature Navigator, go to http://www.cisco.com/go/cfn.