Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] win_wusa.uninstall does not work, /quiet /kb combined no longer supported #62366

Closed
amalaguti opened this issue Jul 22, 2022 · 3 comments · Fixed by #62615
Closed

[BUG] win_wusa.uninstall does not work, /quiet /kb combined no longer supported #62366

amalaguti opened this issue Jul 22, 2022 · 3 comments · Fixed by #62615
Assignees
Labels
Bug broken, incorrect, or confusing behavior Execution-Module Sulfur v3006.0 release code name and version Windows

Comments

@amalaguti
Copy link

Description
wusa.exe /quiet /kb combined no longer supported
https://stackoverflow.com/questions/43822296/unable-to-uninstall-patch-using-wusa-exe-using-quiet-switch#49287650
https://serverfault.com/questions/111525/how-do-to-uninstall-windows-updates-from-a-prompt-or-ps-in-hyper-v-server/869076#869076

More like a Windows issue, but to report this is no longer working.

Suggestion is to use something like this

$SearchUpdates = dism /online /get-packages | findstr "Package_for"
$updates = $SearchUpdates.replace("Package Identity : ", "") | findstr "KBXXXXXX"
#$updates
DISM.exe /Online /Remove-Package /PackageName:$updates /quiet /norestart

Setup
Windows minions

Steps to Reproduce the behavior
use wusa.uninstall to remove a kb
The command called by the function does not work.

Expected behavior
Get the kb removed

Screenshots
If applicable, add screenshots to help explain your problem.

Versions Report

salt --versions-report (Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)
PASTE HERE

Additional context
Add any other context about the problem here.

@amalaguti amalaguti added Bug broken, incorrect, or confusing behavior needs-triage labels Jul 22, 2022
@twangboy twangboy self-assigned this Jul 22, 2022
@twangboy twangboy added this to the Sulphur v3006.0 milestone Jul 22, 2022
@twangboy
Copy link
Contributor

@amalaguti Thanks for reporting this. I've scheduled it for our Sulfur release.

@s0undt3ch s0undt3ch added Sulfur v3006.0 release code name and version and removed Sulfur v3006.0 labels Aug 5, 2022
@twangboy
Copy link
Contributor

twangboy commented Sep 2, 2022

Hey @amalaguti

The above PR makes it easier to uninstall a KB using the win_dism execution/state module. It allows you to just pass the KB number without having to know the actual package name in DISM. I chose to make the changes there as that is where we are working with DISM.

@amalaguti
Copy link
Author

Thanks @twangboy !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior Execution-Module Sulfur v3006.0 release code name and version Windows
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants