Finding seldom used computers in your company

Todd Miller shared a neat MOF snippet.  He had a need to find seldom-used computers in the organization so they could be repurposed.  The value he used to track this is noting when the screen saver activates on a continuously running computer.  There are a few caveats: there must be a screen saver enabled, and it's assumed that these computers aren't shutdown at night, then powered up every day--but no one ever uses them.  Although it could be argued that if someone is taking the time to shutdown & startup daily, someone cares that it's there, maybe not being used, but someone remembers it!

Here's the forum entry for more information.

The snippet:

//  <:[-<>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>- ScreenSaver Activity-<<<<<<<<<<<<<<<<<<<<<<<<<<<<>-]:>
//   If ConfigMgr, this section in configuration.mof
//
#pragma namespace("\\\\.\\root\\cimv2")
#pragma deleteclass("ScreenSaverActivity",NOFAIL)
[Union,
ViewSources{"Select * from Win32_process where Name like '%.scr'"},
ViewSpaces{"\\\\.\\root\\cimv2"},
dynamic,Provider("MS_VIEW_INSTANCE_PROVIDER")]
class ScreenSaverActivity
{
[PropertySources("Handle"),Key] String Handle;
[PropertySources("Name")] string Name;
[PropertySources("CreationDate")] DateTime CreationDate;
};

// If ConfigMgr, this section in sms_def.mof

#pragma namespace("\\\\.\\root\\cimv2\\SMS")
[SMS_Report(TRUE),
SMS_Group_Name("Screen Saver Activity"),
SMS_Class_ID("MICROSOFT|ScreenSaverActivity|1.0") ]
Class ScreenSaverActivity: SMS_Class_Template
{
[SMS_Report(TRUE),Key]  String Handle;
[SMS_Report(TRUE)]  string Name;
[SMS_Report(TRUE)]      DateTime     CreationDate;
};
//  <:[-<>>>>>>>>>>>>>>>>>>>>>>>>>>END>>- ScreenSaver Activity -<<END<<<<<<<<<<<<<<<<<<<<<<<>-]:>

Published Monday, December 15, 2008 7:02 PM by skissinger
Filed under:

Comments

No Comments