Home  >  Article  >  How to manually install Windows 10/11 updates using PowerShell

How to manually install Windows 10/11 updates using PowerShell

王林
王林forward
2023-04-23 17:13:072621browse

When any patch is released or any feature is introduced, it is important to update the system frequently. If we don't do this, then we miss out on critical bug fixes, weak security, software incompatibilities, and more. The system might just be acting strange, or the program might simply crash. Normally, we update the system by browsing settings and update and security and then check if there are any updates available. How else can you update if you can't access settings or update and security options? Probably few of us have this problem but the solution is simple and can also be done using PowerShell commands. In this article, let us learn how to update Windows 10 system manually using PowerShell commands.

Using PowerShell Commands to Update Windows 10

Windows gets updates from the Microsoft Update Server and checks our systems against it. To continue the installation and update process, we used a module called PSWindowsUpdate, which is a third-party module available in PowerShell.

Step 1: Open PowerShell in administrator mode by typing PowerShell in the search bar and pressing Enter. Right-click PowerShell and click Run as administrator. A pop-up window will open asking for confirmation, click Yes.

如何使用 PowerShell 手动更新 Windows 10/11

Step 2: Copy the following command and paste it into the PowerShell window. Click to enter and wait a few seconds. It asks for confirmation of executing the policy, enter y for yes, then press enter. This command enables scripts that are allowed to run on your computer, basically it checks the trust policy.

设置执行策略远程签名

如何使用 PowerShell 手动更新 Windows 10/11

Step 3: The next step is to install the module or package. The following command installs the PSWindowsUpdate module required for Windows Update on your system. Copy and paste the command into PowerShell and press enter. It will take a few minutes for execution to begin, so please be patient. Once execution starts, it will ask for confirmation, enter y and press enter.

安装模块 PSWindowsUpdate

如何使用 PowerShell 手动更新 Windows 10/11

Step 4: The module is installed, now import the module into the current PowerShell session and use it to manage Windows Updates. Copy the following command, paste it into PowerShell, and press Enter.

导入模块 PSWindowsUpdate

如何使用 PowerShell 手动更新 Windows 10/11

Step 5: Now that the module is installed and imported, you can check the number of updates available on your computer before installing. The get command below checks for updates against the Microsoft update server and lists all updates that are available for your system. It also includes the KB (Knowledge Base) ID in the output, which may be needed later during the installation of updates. Copy the following command, paste it into PowerShell, and press Enter.

获取-WindowsUpdate

如何使用 PowerShell 手动更新 Windows 10/11

Note: You can also install only the specific updates you need and ignore the rest. This can be accomplished by executing the following command before step 6. It requires mentioning the KB (Knowledge Base) ID, so updates based on that specific ID will be ignored. Here, I only have 1 KB ID to update, so I'll go ahead with it and skip this command.

隐藏-WindowsUpdate- KBArticleID KB1234567

Step 6: To install all updates, please copypaste the following command into PowerShell, Then press Enter. It asks for confirmation, enter A for Yes to All, then press enter. This will install all updates listed above in the get command. You can also view the installation status at the top of the PowerShell window that appears in green.

安装-WindowsUpdate

如何使用 PowerShell 手动更新 Windows 10/11

After the execution is completed and the update is successfully installed, the output is as shown below. Your system is now up to date.

如何使用 PowerShell 手动更新 Windows 10/11您还可以下载此 PC 修复工具以查找并修复任何 PC 问题:
第 1 步 -从此处下载 Restoro PC 修复工具
第 2 步- 单击开始扫描以自动查找并修复任何 PC 问题。

就是这样!是不是很简单,希望这篇文章对你有用,让你了解手动更新的过程。

The above is the detailed content of How to manually install Windows 10/11 updates using PowerShell. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:yundongfang.com. If there is any infringement, please contact admin@php.cn delete