Collect Hardware Inventory of Local Admins


We had requirements on to collect the information of only local Admins.
We already had blogs which were helping to find information of all local groups.
http://mnscug.org/blogs/sherry-kissinger/244-all-members-of-all-local-groups-configmgr-2012 .
http://myitforum.com/cs2/blogs/skissinger/archive/2010/04/25/report-on-all-members-of-all-local-groups.aspx
In the interest of collecting less data (Save space in DB) I modified the same to collect only Local admins
Steps
1) Import the Cab file

  • ? Take the the attached file--> WMI Framework For Local Administrator
  • ? In your ConfigMgr 12 console, on Assets and Compliance, Compliance Settings
  • ? Right-click on "Configuration Baseline"  and Import this file (http://technet.microsoft.com/en-us/library/hh691016.aspx )
  • ? Once done deploy the baseline to the collection of machines from which you need.(http://technet.microsoft.com/en-us/library/hh219289.aspx )

2) Import the MOF file so that SMS_DEF is updated in 2012 this is how you do

  • ? On the console, Administration ? Client Settings ?  right-click 'Default Client Settings'?and go to properties.
  • ?  Select Hardware Inventory, then on the right "Set Classes.
  • ? Click Import and browse to the localadmin.mof file you saved.

  Content of MOF file
========================================
[ SMS_Report (TRUE),
  SMS_Group_Name ("LocalAdmins"),
  SMS_Class_ID ("MICROSOFT|LocalAdmins|1.0"),
  Namespace ("root\\\\cimv2") ]
class Win32_LocalAdmins : SMS_Class_Template
{
    [SMS_Report (TRUE), key ] string Account;
    [SMS_Report (TRUE)      ] string Domain;
    [SMS_Report (TRUE), key ] string Name;
    [SMS_Report (TRUE)      ] string Type;
};
====================================================

The script use to create a WMI entry is also available in the Zip file uploaded.

=================================

Sudheesh Narayanaswamy

This posting /Script  is provided "AS IS" with no warranties and confers no rights

Data.zip

Comments (7)

  1. Gary Caselman says:

    Not clear where or how to run the script.

  2. Murthy says:

    Sudheesh, will this causes any performance issue if we are running on bulk number of systems.

  3. anonymouscommenter says:

    If you follow the below link and user the configuration item and get the inventory , the data will be

  4. Sudheesh says:

    @Logan There are no default reports but this creates a separate view in database and hence can easily pull the information. It will be something like V_GS_Localadmins…

  5. logan.IN says:

    Hi, This is nice work. How we can check who are all in that group. Any reports?

  6. Fernando Curiel says:

    why do I get Fernando Curiel??? MY NAME IS MARIA G. CURIEL THIS IS MY MSN ACCOUNT…. > From: mariaguadalupe.curiel@facebook.com My hp PC all-in-one & hp2000 Notebook w/ Nortan Anti-virus plzzzz help me…curiel94580@yahoo.com curielmg@Hotmail.com link
    to this blog as {Fernando Curiel sismo systemas MX] HE IS A RELATIVE 2ND COUSIN IN mEXICO MGC 12/14/2014

Skip to main content