Microsoft Resize_script.ps1 KB5034441 with 0x80070643 Error


  1. Posts : 4
    Windows 10 Professional
       #1

    Microsoft Resize_script.ps1 KB5034441 with 0x80070643 Error


    Hi! Everybody

    I successfully found a Microsoft script to fix this update, from a Microsoft web page. The problem is when I tried to run it, it says that execution of scripts are not allowed, because the execution policy is disable. Now, I need clear layman words to the steps on how to temporary enable execution policy temporary to run the script? I found a command that a page said enable temporary execution policy, and is in the screenshot below. I took some screenshots to prove the errors. It will be nice if someone makes a tutorial to run this script from Microsoft and make it a sticky on the forum. Thanks for your time and help.

    My PC details are:

    Edition Windows 10 Pro
    Version 22H2
    Installed on ‎6/‎2/‎2021
    OS build 19045.4170
    Experience Windows Feature Experience Pack 1000.19054.1000.0

    Microsoft Resize_script.ps1 KB5034441 with 0x80070643 Error-windows-10-pro-admin-powershell-errors.png
      My Computer


  2. Posts : 789
    Windows 7
       #2

    Run this command as Administrator:
    Code:
    powershell -NoProfile -ExecutionPolicy Bypass -f \path\to\Resize_script.ps1 -SkipConfirmation $true -BackupFolder C:\winre_backup

    You don't need to permanently change the current Execution Policy for PS scripts, if you're only running scripts once in a while and prefer the default extra security measures.
      My Computer


  3. Posts : 4
    Windows 10 Professional
    Thread Starter
       #3

    garlin said:
    Run this command as Administrator:
    Code:
    powershell -NoProfile -ExecutionPolicy Bypass -f \path\to\Resize_script.ps1 -SkipConfirmation $true -BackupFolder C:\winre_backup

    You don't need to permanently change the current Execution Policy for PS scripts, if you're only running scripts once in a while and prefer the default extra security measures.
    Hi! Garlin

    That command gave me and error. Any other ideas? I wish Microsoft$ windows will test updates more and release a script if you get problems on the update, but that is a wish. See bellow for screenshot of the error. Thanks for your time and help.
    Microsoft Resize_script.ps1 KB5034441 with 0x80070643 Error-new-command-ten-forums-powershell.png
      My Computer


  4. Posts : 789
    Windows 7
       #4

    You're expected to enter that command from CMD, not inside PowerShell itself.
    If you need to do this within PS, change -SkipConfirmation $true" to "-SkipConfirmation 1"
      My Computer


  5. Posts : 4
    Windows 10 Professional
    Thread Starter
       #5

    garlin said:
    You're expected to enter that command from CMD, not inside PowerShell itself.
    If you need to do this within PS, change -SkipConfirmation $true" to "-SkipConfirmation 1"
    Hi! Garlin

    Nope, still gives me an error. Any other ideas? See screenshot below, please. Thanks for your time and help.
    Microsoft Resize_script.ps1 KB5034441 with 0x80070643 Error-windows-script-within-cmd.png
      My Computer


  6. Posts : 789
    Windows 7
       #6

    1. Try recopying the original MS script.

    2. If I truncate the script to only keep the parameters part, it still works for me.

    RESIZE.ps1
    Code:
    Param (
    [Parameter(Mandatory=$false,HelpMessage="Skip confirmation")][bool]$SkipConfirmation=$false,
    [Parameter(Mandatory=$true,HelpMessage="Path to backup old WinRE partition content to")][string]$BackupFolder
    )
    exit
    Code:
    PS C:\Users\GARLIN\Downloads> .\RESIZE.ps1 -SkipConfirmation 1 -BackupFolder C:\BACKUP
    
    PS C:\Users\GARLIN\Downloads> .\RESIZE.ps1 -SkipConfirmation ABC -BackupFolder C:\BACKUP
    C:\Users\GARLIN\Downloads\RESIZE.ps1 : Cannot process argument transformation on parameter 'SkipConfirmation'. Cannot convert value "System.String" to type "System.Boolean". Boolean parameters accept only Boolean values and numbers, such as $True, $False, 1 or 0.
    At line:1 char:32
    + .\RESIZE.ps1 -SkipConfirmation ABC -BackupFolder C:\BACKUP
    +                                ~~~
        + CategoryInfo          : InvalidData: (:) [RESIZE.ps1], ParameterBindingArgumentTransformationException
        + FullyQualifiedErrorId : ParameterArgumentTransformationError,RESIZE.ps1
    
    
    PS C:\Users\GARLIN\Downloads> .\RESIZE.ps1 -SkipConfirmation true -BackupFolder C:\BACKUP
    C:\Users\GARLIN\Downloads\RESIZE.ps1 : Cannot process argument transformation on parameter 'SkipConfirmation'. Cannot convert value "System.String" to type "System.Boolean". Boolean parameters accept only Boolean values and numbers, such as $True, $False, 1 or 0.
    At line:1 char:32
    + .\RESIZE.ps1 -SkipConfirmation true -BackupFolder C:\BACKUP
    +                                ~~~~
        + CategoryInfo          : InvalidData: (:) [RESIZE.ps1], ParameterBindingArgumentTransformationException
        + FullyQualifiedErrorId : ParameterArgumentTransformationError,RESIZE.ps1
     
    
    PS C:\Users\GARLIN\Downloads> .\RESIZE.ps1 -SkipConfirmation $true -BackupFolder C:\BACKUP
      My Computer


  7. Posts : 112
    Windows 10
       #7

    I have only run one PS script in my life (different from yours), and it was successful. I knew beforehand that PS wouldn't run scripts by default for security reasons, and I found a different solution to run it w/o changing the security policy. I put here the relevant part:

    1) Open "Windows PowerShell ISE" from the Start menu as Admin. I also have a "Windows Powerhell ISE (x86)" that I didn't use, although this should depend on if you have the 64 or 32 bits Windows version.

    2) Run "Get-ExecutionPolicy -List". All scopes are "Undefined". I've read that the default is not letting PS run scripts for security reasons.

    3) Run "Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope Process" and "Get-ExecutionPolicy -List". Now the Scope "Process" is "Bypass". This means no/minimum checks during this PowerShell session.

    4) Run "cd C:\Users\Maverick2\Downloads", if you've put your script there.

    5) Run your script. In my case the exact command was, character by character except the quotes ".\PatchWinREScript_2004plus.ps1 -packagePath .\windows10.0-kb5034232-x64_ff4651e9e031bad04f7fa645dc3dee1fe1435f38.cab". I suggest preceeding your script name and extension with "." as I did. My script did need other file that I had put in the same directory and that I preceeded with "." too (without quotes in all cases). SORRY: I CANNOT PUT THE TWO CHARACTERS SEQUENCE FORMED BY A PERIOD AND A BACKSLASH, SOMETHING IS CHANGING IT TO SIMPLY THE PERIOD, THAT IS NOT TRUE AND THAT IS NOT WHAT I AM WRITING. DUPLICATING THE BACKSLASH DID NOT FIX IT, SORRY, BE AWARE THAT THIS POST HAS AN IMPORTANT DEFECT THAT i DO NOT KNOW HOW TO CORRECT.

    6) Exit PowerShell and do checks.

    Ideally, much of this "dancing" isn't needed if you're specialist in PowerShell, but I'm not.

    The MS directions for enlarging the Recovery partition were 100% correct only in one very usual case (UEFI/GPT and Recovery partition just after C:\), quite but not totally correct if Legacy BIOS/MBR instad of UEFI/GPT (the new "Recovery partition" ends as normal partition for lack of the needed id=27 that was reset to id=07 by the format command), and simply not correct if the Recovery partition isn't just after C:\. I wonder if your script is correct, I suppose it is if your system is UEFI/GPT and has the Recovery partition just after C:\. Imo applying manually the MS directions isn't difficult. I would also recommend an imaging program and doing backups before attempting this as many things can fail. In my case I couldn't install KB5034441 although I succeded precisely with my script to install the "dynamic updates" version. The initial failure wouldn't have been important if the mere attempt hadn't blocked all other updates, but it did. I could recover in minutes (and actually do many attempts with all kinds of strategies, all failed) thanks to my previous image backups.
      My Computer


  8. Posts : 4
    Windows 10 Professional
    Thread Starter
       #8

    Hi! Everybody

    I still have not seen clear steps on how to run the Microsoft$ script to resize the WinRE partition. Does anyone have clear steps to run the script? Thanks for your time and help.
    Last edited by Linuxbeliever; 4 Weeks Ago at 21:19. Reason: Typo
      My Computer


 

  Related Discussions
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

© Designer Media Ltd
All times are GMT -5. The time now is 22:34.
Find Us




Windows 10 Forums