Reverse Cyberdrain script to block Windows 11 upgrade

I applied the cyberdrain script to block Windows update showing Windows 11.
To remove this from some computers can I simply replace “reg add” on the two lines of the script with “reg delete”?
Thanks in anticipation for what i guess is a really simple question for a lot of you!

A little more modification than that, but yes. Here are the two you need and some others I’ve been using:

# Undo Set Windows to not upgrade past 21H2 (prevent Windows 11 auto-upgrade)
reg delete HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /f /v TargetReleaseVersion
reg delete HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /f /v TargetReleaseVersionInfo
# Undo Other possible prevention
reg delete HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /f /v DisableOSUpgrade
reg delete HKLM\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate /f /v ProductVersion
reg delete HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\OSUpgrade /f /v AllowOSUpgrade
reg delete HKLM\SOFTWARE\Policies\Microsoft\WindowsStore /f /v DisableOSUpgrade
reg delete HKLM\SYSTEM\Setup\UpgradeNotification /f /v UpgradeAvailable
# Undo Prevent Windows PC Health Check install
reg delete HKLM\SOFTWARE\Microsoft\PCHC /f /v PreviousUninstall
1 Like

Hi Isaac
Many thanks for this.
I really should learn more about scripting, powershell etc.
Any recommendations on good places/books to learn?
Thanks, Andy

I’ve just learned haphazardly by creating my own or modifying existing ones to do what I want and a lot of googling. And I’m old enough to have started with DOS :smiley: I’ve seen people recommend PowerShell in a Month of Lunches lots of times.

Ha! I’m old enough for DOS too!!

Thanks for recommendation. Cheers!

1 Like