Basic Operation Guide 2014/02

This option erases the specified startupconfig file. If the specified file is not the
currently active startup-config file, then the file is simply deleted from the memory
slot it occupies. If the specified file is the currently active startup-config file, then the
switch creates a new, default startup-config file with the same name as the erased
file, and boots using this file. (This new startup-config file contains only the default
configuration for the software version used in the reboot.)
NOTE: Where a file is assigned to either the primary or the secondary flash, but
is not the currently active startupconfig file, erasing the file does not remove the
flash assignment from the memory slot for that file. Thus, if the switch boots using
a flash location that does not have an assigned startup-config, then the switch
creates a new, default startup-config file and uses this file in the reboot. (This new
startup-config file contains only the default configuration for the software version
used in the reboot.) Executing write memory after the reboot causes a
switch-generated filename of config x to appear in the show config files
display for the new file, where x corresponds to the memory slot number.
startup-config:
This option erases the currently active startupconfig file and reboots the switch from
the currently active flash memory location. The erased startup-config file is replaced
with a new startup-config file. The new file has the same filename as the erased
file, but contains only the default configuration for the software version in the flash
location (primary or secondary) used for the reboot. For example, suppose the last
reboot was from primary flash using a configuration file named minconfig.
Executing erase startup-config replaces the current content of minconfig
with a default configuration and reboots the switch from primary flash.
The example below illustrates using erase config <filename> to remove a startup-config
file.
Example 60 Erasing a non-active startup-config file
HP Switch(config)# show config files
Configuration files:
id | act pri sec | name
---+-------------+-----------------------------------------------
1 | * * | minconfig
2 | * | config2
3 | | config3
HP Switch(config)# erase config config3
HP Switch(config)# show config files
Configuration files:
id | act pri sec | name
---+-------------+-----------------------------------------------
1 | * * | minconfig
2 | * | config2
3 | |
With the same memory configuration as is shown in the bottom portion of the above example,
executing erase startup-config boots the switch from primary flash, resulting in a new file
named minconfig in the same memory slot. The new file contains the default configuration for the
software version currently in primary flash.
Multiple configuration files 79