cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2319
Views
0
Helpful
5
Replies

Permanently deleting files on old switch

nicholasacook
Level 1
Level 1

I have a 3560 switch running IOS IPServices 12.2(25) and I needed to delete the current IOS file in flash to make room for the newer IOS version.  I was able to delete the file but when I try and use the "squeeze" command to recover the deleted space, the command is unavailable.  Does anyone know how the older devices would permanently delete files to recover the lost space?

1 Accepted Solution

Accepted Solutions

You need to delete the directory of the IOS to free up the space

 

type 'delete /f /r flash:c3560-i9-mz.122-20.SE1'

View solution in original post

5 Replies 5

Joseph W. Doherty
Hall of Fame
Hall of Fame

Disclaimer

The Author of this posting offers the information contained within this posting without consideration and with the reader's understanding that there's no implied or expressed suitability or fitness for any purpose. Information provided is for informational purposes only and should not be construed as rendering professional advice of any kind. Usage of this posting's information is solely at reader's own risk.

Liability Disclaimer

In no event shall Author be liable for any damages whatsoever (including, without limitation, damages for loss of use, data or profit) arising out of the use or inability to use the posting's information even if Author has been advised of the possibility of such damage.

Posting

I think all the 3560/3750 had the "newer" DOS like file system, i.e. deleting a file frees the space.

What does the directory command show for free space?

You could also reformat the flash.

Here is what is currently showing in Flash:.  As you can see, I am using about 25Kb of data but the difference between my total bytes & bytes free is 7.2Mb which was the size of the old IOS image.  So apparently after issuing the delete command to delete the IOS, it is still taking up space.

 

Switch#dir /all
Directory of flash:/

    2  -rwx         900   Mar 3 1995 18:15:20 +00:00  vlan.dat
    4  -rwx       21372  Mar 20 1995 15:28:48 +00:00  config.old
    6  -rwx        3024  Mar 20 1995 15:28:48 +00:00  private-config.text
   86  drwx         192   Oct 5 2004 19:30:46 +00:00  c3560-i9-mz.122-20.SE1

15998976 bytes total (8353792 bytes free)

You need to delete the directory of the IOS to free up the space

 

type 'delete /f /r flash:c3560-i9-mz.122-20.SE1'

jhager,

 

That did it.  Thanks.

Disclaimer

The Author of this posting offers the information contained within this posting without consideration and with the reader's understanding that there's no implied or expressed suitability or fitness for any purpose. Information provided is for informational purposes only and should not be construed as rendering professional advice of any kind. Usage of this posting's information is solely at reader's own risk.

Liability Disclaimer

In no event shall Author be liable for any damages whatsoever (including, without limitation, damages for loss of use, data or profit) arising out of the use or inability to use the posting's information even if Author has been advised of the possibility of such damage.

Posting

You might be using a lot more the 25KB as your last directory entry is a directory, which may have files and/or subdirectories within it.  First remove that directory and its contents (use a recursive delete).

Review Cisco Networking for a $25 gift card