Thanks a lot sherry! Criselda Hilvano GDE Team From: [email protected] [mailto:[email protected]] On Behalf Of Sherry Kissinger Sent: Friday, June 14, 2013 8:48 PM To: [email protected] Subject: Re: [mssms] extend hardware inventory in sccm2012
It's actually fairly similar to what Jeff's blog post is.
Make the configuration.mof edit; replacing his query with yours.
put that mof edit at the bottom of your configuration.mof file.
This goes on bottom of configuration.mof
#pragma namespace("\\\\.\\root\\cimv2")
[Union,
ViewSources{"Select * FROM Win32_NTLogEvent WHERE LogFile='System' AND
EventCode='whatever it is'"},
ViewSpaces{\\\\.\\root\\cimv2},
Dynamic, Provider("MS_VIEW_INSTANCE_PROVIDER")]
Class EvtVwrHDFailures
{
[PropertySources("LogFile"), Key] string LogFile;
[PropertySources("EventCode")] UINT16 EventCode;
[PropertySources("RecordNumber"), Key] UINT32 Recordnumber;
[PropertySources("Message")] String Message;
[PropertySources("TimeGenerated")] DateTime TimeGenerated;
};
This you import into default client agent settings, hardware inventory,
classes, import... make sure you save it as ending in .mof
#pragma namespace(\\\\.\\root\\cimv2\\sms)
[SMS_Report(TRUE),
SMS_Group_Name("EvtVwrHDFailures"),
SMS_Class_ID("EvtVwrHDFailures")]
Class EvtVwrHDFailures: SMS_Class_Template
{
[SMS_Report(TRUE), Key] String LogFile;
[SMS_Report(TRUE), SMS_Units("DecimalString")] UINT16 EventCode;
[SMS_Report(TRUE), Key, SMS_Units("DecimalString")] UINT32 RecordNumber;
[SMS_Report(True)] String Message;
[SMS_Report(True)] DateTime TimeGenerated;
};
This is what I refer to as a "Custom WMI Inventory edit", a sample walkthrough
here:
http://myitforum.com/cs2/blogs/skissinger/archive/2011/07/14/configmgr2012beta2-hardware-inventory-custom-wmi.aspx
Sherry Kissinger
Microsoft MVP - ConfigMgr
[email protected]
________________________________
From: "Hilvano, Criselda" <[email protected]>
To: "[email protected]" <[email protected]>
Sent: Thu, June 13, 2013 8:59:01 PM
Subject: RE: [mssms] extend hardware inventory in sccm2012
Hello Sherry
Thanks!. Yes I can query out from Select * FROM Win32_NTLogEvent WHERE
LogFile='System' AND EventID='whatever that id is’
Can you please provide the basic steps in doing it in SCCM2012?
Criselda Hilvano
GDE Team
From: [email protected] [mailto:[email protected]] On
Behalf Of Sherry Kissinger
Sent: Thursday, June 13, 2013 9:14 PM
To: [email protected]
Subject: Re: [mssms] extend hardware inventory in sccm2012
You can inventory out of (some of) the event logs:
http://myitforum.com/cs2/blogs/jgilbert/archive/2007/08/08/inventorying-remote-assistance-requests-and-connections.aspx
Criselda, if you were to query wmi in root\cimv2, using something like Select *
FROM Win32_NTLogEvent WHERE LogFile='System' AND EventID='whatever that id is'
does that return the distinct results you are hoping for? So then, yes, with a
configuration.mof edit, and then importing the new custom class which you'll
have created, then yes--that information can be reported.
Of course, the long-term caveats are if you replace that bad hard drive, the
historical "I had a bad drive" will still be in eventvwr, and still be
reported, unless you adopt a procedure where when that drive is replaced,
eventvwr is cleared (unless of course replacing the bad drive really means
"replace the drive, and put the image down" then of course it doesn't matter)
Sherry Kissinger
________________________________
From: Jimmy Martin <[email protected]<mailto:[email protected]>>
To: "[email protected]<mailto:[email protected]>"
<[email protected]<mailto:[email protected]>>
Sent: Thu, June 13, 2013 6:05:12 AM
Subject: RE: [mssms] extend hardware inventory in sccm2012
This is where scom would come in...
Sent from my Windows Phone
________________________________
From: Hilvano, Criselda
Sent: 6/13/2013 1:43 AM
To: [email protected]<mailto:[email protected]>
Subject: [mssms] extend hardware inventory in sccm2012
Hello
I need to extend HW inventory to report a specific event id in system log of a
machine that indicates a bad sectors on a hard drive. Is this a realistic
request? Is SCCM2012 the right tool to do this considering that only specific
event id will be reported and real time data is not a concern, since we have HW
inventory that runs every 3 days. Can someone please provide the right edits
on how to do this?
Criselda Hilvano
[Image removed by sender. Baptist 100. Well beyond a
century.]<http://www.baptist100.org>
Baptist 100. Well beyond a century.
This message and any files transmitted with it may contain legally privileged,
confidential, or proprietary information. If you are not the intended recipient
of this message, you are not permitted to use, copy, or forward it, in whole or
in part without the express consent of the sender. Please notify the sender of
the error by reply email, disregard the foregoing messages, and delete it
immediately.
P Please consider the environment before printing this email...
<<inline: ~WRD000.jpg>>

