Saturday, February 20, 2016

Fixing a Stuck Distribution Point




When building a new SMS Distribution Point for a remote child site, you may notice that sometimes not all of your packages get copied down from the parent site and into the \\Server\SMSPKG directory of your distribution point. Or perhaps someone has deleted some large PkgID.pck files on one of your site servers in the interests of saving disk space.


Simply doing a “refresh distribution point” for these no-shows doesn't work if the corresponding PkgID.pck file is not present on the child site server (i.e., the site server that controls the Distribution Point that we are working with here). In such a case, the Distribution Manager on the child site will tell you something like:


The compressed files for package ZZZ00148 hasn't arrived from site ZZZ yet, will retry later.


In this example “ZZZ” will represent the parent SMS site and “ZZZ00148” will represent the PackageID of the package that we are trying to send.


The problem here is that the Distribution Manager on the child site will wait forever for the parent site to send the PkgID.pck file, and if it never gets sent, you will be waiting for a long time…


Refreshing ALL of your Distribution Points would work, but that may not be an option for you, particularly if you are running a worldwide SMS hierarchy, which typically includes slow WAN links between SMS sites.


So you need to jump start the distribution process. Here's one way you can do it:


In this example, we have 11 packages that have not made it down to the distribution point.


First, go to Enterprise Manager on your parent SMS site server (Site “ZZZ” on server “MGMT01” in this example), go to the SMS database, and open the “PkgStatus” table with “Query”.

0x01 graphic


The following view will appear:

0x01 graphic


Take the text that's circled above and delete it. Replace it with the following:


SELECT ID, SiteCode, PkgServer, Status, SourceVersion

FROM PkgStatus

WHERE (ID = 'ZZZ00148' OR

ID = 'ZZZ00162' OR

ID = 'ZZZ00174' OR

ID = 'ZZZ00175' OR

ID = 'ZZZ00176' OR

ID = 'ZZZ00177' OR

ID = 'ZZZ00179' OR

ID = 'ZZZ0017B' OR

ID = 'ZZZ00190' OR

ID = 'ZZZ00192' OR

ID = 'ZZZ0019D') AND (SiteCode = 'P00') AND (PkgServer = 'MGMT03')


Note the Package ID's. These are the Package ID's corresponding to the packages that we want placed on the Distribution Point.Hit the red exclamation point (“!”) to execute the SQL query, and you will see your results show up in the lower pane.


In the lower pane (circled in red) is the Status and the SourceVersion for each package in the query you just executed.

0x01 graphic

You will need to change all the values of “SourceVersion” (circled in red) to 0.


Before you do this, there are a few things you should know:


  1. Be careful here! You are making real-time changes to data in the SMS database. No fat fingering allowed… ;). You do have a current backup, right?


  1. Be aware that you will generate network traffic when the *.pck files copy from the parent site server to the child site server. There is a distinct possibility that these *.pck files are large (because missing *.pck files can often mean that somebody was trying to free disk space by deleting the largest ones).


0x01 graphic


Here we have changed all the values of “SourceVersion” to 0 (zero). At this point we can refresh the distribution point from the SMS admin console on our parent primary site.

0x01 graphic


Next, go into the SMS Admin console and refresh the DP's as shown below.


0x01 graphic


Tip: if you are running a large SMS hierarchy with many packages, it will help you here if you have a spreadsheet that illustrates PackageID's with Package Names so they are easier to find.


After doing this, you can watch the Distribution Manager log on your *parent* Primary:


“Needs to send the compressed package for package ZZZ00148 to site P00”

Sending a copy of package ZZZ00148 to site P00

Created minijob to send compressed copy of package ZZZ00148 to site P00. Tranfer root = \\MGMT01\SMS_CPSF$\ZZZ00148.PCK.

A distribution point has been changed at this site, adding site P00 to the list of sites to which we are sending package ZZZ00148.

Sent package changes to site P00 for package ZZZ00148

StoredPkgVersion (2) of package ZZZ00148. StoredPkgVersion in database is 2.


In the distribution manager log of the *child* site server, you will see the following:


Start updating the package ZZZ00148...

Successfully created/updated the package ZZZ00148

Validating the compressed file F:\SMSPKG\ZZZ00148.PCK for package ZZZ00148

Decompressing package F:\SMSPKG\ZZZ00148.PCK to F:\_S Mt0ir.TMP

Attempting to create subdirectory ZZZ00148 under the export.

Successsfully created the package directory SMSPKG\ZZZ00148\ under the export.

Successfully created sub directory ZZZ00148 off MSWNET:["SMS_SITE=P00"]\\REMOTE_DP\smsapps\SMSPKG\ZZZ00148\

Copying F:\_S Mt0ir.TMP\FlashPlayer.exe to \\REMOTE_DP\smsapps\SMSPKG\ZZZ00148\FlashPlayer.exe, OK

Successfully copied package ZZZ00148 from F:\_S Mt0ir.TMP\ to MSWNET:["SMS_SITE=P00"]\\REMOTE_DP\smsapps\SMSPKG\ZZZ00148\

Forward package status for pkg ZZZ00148 to site ZZZ


Tip: Trace32.exe from the SMS 2003 Tool Kit is a great tool to watch these log files in real time.

Going to the distribution point, you can visually verify that the files are present by looking for the directories corresponding to the package ID's. From the entries in the DistMgr.log in the example above, we see that package “ZZZ00148” has now been placed on the Distribution Point.

0x01 graphic


After each of the packages that you have reset have reached the distribution point, the problem is solved.


In this example, I used SMS 2003 with SP1 and SQL 2000 SP3 running on Windows 2003 servers. As always, the usual disclaimers apply (i.e., test first in a lab, get help from Microsoft if you need it, don't break anything, etc).


I hope this example helps you!

No comments:

Post a Comment