abbodi1406's Batch Scripts Repo

Discussion in 'Scripting' started by abbodi1406, May 4, 2017.

  1. mehdibleu

    mehdibleu MDL Expert

    Jun 14, 2017
    1,009
    251
    60
  2. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    47,273
    94,758
    450
    Who cares?
     
  3. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    16,215
    84,869
    340
    #283 abbodi1406, Feb 23, 2018
    Last edited: Feb 23, 2018
    (OP)
    W10UI 4.4

    - fixed: skip .NET lang pack updates for WinPE images (thanks @dback)
    - improvement: updated WinRE.wim will not be left over, if the target is install.wim file
     
  4. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    47,273
    94,758
    450
    #284 Enthousiast, Feb 23, 2018
    Last edited: Feb 23, 2018
    What .NET LP's? I thought they weren't needed at all because they already would be inside the target files?

    EDIT: probably about older builds?
     
  5. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    16,215
    84,869
    340
    updated to v4.4

    fixed the fix :p
     
  6. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    47,273
    94,758
    450
    Your fix fixed the fix:
    Code:
    ============================================================
    Running W10UI v4.4
    ============================================================
    
    ============================================================
    Extracting .cab files from .msu files
    ============================================================
    
    1/6: Windows10.0-KB4033393-x86.msu
    2/6: windows10.0-kb4033409-x86_bc85f973d67f3c89c9ff7b25af3fc073eb3b139d.msu
    3/6: Windows10.0-KB4049065-x86.msu
    4/6: Windows10.0-KB4073562-x86.msu
    5/6: windows10.0-kb4074595-x86_ff2a6bef90c646c4a77621825c227e4a02883921.msu
    6/6: Windows10.0-KB4077525-x86.msu
    
    ============================================================
    Extracting files from update cabinets (.cab)
    *** This will require some disk space, please be patient ***
    ============================================================
    
    1/6: Windows10.0-KB4033393-x86.cab
    2/6: Windows10.0-KB4033409-x86.cab
    3/6: Windows10.0-KB4049065-x86.cab
    4/6: Windows10.0-KB4073562-x86.cab
    5/6: Windows10.0-KB4074595-x86.cab
    6/6: Windows10.0-KB4077525-x86.cab
    
    ============================================================
    Mounting install.wim - index 1/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Mounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Checking Updates...
    ============================================================
    
    ============================================================
    Installing servicing stack update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.0
    
    Processing 1 of 1 - Adding package Package_for_KB4049065~31bf3856ad364e35~x86~~10.0.1.3
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Installing updates...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 4 - Adding package Package_for_KB4033393~31bf3856ad364e35~x86~~10.0.1.1549
    [==========================100.0%==========================]
    Processing 2 of 4 - Adding package Package_for_KB4033409~31bf3856ad364e35~x86~~10.0.1.1549
    [==========================100.0%==========================]
    Processing 3 of 4 - Adding package Package_for_KB4073562~31bf3856ad364e35~x86~~10.0.1.2
    [==========================100.0%==========================]
    Processing 4 of 4 - Adding package Package_for_KB4074595~31bf3856ad364e35~x86~~10.0.1.0
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Cleaning up OS image
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Adding .NET Framework 3.5 feature
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Enabling feature(s)
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Reinstalling cumulative update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Updating winre.wim
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Mounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.0
    
    Processing 1 of 1 - Adding package Package_for_KB4049065~31bf3856ad364e35~x86~~10.0.1.3
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_KB4073562~31bf3856ad364e35~x86~~10.0.1.2
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image File : I:\W10UI_4.X\2016_LTSB\winre.wim
    Image Index : 1
    Saving image
    [==========================100.0%==========================]
    Unmounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Exporting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Adding updated winre.wim
    ============================================================
    
            1 file(s) copied.
    
    ============================================================
    Unmounting install.wim - index 1/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image File : i:\W10UI_4.X\2016_LTSB\Work_x86\sources\install.wim
    Image Index : 1
    Saving image
    [==========================100.0%==========================]
    Unmounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Mounting install.wim - index 2/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Mounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Checking Updates...
    ============================================================
    
    ============================================================
    Installing servicing stack update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.0
    
    Processing 1 of 1 - Adding package Package_for_KB4049065~31bf3856ad364e35~x86~~10.0.1.3
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Installing updates...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 4 - Adding package Package_for_KB4033393~31bf3856ad364e35~x86~~10.0.1.1549
    [==========================100.0%==========================]
    Processing 2 of 4 - Adding package Package_for_KB4033409~31bf3856ad364e35~x86~~10.0.1.1549
    [==========================100.0%==========================]
    Processing 3 of 4 - Adding package Package_for_KB4073562~31bf3856ad364e35~x86~~10.0.1.2
    [==========================100.0%==========================]
    Processing 4 of 4 - Adding package Package_for_KB4074595~31bf3856ad364e35~x86~~10.0.1.0
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Cleaning up OS image
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Adding .NET Framework 3.5 feature
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Enabling feature(s)
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Reinstalling cumulative update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Adding updated winre.wim
    ============================================================
    
            1 file(s) copied.
    
    ============================================================
    Unmounting install.wim - index 2/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image File : i:\W10UI_4.X\2016_LTSB\Work_x86\sources\install.wim
    Image Index : 2
    Saving image
    [==========================100.0%==========================]
    Unmounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Rebuilding install.wim
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Exporting image
    [==========================100.0%==========================]
    Exporting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Mounting boot.wim - index 1/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Mounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Checking Updates...
    ============================================================
    
    ============================================================
    Installing servicing stack update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.0
    
    Processing 1 of 1 - Adding package Package_for_KB4049065~31bf3856ad364e35~x86~~10.0.1.3
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Installing updates...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_KB4073562~31bf3856ad364e35~x86~~10.0.1.2
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Resetting WinPE image base
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Unmounting boot.wim - index 1/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image File : i:\W10UI_4.X\2016_LTSB\Work_x86\sources\boot.wim
    Image Index : 1
    Saving image
    [==========================100.0%==========================]
    Unmounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Mounting boot.wim - index 2/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Mounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Checking Updates...
    ============================================================
    
    ============================================================
    Installing servicing stack update...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.0
    
    Processing 1 of 1 - Adding package Package_for_KB4049065~31bf3856ad364e35~x86~~10.0.1.3
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Installing updates...
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_KB4073562~31bf3856ad364e35~x86~~10.0.1.2
    [==========================100.0%==========================]
    The operation completed successfully.
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    Processing 1 of 1 - Adding package Package_for_RollupFix~31bf3856ad364e35~x86~~14393.2097.1.6
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Resetting WinPE image base
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image Version: 10.0.14393.1883
    
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Unmounting boot.wim - index 2/2
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Image File : i:\W10UI_4.X\2016_LTSB\Work_x86\sources\boot.wim
    Image Index : 2
    Saving image
    [==========================100.0%==========================]
    Unmounting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Rebuilding boot.wim
    ============================================================
    
    Deployment Image Servicing and Management tool
    Version: 10.0.16299.15
    
    Exporting image
    [==========================100.0%==========================]
    Exporting image
    [==========================100.0%==========================]
    The operation completed successfully.
    
    ============================================================
    Removing temporary extracted files...
    ============================================================
    
    
    ============================================================
    Creating updated ISO file...
    ============================================================
    
    OSCDIMG 2.56 CD-ROM and DVD-ROM Premastering Utility
    Copyright (C) Microsoft, 1993-2012. All rights reserved.
    Licensed only for producing Microsoft authorized content.
    
    
    Scanning source tree (500 files in 13 directories)
    Scanning source tree complete (987 files in 95 directories)
    
    Computing directory information complete
    
    Image file is 2832400384 bytes (before optimization)
    
    Writing 987 files in 95 directories to Win10_14393.2097_2018-02-24.iso
    
    100% complete
    
    Storage optimization saved 31 files, 14583808 bytes (1% of image)
    
    After optimization, image file is 2820067328 bytes
    Space saved because of embedding, sparseness or optimization = 14583808
    
    Done.
    
    ============================================================
       Finished
    ============================================================
    
    
    Press any key to exit.
    
    
     
  7. with only one edition (pro) of windows 10 iso extracted folder, you w10ui script take very long time to integrate updates, but ntlite and msmg take almost half time compared to your script. why is that?
     
  8. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    16,215
    84,869
    340
    Define "very long"
    and what's the on-screen log says?
     
  9. okay, i'll come here with full details.
     
  10. Enthousiast

    Enthousiast MDL Tester

    Oct 30, 2009
    47,273
    94,758
    450
    Did you set cleanup image to 1 and resetbase to 0? That will take some time to finish. Other tools will probably do the resetbase and that will take much less time but will break windows functions like resetpc.
     
  11. Gladwin

    Gladwin MDL Member

    Dec 20, 2012
    232
    111
    10
    just want ask some update WHD-W7UI ver4.0 , when i update will pop up some error

    Image Version: 6.1.7601.17514

    Processing 1 of 11 - Adding package Microsoft-Windows-PlatformUpdate-Win7-SRV08R2-Package-TopLevel~31bf3856ad364e35~amd64~~7.1.7601.16492
    [==========================100.0%==========================]
    Processing 2 of 11 - Adding package Package_for_KB2750841_BF~31bf3856ad364e35~amd64~~6.1.1.3
    [==========================100.0%==========================]
    Processing 3 of 11 - Adding package Package_for_KB2818604_BF~31bf3856ad364e35~amd64~~6.1.1.0
    [==========================100.0%==========================]
    Processing 4 of 11 - Adding package Package_for_KB3020369~31bf3856ad364e35~amd64~~6.1.1.1
    [==========================100.0%==========================]
    Processing 5 of 11 - Adding package Package_for_KB3046480_BF~31bf3856ad364e35~amd64~~6.1.1.2
    [==========================100.0%==========================]
    Processing 6 of 11 - Adding package Package_for_KB3064209~31bf3856ad364e35~amd64~~6.1.1.1
    [==========================100.0%==========================]
    Processing 7 of 11 - Adding package Package_for_KB3161102~31bf3856ad364e35~amd64~~6.1.2.0
    [==========================100.0%==========================]
    Processing 8 of 11 - Adding package Package_for_KB3172605~31bf3856ad364e35~amd64~~6.1.1.4
    [=================== 32.9% ]
    Processing 9 of 11 - Adding package Package_for_KB3179573~31bf3856ad364e35~amd64~~6.1.1.0
    [==========================100.0%==========================]
    Processing 10 of 11 - Adding package Package_for_KB3184143~31bf3856ad364e35~amd64~~6.1.1.4
    [==========================100.0%==========================]
    Processing 11 of 11 - Adding package Microsoft-Windows-Winhelp-Update-Client-TopLevel~31bf3856ad364e35~amd64~~6.1.0.1
    [==========================100.0%==========================]

    Error: 14005

    Package Package_for_KB3172605 may have failed due pending updates to servicing components in the image. Try the command again.The command completed with errors.
    For more information, refer to the log file.

    may i ask what problem for that ?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  12. mehdibleu

    mehdibleu MDL Expert

    Jun 14, 2017
    1,009
    251
    60
    Try again to integrate all the updates from the beginning from a new install.wim and see the result.
     
  13. Gladwin

    Gladwin MDL Member

    Dec 20, 2012
    232
    111
    10
    this is the updates from the beginning from a new install.wim , the old version WHD-W7UI is working fine , but use WHD-W7UI ver4.0 will become error when the update ~
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  14. mehdibleu

    mehdibleu MDL Expert

    Jun 14, 2017
    1,009
    251
    60
    So that means there is an error in the script of the last version ver4.0, @abbodi1406 has to be informed about this.
     
  15. abbodi1406

    abbodi1406 MDL KB0000001

    Feb 19, 2011
    16,215
    84,869
    340
    #295 abbodi1406, Feb 26, 2018
    Last edited: Feb 26, 2018
    (OP)
    It's dism integration error, nothing the script can control or related to

    but maybe the cause is SSU KB3177467 offline integration workaround
    although it worked without issue in my tests

    anyway, without C:\Windows\Logs\DISM\dism.log i cannot determine the reason
     
  16. mehdibleu

    mehdibleu MDL Expert

    Jun 14, 2017
    1,009
    251
    60
    that's why i told him to repeat the procedure with the new version.
    but what makes you think that it's especially this update KB3177467 that caused the integration problem in his case ?
    if i go by what he showed in test integratio, we can see that it's KB3172605 update that wasn't integrated so the problem can be related to this update.
     
  17. dback

    dback MDL Junior Member

    Nov 30, 2012
    57
    25
    0
    Integration using your W7UI 4.0 script works fine here for me @abbodi1406
     
  18. turned out it was my hdd fault,thats why your w10ui was taking long time (3+hours) on win 10 ltsb x64. i was using other tools and your w10ui on different 2 hdd, i tested msmg and w10ui both on my new hdd, results are now almost identical. :hug2:
     
  19. Mr.X

    Mr.X MDL Guru

    Jul 14, 2013
    8,575
    15,646
    270
  20. MonarchX

    MonarchX MDL Expert

    May 5, 2007
    1,732
    313
    60
    #300 MonarchX, Mar 2, 2018
    Last edited: Mar 2, 2018
    Wasn't there some kind of new KMS_VL_ALL with cleaner code that was posted not that long ago?

    Does W10UI 4.4 recognize both packages for NetFX 4.7.1 (326MB Windows10.0-KB4033393-x64.cab and 35MG Windows10.0-KB4054855-x64.cab) and install them in the correct order?