Question
How can I reset the Server side data hashes for the Software Inventory Policy returns?
When Patch Compliance reporting is inaccurate or Patch Dataclasses are not being created and the setting to 'Only Report inventory if Changed' has already been deselected allowed to propagate to all the clients, then run the SQL to clear server side data hashes.
Answer
The following SQL queries will set the datahash's to 'Null'. The first option is the one that needs to be run to Null all datahash's.
-
To update all DataHash's for all Resources run the following:
UPDATE ResourceUpdateSummary
SET DataHash = NULL
WHERE InventoryClassGuid IN
('2A5937E2-2BBD-45EE-8DB9-235C1724A230',
'1AC7A644-5AB5-4434-B24E-B3C27BA17DED',
'31967BBA-7A64-495E-A61E-48018592D068',
'CC6F3303-77D3-4F98-A2C7-3018949A23F1',
'729E790B-C1AA-4810-9717-C046650FC79B',
'9D326BB4-75D4-4DB9-9946-59141BD1D44E',
'75DA0CCA-0095-44E7-8FBE-960FA0D72075')
AND DataHash IS Not NULL
-
To update the DataHash for a single computer run the following: (This would be used to test and verify that it will help the issue if the all DataHash's are set to Null)
UPDATE ResourceUpdateSummary
SET DataHash = NULL
WHERE InventoryClassGuid IN
('2A5937E2-2BBD-45EE-8DB9-235C1724A230',
'1AC7A644-5AB5-4434-B24E-B3C27BA17DED',
'31967BBA-7A64-495E-A61E-48018592D068',
'CC6F3303-77D3-4F98-A2C7-3018949A23F1',
'729E790B-C1AA-4810-9717-C046650FC79B',
'9D326BB4-75D4-4DB9-9946-59141BD1D44E',
'75DA0CCA-0095-44E7-8FBE-960FA0D72075')
AND ResourceGuid = 'ENTER RESOURCE GUID HERE'
-
To update the DataHash for a single DataClass run the following:
UPDATE ResourceUpdateSummary
SET DataHash = NULL
WHERE InventoryClassGuid = 'Place Guid From Below Here'
The following are corresponding Guid's with Inventory policies and dataclasses :
Windows Operating System = 2A5937E2-2BBD-45EE-8DB9-235C1724A230
Windows Software Release = 1AC7A644-5AB5-4434-B24E-B3C27BA17DED
Windows Service Pack = 31967BBA-7A64-495E-A61E-48018592D068
Microsoft Software Release = CC6F3303-77D3-4F98-A2C7-3018949A23F1
Microsoft Service Pack = 729E790B-C1AA-4810-9717-C046650FC79B
Installed Microsoft Software Update = 9D326BB4-75D4-4DB9-9946-59141BD1D44E
Applicable Microsoft Software Update = 75DA0CCA-0095-44E7-8FBE-960FA0D72075