Automating Disk Cleanup
I am trying to automate Disk Cleanup using Task Scheduler tostart cleanmgr.exe on a schedule of my choosing. Prior to establishing the schedule I have manually run cleanmgr with a /sageset:0 argument to select the files that I want to delete. My scheduled task has the optional argument /sagerun:0 so that the files I selected will be deleted each time Disk Cleanup runs.What I am finding is that the scheduled Disk Cleanup does not completely delete all the files I selected using /sageset:0 and will not empty the Recycle Bin even though I selected that. Running Disk Cleanup manually immediately after the scheduled task runs still shows a small amount of space that can be clearedplus the entire contents of the Recycle Bin.In summary I am trying to understand why running cleanmgr with the /sageset:0 and /sagerun:0 arguments will not completely delete all the files I selected as it would if I manually ranDisk Cleanupand why it won't delete anything from the Recycle Bin even though I selected it.
December 6th, 2009 4:38pm

Hey Richmny,Any luck on figuring this out? I'm running into the same problem.
Free Windows Admin Tool Kit Click here and download it now
January 22nd, 2010 7:36pm

Jeff, I haven't looked into it further, waiting for someone else who may who may have an answer to this one. In the interim, I let my scheduled task cleanup whatever it can and empty the recycle bin manually.
January 22nd, 2010 9:29pm

May be this will be helpful. http://social.technet.microsoft.com/Forums/en-US/itprovistaapps/thread/093cdb51-1139-4d7b-862b-eb9daa36b453MCP | scriptoholic | PowerShell | SCCM 2007 | SMS 2003
Free Windows Admin Tool Kit Click here and download it now
June 25th, 2010 3:39pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics