Serge Chegorian's System Center Blog

Serge Chegorian's System Center Blog

SCCM Keeps Processing Package

December 4th, 2015

Sometimes you may see several hundred thousand informational messages produced by the child site distribution manager. The messages look like this:

SMS Distribution Manager successfully processed package “Java 7 Update 91” (package ID = CAS000D3).
SMS Distribution Manager is beginning to process package “Java 7 Update 91” (package ID = CAS000D3).
SMS Distribution Manager successfully processed package “Java 7 Update 91” (package ID = CAS000D3).
SMS Distribution Manager is beginning to process package “Java 7 Update 91” (package ID = CAS000D3).
SMS Distribution Manager successfully processed package “Java 7 Update 91” (package ID = CAS000D3).
SMS Distribution Manager is beginning to process package “Java 7 Update 91” (package ID = CAS000D3).

This package looping may affect both existing and non-existing packages.

Workaround:

On the affected server go to inboxes\distrmgr.box folder.

Select and delete CAS000D3.PKG and CAS000D3.PKN files

Connect to CAS DB and run the following query:

SELECT * FROM PkgServers where NALPath like ‘%<affected server name>%’ and PkgID = ‘CAS000D3′

If this query returns any result redistribute CAS000D3 package.

 

How to export SCCM 2012 ADR

May 11th, 2015

How to export SCCM 2012 Automatic Deployment Rule?

1. Start SCCM 2012 PowerShell core by clicking on the down arrow in the left upper corner of SCCM 2012 Management Console – Connect via Windows PowerShell.

2. Use Get-CMSoftareUpdateAutoDeploymentRule to display all rules or Get-CMSoftareUpdateAutoDeploymentRule -Name “<rule name>” to display a specific rule.

3. Format output and/or redirect it to a file

Co-hosting SCCM PXE point, DHCP and WDS services

January 22nd, 2015

SCCM PXE point or SCCM PXE enabled distribution point can be co-hosted with DHCP services. This configuration though is not recommended but is fully supported by Microsoft.

In order to configure DHCP and Windows Deployment Services on the same host you must do the following:

1. Install DHCP and WDS

2. For DHCP configure option 60 with with the value PXEClient. Do not enable and configure options 66 and 67.

3. Go to WDS properties, tick an option ‘Do not listen on port 67

Now you can start using WDS or configure SCCM PXE option on the top of WDS

SCCM 2012 Software Updates do not install

August 25th, 2014

In SCCM 2012 you may come across the situation when you crate a Software Update package but it does not install. You may check DP, policy, client and you see it is detected but is still not deployed.

Have a look at your package size specifically the number of updates. Exactly like for application each Software Update has it’s maximum runtime which is unmanageable in SCCM 2007 and can be changed in SCCM 2012 R2 (10 minutes by default). The total runtime for the package is a sum of maximum runtimes for every individual Software Update. If this sum exceeds 24 hours your package will never run because SCCM believes there is no window to run it.

Split up your package in several smaller packages and it will work.

SCCM 2007 R3 Reporting Point Error 500

August 1st, 2014

Sometimes when you access SCCM 2007 reports running on Reporting Point you may see HTTP Error 500 – Internal server error. If it affects some of your reports where you would anticipate a large number of records in the output it could be caused by insufficient buffer size. This is a well known issue and the work around it can be found here.

But what if all your reports are affected? Try several reports again and go to IIS logs. You will see something like this:

GET /SMSReporting_XXX/Report.asp ReportId=200|372|ASP_0177_:_8007007e|Server.CreateObject_Failed 80

This means that one of Reporting Point ActiveX is missing.

Check <webroot>\SMSComponent folder. If consistent it must contain the following files:

    FormatMessageCtl.dll
    smscomponent.dll
    SMSRPH.exe

Most likely FormatMessageCtl.dll will be missing

Go to SCCM 2007 SP2 set up DVD, SMSSETUP\BIN\I386

Run reportinginstall.exe /x

Select the file FormatMessageCtl.dll (you will see 3 instances but they are all the same) and extract it to <webroot>\SMSComponent folder.

That’s it, you don’t need to register this DLL or restart IIS and SCCM. Just run report again.


Why did it happen?

Go to <wwwroot>\SMSReporting_<site code> folder and check for install.log file. Check the file time-stamp and dates in the file. Most likely your Reporting Point was recently reinstalled.

SCCM Component Manager service “pings” all installed components every 3600 seconds. If it does not have a response for several consequent attempts it reinstalls the component. This is the feature of SCCM 2007 and according to Microsoft Premium Support it cannot be configured or adjusted. So apparently something has happened to your Reporting Point which has triggered component reinstallation.

How to create a new SCCM system role with a script

August 8th, 2013

Both SCCM 2007 and 2012 keep system role information in the site control file. So the two main operation at the begining and at the end of the script will be getting the file handle, refreshing the file, commit changes and release the handle.

$ComputerName = "MySiteServer"
$MyNewRoleServer = "MyNewRoleServer"
$sitecode = "ABC"
$nameSpacePath = "\\$ComputerName\root\sms\site_$sitecode"
$domainname=".mydomain.local"

# Get a session handle for the site control file
$scf = Invoke-WmiMethod -Namespace $NameSpace -class SMS_SiteControlFile -name GetSessionHandle -computername $ComputerName

# Refresh the WMI copy of the site control file
$refresh = Invoke-WmiMethod -Namespace $NameSpace -class SMS_SiteControlFile -name RefreshSCF -ArgumentList $sitecode -computername $ComputerName
<#
your main script will be here
#>
# Commit site control file from WMI to the actual file
$commit = Invoke-WmiMethod -Namespace $NameSpace -class SMS_SiteControlFile -name CommitSCF $sitecode -computername $ComputerName

# Release session handle
$scf = Invoke-WmiMethod -Namespace $NameSpace -class SMS_SiteControlFile -name ReleaseSessionHandle -ArgumentList $scf.SessionHandle -computername $ComputerName

SCCM Distribution Point Groups Audit

July 29th, 2013

In a complex SCCM environment when you’re dealing with a large number of Distribution Point Groups it is always good to run a periodic audit. There is no out of box report so here are some reports I use.

1. List of all DP groups and group members:

select distinct sGroupName, SUBSTRING(NALPath,
CHARINDEX(‘\\’, NALPath) + 2,
CHARINDEX(‘”]’, NALPath) – CHARINDEX(‘\\’, NALPath) – 3 ) as [DP Name] from v_DistributionPointGroup where NALPath not like ”* order by sGroupName asc, “DP Name” asc

*) – the first record is always a blank ‘placeholder’

2. The list of Members of Specific DP Group – Secondary

select SUBSTRING(NALPath,
CHARINDEX(‘\\’, NALPath) + 2,
CHARINDEX(‘”]’, NALPath) – CHARINDEX(‘\\’, NALPath) – 3 ) as [DP Name] from v_DistributionPointGroup where sGroupName=@DPGroupName* and NALPath not like ” order by “DP Name” asc

*) Prompted value

3. List of all DP groups DP belongs to – Secondary

select sGroupName as [DP Group Name] from v_DistributionPointGroup where NALPath like ‘%’+@DPName+’%’ and NALPath not like ” order by “DP Group Name” asc

*) Prompted value

How to populate SCCM collection with the members of subcollection

July 18th, 2013

In some situations you may want to populate your collection with the members of all its subcollections. For example you want to assign the same maintenance window to several dynamically populated collections and to minimize the administrative overhead. If your child collection ID’s are for example ABC000A1 and ABC000A2, your parent collection query will be:

select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,
SMS_R_SYSTEM.SMSUniqueIdentifier,SMS_R_SYSTEM.ResourceDomainORWorkgroup,
SMS_R_SYSTEM.Client from SMS_R_System where SMS_R_System.ResourceId in (select ResourceID from SMS_CM_RES_COLL_ABC000A1) or SMS_R_System.ResourceId in (select ResourceID from SMS_CM_RES_COLL_ABC000A2)

Serge Chegorian's System Center Blog

Serge Chegorian's System Center Blog