Basically what I wanted to do was automate these three things that I do every once in a while on my machine (& that I always have to do on other's machines). I created a set of vbscript files to take care of things for me. I also put it into a self-extracting archive that installs it.
I came across some things that are similar to this, but I wanted to do it with just tools that are included with XP. I also wanted it fully automated. Others I've seen reboot, then wait for you to login…unless you have Windows logging in automatically.
One of the goals I had with this is to make it secure. It was a little tricky because I had to create an admin user & use the autoadmin logon feature to get to the defrag part automatically. I've done some testing and it appears to work nicely with two reboots.
These are still works in progress. I am not responsible for any damage they may do to a system.
Here is the link for the package:
http://www.netsec.pro/downloads/index.php?dir=Windows%2FUtilities%2F&download=Maintenance.exe
Here is the link for the readme file:
http://www.netsec.pro/downloads/index.php?dir=Windows%2FUtilities%2F&download=Maintenance.txt