I am running a window script to delete files from folder which have around 10k files .I want that my script command which is:
forfiles /p "path" /s /d -30 /c "cmd /c del @file : date >= 30 days >NUL"
,should delete 10 files and then wait for 5 sec and then again start deleting and then again wait for 5 secons
and so on?
I want this feature because if 10k files are deleted in one go , it will create hamper the normal working of server