ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Main Area and Open Discussion > General Software Discussion

How can I delete over 6,000 recursive directories?

(1/5) > >>

Jammo the OrganizedFellow:
Around 3-4 months ago, my wifes phone (Motorola Defy) suddenly slowed to a pathetic crawl.
It would take forever to accomplish anything. She didn't know why, but I suspected some rogue app.
I forget all the steps I took to isolate the condition, but I found that the camera would store every photo in its own directory. Plus it did the same for thumbnails.
Long terrible situation > short ... her phone no longer works.
Now, at this time, she only had her phone for about 4-5 months. TOPS!!!
She used the camera regularly, nothing outrageous.
I made a backup of her 8GB microSD card.
It was filled to the max!
WTF?

I ran Microsoft Security Essentials on this backup folder.
When it finished, it reported no issues. But it DID scan 12,408 directories.
FRIGGIN' CRAZY, RIGHT??!??!
The attached screenshot is about half way through the scan.

What's REALLY odd, I was able to delete all the photos. But the empty folders are still there.

So my question: how can I delete all these folders?

MilesAhead:
Is there any software on the card?  If it's just storage, find out how to format it.  That will delete everything.

rjbull:
DelAge32, freeware by Horst Schaeffer.
DelAge32 is a command line tool that deletes or moves files by age (number of days).
[...]
/recurse   Recurse through the entire subdirectory structure (see /rd option to remove empty directories)
/subonly   Recurse, but exclude the initial directory   
/rd   Remove empty directories by age (according to "created" stamp)   
[...]
--- End quote ---

Jammo the OrganizedFellow:
Is there any software on the card?  If it's just storage, find out how to format it.  That will delete everything.

-MilesAhead (June 01, 2011, 04:27 PM)
--- End quote ---
The phone no longer works. Getting it functional is beyond my intents.
The microSD card is still in the phone.

I'm wanting to delete the backed up folders from my PC.
It's spring cleaning time, and I came across them today.

@rjbull: thank you. I'll give that a try.

Jammo the OrganizedFellow:
NOPE.
I extracted the contents of "delage32.zip" to a temp directory. And ran my first command:
Delage32 D:\MomPhoneBackup\*.* 10 /recurse /rd

*I didn't know if it would delete anything/everything YOUNGER or OLDER than 10 days.
So I ran it a few times with 10, 100, 1000, etc. You get the picture.

OUTPUT

--- ---D:\_TEMP\delage32>Delage32 D:\MomPhoneBackup\*.* 10 /recurse /rd
 (rd) 110327_112728\dcim\b\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camer
a\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\Camera\ *** fail
ed ***
DelAge32 - No files

D:\_TEMP\delage32>
*I didn't know ... I didn't read the directions fully till my first few attempts because I wasn't paying attention and ended up watching a movie and having lunch ... because I got distracted.
But I tried a few more times and all come up with the same results.

Navigation

[0] Message Index

[#] Next page

Go to full version