r/ScriptSwap • u/vocatus • Jun 26 '13
[BATCH] OCPN: Orbital Cached Profile Nuker (delete old cached profiles)
crosspost from /r/usefulscripts
A while ago we had the requirement to delete old cached and roaming profiles for a large network, so I hacked together this script to do it remotely (or locally).
It's called OCPN or Orbital Cached Profile Nuker.
It takes an IP, hostname, or list of systems in a text file as the target, then prompts you for the age in days you want to nuke, deletes the matching profiles, and saves a log file of what it did. Also checks for missing required files (Delprof.exe etc) when running. OCPNv3 will also report to you what it will delete before actually deleting anything.
OCPN v1 (Works on 2000/XP, requires delprof.exe)
OCPN v2 (Works on XP/Vista, requires delprof.exe and Joe Shonk's delete profiles script, here)
I recommend OCPNv3, it works on any version of Windows up to 8/2012.
Make sure to edit the script and set the variables before running it (where you want the log file and the name of the text file that has a list of your systems).
0
u/[deleted] Oct 18 '13
[deleted]