Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Removing directories

Is there any easy way to remove a directory to create space in the flash, without having to delete everysingle file in it first?

rmdir does not work if there are files in the directory.

thks

1 ACCEPTED SOLUTION

Accepted Solutions
Cisco Employee

Re: Removing directories

Doing this will break your HTML management interface. But the command would be:

delete /recursive /force flash:/c2940-i6q4l2-mz.121-22.EA6/html/images

6 REPLIES
Cisco Employee

Re: Removing directories

You can use the /recursive option to delete:

delete /recursive flash:dir

You can also pass /force if you do not want to confirm each file:

delete /recursive /force flash:dir

New Member

Re: Removing directories

HI,

I must be doing something wrong. Tried what you said but it does not seem to be doing any deleting.

I am attaching a file showing my directory structure.

What I am trying to do is to delete the directory "images" under flash:/c2940-i6q4l2-mz.121-22.EA6.bin/html/images

Cisco Employee

Re: Removing directories

Doing this will break your HTML management interface. But the command would be:

delete /recursive /force flash:/c2940-i6q4l2-mz.121-22.EA6/html/images

New Member

Re: Removing directories

Thats great. I do not use the html interface.

So in theory I could delete the html directory directly and that would delete the images directory underneath it.

Thanks again.

Cisco Employee

Re: Removing directories

That is correct.

In the future, if you don't want the HTML interface, just download the .bin images from Cisco.com.

New Member

Re: Removing directories

The problem is Cisco ships all the switches with these html images as default. I have tried to get them to not do it, but it would be too expensive and I guess a nightmare for them too.... (even tho, I am ordering abt 500 switches from them a year!)

155
Views
5
Helpful
6
Replies