May 2011 - Posts

Hardware Inventory mof edit for .net Frameworks (updated with v1)

This updated mof snippet adds in v1.0 for .net Frameworks, if you happen to have older OS' out there, or XP Media Center Edition. 

If you currently have dotNetframeworks (older) mof edit, you may want to carefully check if replacing the old one with this new one will affect any current collection queries or reports. Fyi, there isn't any SP 's for v4 yet; so in the v4 section I made a complete guess about what the regkey might be if a ServicePack ever comes out for v4.  There may never be one, or if there is one, I've guessed the regkey incorrectly.  That might need to be updated if my guess is wrong.

The registry key locations are from http://support.microsoft.com/kb/318785/en-us

Mof Snippets -->Here<--

If you implement this mof snippet, here's a potential report.

 select sys1.netbios_name0,
        MAX(CASE dn.version0 when '1.0' THEN
          case dn.installed0 when '1' then dn.BuildNumber0 End END) AS [.Net 1.0],
        MAX(CASE dn.version0 when '1.0 MCE' THEN
          case dn.installed0 when '1' then dn.BuildNumber0 End END) AS [.Net 1.0 MCE],
        MAX(CASE dn.version0 when '1.1' THEN
          case dn.installed0 when '1' then dn.BuildNumber0 End END) AS [.Net 1.1],
        MAX(CASE dn.version0 when '1.1' THEN
          case dn.installed0 when '1' then dn.ServicePack0 End END) AS [.Net 1.1 SP],
        MAX(CASE dn.version0 when '2.0' THEN
          case dn.installed0 when '1' then dn.BuildNumber0  end END) AS [.Net 2.0],
        MAX(CASE dn.version0 when '2.0' THEN
          case dn.installed0 when '1' then dn.ServicePack0  end END) AS [.Net 2.0 SP],
        MAX(CASE dn.version0 when '3.0' THEN
          case dn.installed0 when '1' then dn.BuildNumber0  end END) AS [.Net 3.0],
        MAX(CASE dn.version0 when '3.0' THEN
          case dn.installed0 when '1' then dn.ServicePack0  end END) AS [.Net 3.0 SP],
        MAX(CASE dn.version0 when '3.5' THEN
          case dn.installed0 when '1' then dn.BuildNumber0  end END) AS [.Net 3.5],
        MAX(CASE dn.version0 when '3.5' THEN
          case dn.installed0 when '1' then dn.ServicePack0 end END) AS [.Net 3.5 SP],
        MAX(CASE dn.version0 when '4.0' THEN
          case dn.installed0 when '1' then dn.BuildNumber0  end END) AS [.Net 4.0]

FROM
v_r_system AS sys1
Left Join v_gs_dotnetframeworks0 dn
ON dn.resourceid=sys1.ResourceID
group by sys1.netbios_name0
 
  
Posted by skissinger | with no comments
Filed under: ,