Ask a questionAsk a question
 

AnswerMOF Custom Registry Entry Modification

  • Tuesday, November 03, 2009 5:03 AMTom Wilmot Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Hello,

    Calling all MOF experts!! I have spent hours attempting to pull back some registry information. Does anyone see anything wrong with this information that I modified in my site servers MOFs. I can't get the data to appear in the Resource Explorer. The MOFCOMP.exe revealed no errors.

    sms_def.mof

    #pragma namespace("\\\\.\\root\\cimv2\\SMS")
    #pragma deleteclass("TerminalServerMode", NOFAIL)
    [SMS_Report(TRUE),
     SMS_Group_Name("RegScan Terminal Server Key"),
     SMS_Class_ID("CUSTOM|TerminalServerMode|1.0")]
    Class TerminalServerMode : SMS_Class_Template
    {
      [SMS_Report(TRUE),key] string KeyName;
      [SMS_Report(TRUE)] Uint32 TSAppCompat;
    };

    configuration.mof


    #pragma namespace ("\\\\.\\root\\cimv2")
    #pragma deleteclass("TerminalServerMode",NOFAIL)
    [DYNPROPS]
    Class TerminalServerMode
    {
      [key] string  KeyName;
     Uint32  TSAppCompat;
    };
    [DYNPROPS]
    instance of TerminalServerMode
    {
      KeyName = "TerminalServerMode";
      [PropertyContext("Local|HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Terminal Server|TSAppCompat"),
         Dynamic, Provider("RegPropProv")] TSAppCompat;
    };

Answers

  • Wednesday, November 04, 2009 10:24 PMTom Wilmot Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    Sorry guys...... it helps if the machine is in a boundary managed by the site server that you change the MOF on. :) Once I added the boundary, waited a few minutes, and ran Hardware Inventory the new entry appeared in Resource Explorer. Lesson learned!!!! Thanks Garth.
    • Marked As Answer byTom Wilmot Friday, November 06, 2009 3:17 PM
    •  

All Replies

  • Tuesday, November 03, 2009 10:44 PMTom Wilmot Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Could I be using a keyword or phrase that SCCM already has reserved? Does anyone know of a canned report to extract terminal servers in application mode?
  • Wednesday, November 04, 2009 1:16 PMGarth JonesMVPUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    What does the inventory.log say on a client? Does the class show up?
    http://www.enhansoft.com/
  • Wednesday, November 04, 2009 10:24 PMTom Wilmot Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    Sorry guys...... it helps if the machine is in a boundary managed by the site server that you change the MOF on. :) Once I added the boundary, waited a few minutes, and ran Hardware Inventory the new entry appeared in Resource Explorer. Lesson learned!!!! Thanks Garth.
    • Marked As Answer byTom Wilmot Friday, November 06, 2009 3:17 PM
    •