Optimize-Offline Guide - Windows Debloating Tool, Windows 1803, 1903, 19H2, 1909, 20H1 and LTSC 2019

Discussion in 'Windows 10' started by KedarWolf, Jul 30, 2019.

  1. zbigniew59

    zbigniew59 MDL Member

    Joined:
    May 14, 2016
    Messages:
    130
    Likes Received:
    39
    Trophy Points:
    10
    I have been using this script for a long time and I confirm that after appropriate modifications the newest scrypt works for me flawlessly on my iso pl-PL.
    I even debloated Win 11 without any errors.
     
  2. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    I open the file "Start-Optimize.ps1" with PoweShell. It opens and closes immediately....
     
  3. KedarWolf

    KedarWolf MDL Addicted

    Joined:
    Mar 17, 2016
    Messages:
    533
    Likes Received:
    415
    Trophy Points:
    30
  4. strotee

    strotee MDL Member

    Joined:
    Jan 30, 2011
    Messages:
    120
    Likes Received:
    124
    Trophy Points:
    10
    open powershell, change directory to location of "Start-Optimize.ps1", execute it, now (hopefully) you'll see the error that it's reporting
     
  5. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    Yes!
     
  6. KedarWolf

    KedarWolf MDL Addicted

    Joined:
    Mar 17, 2016
    Messages:
    533
    Likes Received:
    415
    Trophy Points:
    30
  7. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    ObjectNotFound: (Start-Optimize.ps1:String) [], CommandNotFoundException
     
  8. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
  9. strotee

    strotee MDL Member

    Joined:
    Jan 30, 2011
    Messages:
    120
    Likes Received:
    124
    Trophy Points:
    10
    what's your Configuration.json look like?
     
  10. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    {
    "_Info": [
    "This is a JSON based Configuration file for Optimize-Offline.",
    "Ensure proper formatting is used when editing the JSON parameter values.",
    "Boolean parameter values use true and false. String parameter values must be enclosed in double-quotes."
    ],
    "SourcePath": "E:\\1\\Win.iso",
    "WindowsApps": "All",
    "SystemApps": true,
    "Capabilities": true,
    "Packages": true,
    "Features": true,
    "DeveloperMode": false,
    "WindowsStore": false,
    "MicrosoftEdge": false,
    "Win32Calc": true,
    "Dedup": false,
    "DaRT": [
    ],
    "Registry": true,
    "Additional": {
    "Setup": false,
    "Wallpaper": false,
    "SystemLogo": false,
    "LockScreen": false,
    "RegistryTemplates": false,
    "LayoutModification": false,
    "Unattend": false,
    "Drivers": false,
    "NetFx3": false
    },
    "ComponentCleanup": false,
    "ISO": "No-Prompt"
    }
     
  11. KedarWolf

    KedarWolf MDL Addicted

    Joined:
    Mar 17, 2016
    Messages:
    533
    Likes Received:
    415
    Trophy Points:
    30
    Better to insert the stuff as code like below or formatting gets messed up. Then we can tell better if there are any errors.

    Code:
    {
      "_Info": [
        "This is a JSON based Configuration file for Optimize-Offline.",
        "Ensure proper formatting is used when editing the JSON parameter values.",
        "Boolean parameter values use true and false. String parameter values must be enclosed in double-quotes."
      ],
      "SourcePath": "C:\\Users\\Kedar\\Downloads\\en_windows_10_business_editions_version_21h1_updated_jun_2021_x64_dvd_8222df3d.iso",
      "WindowsApps": "Select",
      "SystemApps": true,
      "Capabilities": true,
      "Packages": true,
      "Features": true,
      "DeveloperMode": false,
      "WindowsStore": false,
      "MicrosoftEdge": false,
      "Win32Calc": true,
      "Dedup": false,
      "DaRT": [
      ],
      "Registry": true,
      "Additional": {
        "Setup": true,
        "Wallpaper": false,
        "SystemLogo": false,
        "LockScreen": false,
        "RegistryTemplates": true,
        "LayoutModification": false,
        "Unattend": false,
        "Drivers": true,
        "NetFx3": true
      },
      "ComponentCleanup": false,
      "ISO": "No-Prompt"
    }
     
  12. KingOfDecepton

    KingOfDecepton MDL Novice

    Joined:
    Jul 1, 2021
    Messages:
    8
    Likes Received:
    0
    Trophy Points:
    0
    Code:
    {
      "_Info": [
        "This is a JSON based Configuration file for Optimize-Offline.",
        "Ensure proper formatting is used when editing the JSON parameter values.",
        "Boolean parameter values use true and false. String parameter values must be enclosed in double-quotes."
      ],
      "SourcePath": "E:\\1\\Win.iso",
      "WindowsApps": "All",
      "SystemApps": true,
      "Capabilities": true,
      "Packages": true,
      "Features": true,
      "DeveloperMode": false,
      "WindowsStore": false,
      "MicrosoftEdge": false,
      "Win32Calc": true,
      "Dedup": false,
      "DaRT": [
      ],
      "Registry": true,
      "Additional": {
        "Setup": false,
        "Wallpaper": false,
        "SystemLogo": false,
        "LockScreen": false,
        "RegistryTemplates": false,
        "LayoutModification": false,
        "Unattend": false,
        "Drivers": false,
        "NetFx3": false
      },
      "ComponentCleanup": false,
      "ISO": "No-Prompt"
    }
    
     
  13. strotee

    strotee MDL Member

    Joined:
    Jan 30, 2011
    Messages:
    120
    Likes Received:
    124
    Trophy Points:
    10
    mount the ISO, then run
    Code:
    dism /Get-WimInfo /WimFile:x:\sources\install.wim /index:1
    at admin CMD (x=mounted drive) and report what you see.
     
  14. KedarWolf

    KedarWolf MDL Addicted

    Joined:
    Mar 17, 2016
    Messages:
    533
    Likes Received:
    415
    Trophy Points:
    30
    #835 KedarWolf, Jul 2, 2021
    Last edited: Jul 2, 2021
    (OP)
    https://forums.mydigitallife.net/th...-20h1-and-ltsc-2019.80038/page-8#post-1569377

    Code:
    Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass
    Run that before you run the script.
     
  15. Mavericks Choice

    Mavericks Choice MDL Expert

    Joined:
    Aug 5, 2015
    Messages:
    1,832
    Likes Received:
    7,023
    Trophy Points:
    60
    Try calling the script like this it will pause & show any errors.

     
  16. zalim581

    zalim581 MDL Novice

    Joined:
    Aug 12, 2019
    Messages:
    28
    Likes Received:
    6
    Trophy Points:
    0
    I just tried with an english ISO. Same error.
     
  17. zalim581

    zalim581 MDL Novice

    Joined:
    Aug 12, 2019
    Messages:
    28
    Likes Received:
    6
    Trophy Points:
    0
    Powershell accepts unix like paths so type in
    Code:
    ./Start-Optimize.ps1
    not
    Code:
    Start-Optimize.ps1
     
  18. zalim581

    zalim581 MDL Novice

    Joined:
    Aug 12, 2019
    Messages:
    28
    Likes Received:
    6
    Trophy Points:
    0
    I changed my Windows' language to en-us and finally it worked fine.