Using ZEN to run ScanDisk on an Enterprise Scale
Novell Cool Solutions: Trench
By Mark Poole
Digg This -
Posted: 7 Jul 1999
Mark Poole, our ever-helpful ZEN power user from James Madison University, sent along this explanation of how he uses ZENworks Workstation Management to schedule ScanDisk to run unattended on an enterprise scale.
One of the nicer things that Microsoft Plus! gives is the ability to schedule ScanDisk to run completely unattended, with custom settings on an individual machine. Using ZENworks workstation management, and a little knowledge of the registry, it is easy to set up the same thing on an enterprise scale.
In order to pull off this little trick, Plus! uses the fact that ScanDisk is a System Agent aware application. When the user sets up ScanDisk to run at a certain time, the settings are stored in the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\ Plus!\System Agent\SAGE registry branch. In this branch it will create a key for the application, namely "ScanDisk for Windows". Under this it will create another key called Set# where the # begins at 0, and increments each time the application is scheduled with different settings. So, a user who has ScanDisk scheduled to do a thorough scan once a month, and a standard scan weekly would have two keys, Set0 and Set1. Plus! uses these registry keys to call the application with the desired settings.
The nice part is that all of this can be pulled off without owning Plus!. System Agent aware applications can be run with the command line switch /sageset:# where the # is the value that will be used to create the key. The application will then launch, but any settings that are made will be stored in the registry before the application exits. The next time you want to use the same settings, you can just call them with /sagerun:#.
So basically, all we have to do is run ScanDisk /sageset:9 (I will explain why I used 9 in a minute) and then pick all the settings in the GUI. You then import the SAGE branch into a NAL object, and force run it against your machines. Now, in the relevant ZEN workstation policy package, you create a new policy that schedules ScanDisk with a parameter of /sagerun:9 and you have every machine running ScanDisk on a enterprise wide basis.
The reason I used 9 is that in an organization without centralized control of the desktops, it is very possible that someone is using Plus!, and already has settings for sageset:0. By starting at 9 you avoid changing their settings (unless they are scheduling ScanDisk with 10 different configurations.) The number could just have easily been 37 if you wanted to really avoid any other users' settings.
This same exact procedure will work with defrag as well, and should work for any other System Agent aware application. It is a really easy way to do some basic workstation maintenance, without having to either train the end user, or leave your desk.
Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com