O R G A N I C / F E R T I L I Z E R: using preloadpkgonsite.exe to stage compressed copies to child site distribution points

Dec 1, 2008

using preloadpkgonsite.exe to stage compressed copies to child site distribution points

UPDATE: john marcum sent me a kind email to let me know about a problem he ran into with preloadpkgonsite.exe in the new SCCM Toolkit V2 where under certain conditions, packages will not uncompress.  if you are using the v2 toolkit, PLEASE read this blog post before proceeding.

 

here’s a scenario that came up on the mssms@lists.myitforum.com mailing list. when confronted with a situation of large packages and wan links, it’s generally best to get the data to the other location without going over the wire. in this case, 75gb. :/

the “how” you get the files there is really not the most important thing to worry about. once they’re there and moved to the appropriate location, preloadpkgonsite.exe is required to install the compressed source files. once done, a status message goes back to the parent server which should stop the upstream server from copying the package source files over the wan to the child site.

anyway, if it’s a relatively small amount of packages, you can run the execution like so:

preloadpkgonsite.exe <pkgid>

of course, if it was a small amount of packages, we wouldn’t be having this conversation right now. so what do you do when you have an enormous directory with 75gb worth of packages?

well, it would look a little something like this…

  1. on the site server, navigate to <installdir>\bin\i386. this is where the preloadpkgonsite.exe should have been dropped.
  2. run the following command:
for /f "delims=." %a in ('dir /b \\<siteserver>\sms_<sitecode>\inboxes\pkginfo.box\*.pkg') do preloadpkgonsite.exe %a

that will effectively run preloadpkgonsite.exe against every known package on that child site server. now there are caveats to making this work – one being that the .pkg has to exist on the child site server.

i’m really blogging this for sherry kissinger who wrote this excellent blog article on replacing secondary site servers. she claims she doesn’t want to dig this up in her email. i think really, she didn’t want to be bothered with having to blog this. :)

this is just a small part to an overall solution for managing sites across the wan. make sure you read the information associated with the preloadpkgonsite.exe tool to understand the caveats and dependencies.