Access is denied when using Configuration Manager Remote Control

When using Configuration Manager Remote Control to manage SCCM Clients, user is asked for credentials. After authenticating, Access Denied error is received even if user is member of Permitted Viewers list specified in the Remote Tools Client Agent properties.

After investigating this issue, it turned out that DCOM was not enabled on affected computers. In order to enable DCOM, use the following procedure on computers that are experiencing this problem:
1. Open Component Services mmc. Start ->Run -> dcomcnfg.
2. Expand Component Services -> Computers -> My Computer.
3. Right click on My Computer and select Properties. Go to the Default Properties tab. Make sure that “Enable Distributed COM on this computer” option is enabled. Set Default Authentication Level to Connect and Default Impersonation Level to Identify.

Access is denied when using Configuration Manager Remote Control

An error occurs when upgrading Message Queuing Management Pack for Operations Manager 2007

When upgrading MSMQ Management Pack to version 6.0.6615.0, you might receive the following error:
The requested management pack was invalid. See inner exception for details.
Parameter name: managementPack

In addition, the following events are written to the Operations Manager log on the SCOM Root Management Server:

Event Type: Error
Event Source: OpsMgr SDK Service
Event ID: 26319
Description:
An exception was thrown while processing ImportManagementPack for session id uuid:6e44bef7-2a3a-4304-9443-d7cbf155c41b;id=326.
Exception Message: The creator of this fault did not specify a Reason.
Full Exception: System.ServiceModel.FaultException`1[Microsoft.EnterpriseManagement.Common.ManagementPackException]: The creator of this fault did not specify a Reason. (Fault Detail is equal to : Verification failed with [1] errors:
-------------------------------------------------------
Error 1:
: Could not load ManagementPack [ID=Microsoft.MSMQ.Library, Keytoken=31bf3856ad364e35, Version=6.0.6615.0]. ManagementPack not found in the store.
Version mismatch. For ManagementPack [[Microsoft.MSMQ.Library, 31bf3856ad364e35, 6.0.6587.0]] requested version from the database was [6.0.6615.0], and actual version available is [6.0.6587.0]
-------------------------------------------------------

Could not load ManagementPack [ID=Microsoft.MSMQ.Library, Keytoken=31bf3856ad364e35, Version=6.0.6615.0]. ManagementPack not found in the store.Version mismatch. For ManagementPack [[Microsoft.MSMQ.Library, 31bf3856ad364e35, 6.0.6587.0]] requested version from the database was [6.0.6615.0], and actual version available is [6.0.6587.0]).

Event Type: Error
Event Source: OpsMgr SDK Service
Event Category: None
Event ID: 26319
Description:
An exception was thrown while processing ImportManagementPack for session id uuid:6e44bef7-2a3a-4304-9443-d7cbf155c41b;id=326.
Exception Message: The creator of this fault did not specify a Reason.
Full Exception: System.ServiceModel.FaultException`1[Microsoft.EnterpriseManagement.Common.ManagementPackException]: The creator of this fault did not specify a Reason. (Fault Detail is equal to : ManagementPack Version [6.0.6615.0] is not upgrade compatible with older version [6.0.6587.0]. Compatibility check failed with 1 errors:
-------------------------------------------------------
Error 1:
: SecureReference: [Microsoft.MSMQ.QueueAccessProfile] is not upgrade compatible.
[SecureReference]: [Microsoft.MSMQ.QueueAccessProfile] exists in current version [6.0.6587.0] of ManagementPack but does not exist in the new version [6.0.6615.0].
-------------------------------------------------------

This issue is caused by the fact that any existing MSMQ Management Pack should be removed prior upgrade to the 6.0.6615.0 version. Message Queuing Management Pack Guide does not include this information (at the time when this blog post was created).

An error occurs when upgrading Message Queuing Management Pack for Operations Manager 2007

How to force hardware/software inventory on SCCM Client?

In order to force Hardware Inventory on SCCM Client, run the following VBScript:

hInventoryActionID = "{00000000-0000-0000-0000-000000000001}"
Set oLocator = CreateObject("WbemScripting.SWbemLocator")
Set oServices = oLocator.ConnectServer( , "root\ccm\invagt")
oServices.Delete "InventoryActionStatus.InventoryActionID=""" & hInventoryActionID & """"
wscript.sleep 3000
Set cpApplet = CreateObject("CPAPPLET.CPAppletMgr")
Set actions = cpApplet.GetClientActions
For Each action In actions
If Instr(action.Name,"Hardware Inventory") > 0 Then
action.PerformAction
End if
Next

For more information, refer to the following MSDN article: http://msdn.microsoft.com/en-us/library/cc144592.aspx

 

In order to force Software Inventory on SCCM Client, run the following VBScript:

sInventoryActionID = "{00000000-0000-0000-0000-000000000002}"
Set oLocator = CreateObject("WbemScripting.SWbemLocator")
Set oServices = oLocator.ConnectServer( , "root\ccm\invagt")
oServices.Delete "InventoryActionStatus.InventoryActionID=""" & sInventoryActionID & """"
wscript.sleep 3000
Set cpApplet = CreateObject("CPAPPLET.CPAppletMgr")
Set actions = cpApplet.GetClientActions
For Each action In actions
If Instr(action.Name,"Software Inventory") > 0 Then
action.PerformAction
End if
Next

For more information, refer to the following MSDN article: http://msdn.microsoft.com/en-us/library/cc145432.aspx

How to force hardware/software inventory on SCCM Client?

Configuration Manager Task Sequence fails with 0x80070002 error code

Recently I’ve had an issue in which Configuration Manager Task Sequence (TS) used for the Operating System Deployment (OSD) kept failing. When looking at the contect of the appropriate Smsts.log file, it turned out that it was failing with the 0x80070002 error code:

Failed to resolve the source for SMS PKGID=PKGID$, hr=0x80070002

When looking at numerous forum posts on this subject, in almost all cases it turned out to be network-related problem in a way that SCCM Client is not able to reach software distribution package on the distribution point. However, in my case this couldn’t have been the problem because Task Sequence was run from standalone bootable media (DVD-ROM) which contained all referenced software distribution files.

After spending a lot of time troubleshooting, it turned out that the problem was caused by the fact that DVD-ROM drive included in the physical server on which TS was running was not able to read dual-layered DVD-ROM media files. Complete TS had approximately 5 GB in size and couldn’t fit on single-layered media. That’s why dual-layered DVD-ROM media had to be used.

This just proved again that most obvious solution is often the last one taken into consideration.

Configuration Manager Task Sequence fails with 0x80070002 error code

How to decompress all files in the specified directory?

In case you run into situation that you need to decompress all files in the specified directory, use the following procedure. This most often happens if a system administrator runs the disk cleanup wizard on the server with an option to compress old (files that have not been used recently) files enabled. File compression must be used carefully because it can greatly affect disk performance as explained in the following KB article: Best practices for NTFS compression in Windowshttp://support.microsoft.com/kb/251186.

  1. Open Command Prompt.
  2. Navigate to folder containing compressed files.
  3. Run the following command: COMPACT /U /S /A /I

To see all command line parameters of the COMPACT command line tool, simply run COMPACT /?.

How to decompress all files in the specified directory?

How to extend hardware inventory information to include physical memory location?

In certain cases, beside the total amount of physical memory information, it is useful knowing the actual physical memory bank distribution across hardware memory slots. This is especially true when memory upgrade must be considered within the company in order to meet requirements imposed by the new version of client operating system.

By default, this is not included in Configuration Manager hardware inventory which therefore must be extended by editing sms_def.mof file. The Win32_PhysicalMemory WMI class represents a physical memory device located on a computer system and available to the operating system. To include Win32_PhysicalMemory WMI class in the scope of hardware inventory, the following lines should be added to the sms_def.mof file:

//* Physical memory location inventory.

[ SMS_Report(TRUE),
SMS_Group_Name("Physical Memory Location"),
SMS_Class_ID("Microsoft|PHYSICAL_MEMORY_LOCATION|1.0") ]
Class Win32_PhysicalMemory: SMS_Class_Template
{
[key, SMS_Report(TRUE)]
uint64 Capacity;
[key, SMS_Report(TRUE)]
string Description;
[key, SMS_Report(TRUE)]
string DeviceLocator;
[key, SMS_Report(TRUE)]
string Manufacturer;
[key, SMS_Report(TRUE)]
uint16 MemoryType;
[key, SMS_Report(TRUE)]
string PartNumber;
[key, SMS_Report(TRUE)]
string SerialNumber;
[key, SMS_Report(TRUE)]
uint32 PositionInRow;
[key, SMS_Report(TRUE)]
uint32 Speed;
};

In this example Capacity, Description, DeviceLocator, Manufacturer, MemoryType, PartNumber, SerialNumber, PositionInRow and Speed properties of the Win32_PhysicalMemory WMI class will be queried and included in hardware inventory.
For a list of all available properties, you may refer to MSDN: Win32_PhysicalMemory Classhttp://msdn.microsoft.com/en-us/library/aa394347(v=vs.85).aspx

Once this is done and first managed devices run hardware inventory based on extended sms_def.mof file, you can then create custom Configuration Manager report to display collected information. For a custom Configuration Manager report, the following query can be used:

SELECT
v_GS_SYSTEM.Name0 AS 'Computer Name',
Capacity0/1048576 AS 'Capacity (MB)',
Description0 AS 'Description',
DeviceLocator0 AS 'Device Locator',
Manufacturer0 AS 'Manufacturer',
PartNumber0 AS 'Part Number',
SerialNumber0 AS 'Serial Number',
MemoryType0 AS 'Memory Type',
PositionInRow0 AS 'Position In Row',
Speed0 AS 'Speed (ns)'
FROM
v_GS_PHYSICAL_MEMORY_LOCATION
JOIN
v_GS_SYSTEM ON v_GS_SYSTEM.ResourceID = v_GS_PHYSICAL_MEMORY_LOCATION.ResourceID
ORDER BY v_GS_SYSTEM.Name0

How to extend hardware inventory information to include physical memory location?

An error when performing Software Update Point synchronization

When performing Software Update Point synchronization on the child primary site, the following error was logged in the wsyncmgr.log file:

Sync failed: WSUS server not configured. Source: CWSyncMgr::DoSync

In my case, affected primary site was child-site of the central primary site which is configured to perform synchronization with the Microsoft Update.
First thing I have stumbled upon was the following TechNet article: Troubleshooting Software Updates Synchronization Failureshttp://technet.microsoft.com/en-us/library/bb735874.aspx which also contains possible solutions for the exact problem I was experiencing. However, none of the suggested solutions worked for me.

After spending some time troubleshooting, it turned out that there was a problem with the synchronization between the central (parent) and the affected primary (child) site. In order to fix the problem, I had to make sure that:
1. Standard Sender Address is configured appropriately on both sites and that
2. Public keys between the sites are manually exchanged (How to Manually Exchange Public Keys Between Siteshttp://technet.microsoft.com/en-us/library/bb693690.aspx)

Once synchronization between sites was successfully established, error in the wsyncmgr.log file was gone and Software Update Point synchronization works as expected.

An error when performing Software Update Point synchronization

Custom DCM report for showing summary compliance for a configuration baseline by computer

Recently I had to come up with a custom Desired Configuration Management (DCM) report which shows summary compliance for a configuration baseline by computer.
This report is linked from the builtin Summary compliance by configuration baseline report which passes Configuration Baseline Name and Configuration Baseline Content Version as input parameters to my custom report.

Here is the actual query used within my custom report:

SELECT
v_R_System.Name0 AS 'Computer Name',
v_CICurrentComplianceStatus.ComplianceStateName AS 'Compliance State Name',
v_CICurrentComplianceStatus.ComplianceState AS 'Compliance State',
v_LocalizedCIProperties_SiteLoc.DisplayName AS 'DCM Baseline Name',
v_ConfigurationItems.CIVersion AS 'DCM Baseline Content Version'
FROM
v_BaselineTargetedComputers
INNER JOIN v_R_System ON v_R_System.ResourceID = v_BaselineTargetedComputers.ResourceID
INNER JOIN v_ConfigurationItems ON v_ConfigurationItems.CI_ID = v_BaselineTargetedComputers.CI_ID
INNER JOIN v_CICurrentComplianceStatus ON v_CICurrentComplianceStatus.CI_ID = v_ConfigurationItems.CI_ID AND v_CICurrentComplianceStatus.ResourceID = v_BaselineTargetedComputers.ResourceID
INNER JOIN v_LocalizedCIProperties_SiteLoc ON v_LocalizedCIProperties_SiteLoc.CI_ID = v_ConfigurationItems.CI_ID
WHERE
v_LocalizedCIProperties_SiteLoc.DisplayName = @name
AND
v_ConfigurationItems.CIVersion = @cicontentversion

Custom DCM report for showing summary compliance for a configuration baseline by computer

Configuration Manager Console fails to open

Problem description
Configuration Manager Console fails to open with the following error: “MMC cannot initialize the snap-in.

MMC cannot initialize the snap-in.
MMC cannot initialize the snap-in.

After clicking on OK, empty Configuration Manager Console opens as shown on the screenshot below:

Empty Configuration Manager Console
Empty Configuration Manager Console

Resolution
Open new instance of the Microsoft Management Console (MMC) (Start -> Run… -> mmc -> OK) and go to File -> Options -> Disk Cleanup.
Click on the Delete Files to delete MMC cache files and per-user preferences for console files which are saved in user’s profile.

MMC: Disk Cleanup
MMC: Disk Cleanup

After that, restart Configuration Manager Console to verify if it now works as expected.

Configuration Manager Console fails to open

Workflow Runtime: Failed to run a WMI query alert description

Today I have received the following alert from SCOM:

Alert: Workflow Runtime: Failed to run a WMI query
Alert description: Object enumeration failed
Query: ‘SELECT StartMode, State FROM Win32_Service WHERE Name = ‘MSSQLSERVER”
HRESULT: 0x800705af
Details: The paging file is too small for this operation to complete.
One or more workflows were affected by this.

This alert was raised by Windows Server 2008 R2-based computer and I believe that it is caused by an error explained in KB981314: The “Win32_Service” WMI class leaks memory in Windows Server 2008 R2 and in Windows 7http://support.microsoft.com/kb/981314.

This hotfix contains updated Cimwin32.dll which is located in %SYSTEMROOT%\System32\wbem folder. Updated file version is 6.1.7600.20683.

NOTE: Installation of KB981314 requires computer restart.

Workflow Runtime: Failed to run a WMI query alert description