Flash Cleanup
Automated detection and safe removal of unused IOS images
Overview
Flash Cleanup identifies and removes IOS image files from device flash storage that are no longer needed - old images that were superseded by upgrades, duplicate copies left by failed transfers, or inactive Install Mode packages. Freeing flash space is a prerequisite for new upgrades and is required as part of regular maintenance hygiene.
Scanning for Unused Files
The scanner connects to each device, runs show flash:, and identifies files that are safe to remove.
What is flagged for removal
- IOS/IOS-XE image files (
.bin) not referenced by the boot variable - Old Install Mode packages not in the active or committed install state
- Temporary files (
.tmp, partial transfers) - Duplicate files with identical content
Running a scan
Stack-Aware Cleanup
For stacked switches (e.g. Catalyst 3750, 9300 stacks), each stack member has its own flash. NetGUI is stack-aware and scans all members simultaneously.
- The scan aggregates flash usage across all stack members.
- Files are listed per-member with the member number clearly labeled.
- Deletion is performed on each member where the file exists.
- The active image on the stack master and all members is always protected.
Batch Device Cleanup
Run flash cleanup across hundreds of devices in a single operation.
- Select all target devices using group filters (e.g. all switches at a site, or all devices upgraded in the last 90 days).
- Run the scan to preview what will be removed across the entire batch.
- Review the aggregate summary: total devices, total files, total MB to be reclaimed.
- Click Batch Delete. NetGUI processes devices in parallel with a configurable concurrency limit (default: 10 simultaneous sessions).
- A per-device result summary is available after completion.
Install Mode Cleanup
For Catalyst 9000 devices in Install Mode, unused packages accumulate after each upgrade commit. These are removed with the install remove inactive command.
NetGUI identifies Install Mode devices automatically during scanning and uses the correct cleanup method for each device type:
- Bundle Mode devices:
delete /force flash:{filename} - Install Mode devices:
install remove inactive
Safety Rules
The following files are always protected and will never be flagged or deleted by Flash Cleanup regardless of configuration:
- The currently active IOS/IOS-XE image (as reported by
show version) - Any image referenced in the current boot variable (
show boot) - The committed Install Mode package set
- The running configuration file
- VLAN database files (
vlan.dat) - Private configuration files
All deletions are logged in the Activity Log with the filename, file size, device, and the user who initiated the cleanup.