Solved

fast delete a number of files

Posted on 2006-06-12
9
11,732 Views
Last Modified: 2010-12-13
Hello,
I have some offline websites. I had more than 15000 files and folders( all stored in a foler). Deleting all these things is a nightmare, even when i used winrar(I checked delete files after finished). It took a lot of time. I wonder whether there is a software can wipe all these file within a minute? Thanks
0
Comment
Question by:binocular222
9 Comments
 
LVL 23

Expert Comment

by:basicinstinct
ID: 16884168
why not just delete the top-level folder?
0
 

Author Comment

by:binocular222
ID: 16884239
Windows can delete but very slowly. 15000 file!
0
 
LVL 15

Expert Comment

by:deepaknet
ID: 16884423
Did you try using command prompt?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 2

Accepted Solution

by:
Night0wl earned 25 total points
ID: 16884522
using windows will probably be the fastest solution because it only removes the header informarion from the files, unllike winrar which parses the files into memory and compresses it thus adding another step to the process. The easiet way is probably a combination of basicinstinct and deepaknet. Use a command line and navigate to the top-level folder and type rmdir foldername /S or go in one folder and type del *.* /S and then delete the top-level folder. Using the /S switch will surpress the warnings windows gives when you delete a hidden file, a sytem file (thumbnail caches) or a read only file. This way you can set it up to run over night.
0
 
LVL 10

Assisted Solution

by:GuruGary
GuruGary earned 25 total points
ID: 16886019
Yes, I agree with deleting them through the command prompt.  To update the notes from Night0wl, the /S will delete subdirectories, and it is the /Q parameter to supress the warnings.  So be VERY CAREFUL using this as it is easy to delete unwanted information using this.  Use:

rd /q /s "X:\path\to\top level directory\"
0
 
LVL 7

Expert Comment

by:CitizenRon
ID: 31027282
In case anyone else find this in a search:
 
 I had a cleanup project to do on a server that someone else "worked"  on.  They left 11,600,000 files in 412,000 folders behind on a drive  that desperately needed the space and I had to get it cleaned ASAP  without doing anything bad to the server.
 
 I used a trick with ROBOCOPY.EXE to delete those 11.6 million files in  just a couple hours.  Use the MIRROR (/MIR) switch (which copies or deletes files as needed to make the Destination folder and EXACT copy of the Source folder) with RoboCopy and  copy an empty folder to the  folder containing all the files you need quickly removed.
  1. Create a Temp folder, something like "C:\RoboTemp"
  2. Copy the folder to the folder you want deleted using the /MIR  switch
  3. ROBOCOPY C:\ROBOTEMP C:\FOLDERTODELETE /MIR
  4. Sit back and watch the files disappear lightning fast
  5. Delete the now-empty folder that used to contain millions of files  and the empty Temp folder
  Something about the way RoboCopy deletes files when mirroring makes it extremely fast, faster than any other (free) method I've found in Windows.
 
0
 

Expert Comment

by:mbooher
ID: 34340955
CitizenRon,

You have saved me HOURS of time - thanks for this GREAT suggestion!  It is working like a champ!  Using Win7, my system was deleting about 2 files per second.  Now it is ZIPPING along!!!
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

There are 2 things you must have in order to connect to the internet behind a router, The "Gateway IP" of the router, which is usually something like 192.168.xxx.1, I've seen routers with default values of: 192.168.0.1, 192.168.1.1, 192.168.11.1, …
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question