Download All Microsoft Management Packs for SCOM 2007, R2 and 2012 in Bulk V3

In short the script grabs the names and the links for all management packs on the site. Than it goes trough every MP link. From every MP page gets the version of it and all download links (msi, guides and etc.). Authors: Stanislav Zhelyazkov, Damian Flynn and Cameron Fuller

4.9 Star
Add to favorites
System Center
E-mail Twitter Digg Facebook
Sign in to ask a question

  • proxy server-issue
    1 Posts | Last post December 18, 2017
    • Great script btw, however it will not work if you company proxy requires authentication. Can you advise please how to properly allow the script to talk thru a proxy.
      below is my output.
      Invoke-WebRequest :  
      Authentication Required 
      You must be authenticated to access this URL. 
      Company Acceptable Use Policy 
      This is an optional acceptable use disclaimer that appears on every page. You may change the wording or remove this section entirely in index.html. 
      For assistance, please contact your system administrator. 
      generated 2017-12-18 10:12:19 by McAfee Web Gateway 
  • 'Bug' in Get-MSDownloadVersionDetails
    1 Posts | Last post November 17, 2017
    • The code should be changed to:
                  if ($HTTPData -match 'Version:[ ]{1,}</div><p>(.+?)</p></div>') 
                  if ($HTTPData -match 'Date Published:[ ]{1,}</div><p>(.+?)</p></div>') 
      without this change the 'Version' and 'Date Published'will not be extracted anymore
  • Great script
    1 Posts | Last post June 25, 2015
  • Error "This operation is not supported for a relative URI"
    3 Posts | Last post February 23, 2015
    • Great script! But unfortunately I get the following error message:
      Invoke-WebRequest : This operation is not supported for a relative URI.
      At C:\temp\Get-All-SCOM-MPs-V3.0.1.ps1:299 char:23
      +         $allmpspage = Invoke-WebRequest -Uri " ...
      + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : NotSpecified: (:) [Invoke-WebRequest], InvalidOperationException
          + FullyQualifiedErrorId : System.InvalidOperationException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
      [We have a proxy server that requires authentication. So I added 
       -Proxy "proxy address" -ProxyCredential "my username" to the Invoke-WebRequest line. I hope this is correct?!?]
    • Hi
      Currently the script does not support defining proxy. I will consider this suggestion and will see if we can implement it.
    • The script is currently using the inbox Invoke-WebRequest command to do most of the heavy lifting, so if you need a proxy server, maybe adding something like this to your profile would help
      replace myProxyName with the name of your proxy server, and the script should update the global variable for the session to indicate that you wish to use your proxy sever to get out.
      if(Test-Connection myProxyName -Count 1 -Quiet)
          $global:PSDefaultParameterValues = @{
  • v3.0
    2 Posts | Last post February 15, 2015
    • Thanks for the update, Stanislav (and @Damain_Flynn)! I like the new features and the transformation into functions; this makes the script much easier to use within automation (like you were suggesting...I am looking forward to seeing what you have in mind for that).
      I did notice that, as written currently, the Write-CMTraceLog function ignores any non-default output directories entered into the Get-SCOMManagementPacks function. I went ahead and fixed that, as well as made a few other small tweaks, and have the updated file available on my OneDrive, which you are free to review and keep any changes you like: 
      Thanks again!
    • Hi Gabriel,
      I think we fixed this in the latest version 3.0.1.
  • Possible future enhancements ?
    3 Posts | Last post February 15, 2015
    • Hi,
        Thanks for the great script - very useful.
      I'm not sure if others would find these suggestions helpful - but it think they might be worth considering for future versions.
      1) Option to copy all the extracted *.mp files to a central directory - to allow for quicker importing.
      2) As an extension to the above, option to exclude certain language specific mp's. e.g. or to only include English mps, or French mp's etc.
    • I should point out that I am currently using this line of powershell to achieve it... however I am well aware that my powershell is terrible... but it may be a stopgap if someone else has the same requirement.
      get-childitem c:\mps\microsoft -filter *.mp -exclude *,*,*,*,*,*,*,*,*,*,*,*,*,*,*,*,* -recurse | copy-item -Destination C:\mps\MasterExtract
    • Hi
      Cameron wrote something that might fit your needs I think:
  • Wildcard error
    2 Posts | Last post February 15, 2015
    • Attempting to run this in a SCOM 2012 R2 RU3 but get prompted to add missing wildcard. Any way around this without making changes to enhanced security on the server?
    • Hi Phil,
      The script does not have dependency on SCOM version. You can run it on any server with PowerShell 4.0 (this is the version we have tested it.) and direct Internet connection. I do not understand what the script prompts you for. May be if you give us more detailed information what are you doing and what you see will give us clue. Screenshots are always welcome.
  • Cookie Prompt using 2.4?
    6 Posts | Last post June 08, 2014
    • Anyone else getting a Windows Security Warning on v2.4?
      Prompts regarding adding a cookie to your machine
    • Yep. Something changed on the MS side last month. The way this parses the html is causing the popup to accept a cookie. Reworking the parser queries to eliminate that from happening  Unless Stanislav gets to it sooner. :)
    • Thank you guys for notifying me about this. I will try to find workaround for this.
    • Couple problems. The first is a known problem with invoke-webrequest and parsedhtml.  If the site that you are parsing has cookies other than session cookies powershell will prompt to accept/deny the cookie.  usually this just affects scripts that are being run in PSE but it seems to affect powershell.exe as well now.  The only option I've ever had success with is using basicparsing instead but that requires the scraping method to be alot more complicated.  
      Second issue is looks like some of MS download links have changed formats again.  The tags aren't the same anymore so things are breaking down determining version, date, etc.
      Third issue is related to the second.  Getting duplicate download links for some MPs.  
      I've got the second and third items resolved but need to look into the download links that still don't parse because of the content changes. Also the basic parsing is a major pain....  I'm actually hopeful it might a bug in a recent IE/Windows patch that came out in the past few months as I've only seen this happen in ise, never in commandline powershell.
    • So I guess it's stopped working now...??
      Out-File : The device is not ready.
      At E:\Get-All-SCOM-MPs-V2.5.ps1:202 char:26
      + "Failure,$Date,$mpname" |Out-File "$dirmp\$MPErrorLogfile" -Append
      +                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
          + CategoryInfo          : OpenError: (:) [Out-File], IOException
          + FullyQualifiedErrorId : FileOpenFailure,Microsoft.PowerShell.Commands.OutFileCommand
      MP Name: System Center Global Service Monitor 
      MP Link:
      Confirmation Link:
      MP Version: 1.0.1800.1
      MP Release Date: 1-28-2013
      Download Links: Global Service Monitor.msi
      Downloading - System Global Service Monitor.msi ...
      Cannot Invoke MP System Center Global Service Monitor Web page
    • Hi Kelvin,
      Just checked and the latest version is working for me. I guess the issue is related to something local on the server you are running the script.
  • Great Work
    2 Posts | Last post February 22, 2014
    • Thank so much for this great tool Stanislav. It works like a charm.
    • Thanks Hector
  • updating of management packs
    2 Posts | Last post January 30, 2014
    • I'm new to SCOM and creating of management packs, and this question is not exactly about your script (which just finished its job for me). Does Microsoft every update a previously published management pack, and when they do, does this script find and pull down the update without running through the whole list again?
    • We update management pack versions in this Wiki here:
      and the script grabs the latest version from that wiki. The script will run trough the whole script but will download only those MPs that are not in the folder structure that is created during download. This means that if you run the script and download MPs and after that a new version of MP is published and run the script again will be downloaded only the new version.
1 - 10 of 20 Items