Presenting… StartComponentCleanup for MSI (including Office)

Discussion in 'MDL Projects and Applications' started by 600415, Aug 11, 2018.

Tags:
  1. 600415

    600415 MDL Junior Member

    Aug 31, 2015
    86
    89
    0
    #1 600415, Aug 11, 2018
    Last edited: Sep 12, 2018
  2. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    8,206
    27,850
    270
  3. ch100

    ch100 MDL Member

    Sep 11, 2016
    176
    163
    10
    PatchCleaner has an option to move files to a backup location.
     
  4. ch100

    ch100 MDL Member

    Sep 11, 2016
    176
    163
    10
    If there is no better alternative to the superseded Office patches cleanup and the script is given all clear, I would suggest that this script should be given more attention and made a sticky or a reference in any other way on this forum. Otherwise it will get lost among other less relevant threads.
    I know of few other alternatives to clean superseded msp/msi, one which I mentioned here, but this script seems to be the most complete way to clean up Office patches as far as I know.
    For Windows we have the official way, but not for Office.
     
  5. Mr.X

    Mr.X MDL Guru

    Jul 14, 2013
    6,077
    13,647
    210
    Saving whatever amount of GBs is always good. Specially for those like me who relies on imaging (system image). Less R/W to the HDD, cool.
     
  6. Tovadyk

    Tovadyk MDL Novice

    Jul 21, 2015
    23
    14
    0
    #9 Tovadyk, Aug 15, 2018
    Last edited: Aug 16, 2018
    Tried it on O2013x86 and Win81x64 - works well - ran as cscript c:\temp\clean.vbs
    On most msi stores it gave a 1646 return code and I recovered about 15 GB

    When used with O2010 the return code is almost always 0...
     
  7. 600415

    600415 MDL Junior Member

    Aug 31, 2015
    86
    89
    0
    I'm going to add permanent update detection when i have time. Then it should skip them and not give error 1646.

    Or, given how patch sequencing works (content of superseded updates is completely disregarded when doing any repair on the product, therefore their uninstall is almost a no-op) i could add a “dangerous” option that would mark such an update as uninstallable and then uninstall it.

    I have for now tested this manually with adobe reader and it still worked afterwards.
     
  8. 600415

    600415 MDL Junior Member

    Aug 31, 2015
    86
    89
    0
    Updated tha script to add permanent patch detection and (optional) “force” removal for all yer Silverlight and Adobe Reader goodness.
     
  9. STaRDoGG

    STaRDoGG MDL Novice

    Dec 2, 2015
    9
    1
    0
    Out of curiosity, is this better than doing ... ?

    Code:
    DISM /Online /Cleanup-Image /SPSuperseded
    and/or

    Code:
    DISM /Online /Cleanup-Image /StartComponentCleanup /ResetBase
     
  10. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    17,350
    22,054
    340
    Do those commands cleanup superseded MSP patches (for office)?
     
  11. STaRDoGG

    STaRDoGG MDL Novice

    Dec 2, 2015
    9
    1
    0
    Dunno, that's why I was asking ... ;)
     
  12. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    17,350
    22,054
    340
    It was more of a rhetorical question;):D
     
  13. STaRDoGG

    STaRDoGG MDL Novice

    Dec 2, 2015
    9
    1
    0
    You're just wayyy too smart for me, man ... ;)