How to Check Installed Windows Updates | Hotfixes on any remote computer using a Powershell command.
When you want to get all the installed hotfixes on your windows machine or a server then we have cmdlet available in Powershell called get-hotfix, here are the examples and usage fo the command.
Get-HotFix parameters
[ID] one can use an ID number to pull the hotfix information.
[ComputerName] we query or get hotfix on remote computers using this parameter.
[-Credential] we can pass remote computer user creadentials.
Get-HotFix Examples
PS C:\Windows\system32> get-hotfix Source Description HotFixID InstalledBy InstalledOn ------ ----------- -------- ----------- ----------- DESKTOP-SV... Update KB4534131 NT AUTHORITY\SYSTEM 2/14/2020 12:00:00 AM DESKTOP-SV... Update KB4465065 NT AUTHORITY\SYSTEM 6/19/2019 12:00:00 AM DESKTOP-SV... Security Update KB4470788 NT AUTHORITY\SYSTEM 1/13/2019 12:00:00 AM DESKTOP-SV... Update KB4480056 NT AUTHORITY\SYSTEM 1/13/2019 12:00:00 AM DESKTOP-SV... Update KB4486153 NT AUTHORITY\SYSTEM 8/29/2019 12:00:00 AM DESKTOP-SV... Security Update KB4493510 NT AUTHORITY\SYSTEM 4/10/2019 12:00:00 AM
Example Check hotfixes using ID
PS C:\Windows\system32> get-hotfix -Id KB4512577 Source Description HotFixID InstalledBy InstalledOn ------ ----------- -------- ----------- ----------- DESKTOP-SV... Security Update KB4512577 NT AUTHORITY\SYSTEM 9/13/2019 12:00:00 AM
Example Check hotfixes using Description.
PS C:\Windows\system32> Get-HotFix -Description Security* Source Description HotFixID InstalledBy InstalledOn ------ ----------- -------- ----------- ----------- DESKTOP-SV... Security Update KB4470788 NT AUTHORITY\SYSTEM 1/13/2019 12:00:00 AM DESKTOP-SV... Security Update KB4493510 NT AUTHORITY\SYSTEM 4/10/2019 12:00:00 AM DESKTOP-SV... Security Update KB4499728 NT AUTHORITY\SYSTEM 5/16/2019 12:00:00 AM DESKTOP-SV... Security Update KB4504369 NT AUTHORITY\SYSTEM 6/12/2019 12:00:00 AM DESKTOP-SV... Security Update KB4509095 NT AUTHORITY\SYSTEM 7/10/2019 12:00:00 AM DESKTOP-SV... Security Update KB4512577 NT AUTHORITY\SYSTEM 9/13/2019 12:00:00 AM DESKTOP-SV... Security Update KB4512937 NT AUTHORITY\SYSTEM 8/20/2019 12:00:00 AM DESKTOP-SV... Security Update KB4516115 NT AUTHORITY\SYSTEM 9/13/2019 12:00:00 AM
Get-Hotfix on the remote computer
This Powershell command also get all the installed hotfixes on the remote computer and gives, installed date and user name, please see the below example.
PS C:\Windows\system32> Get-HotFix -ComputerName DESKTOP-SV9FF3Q Source Description HotFixID InstalledBy InstalledOn ------ ----------- -------- ----------- ----------- DESKTOP-SV... Update KB4534131 NT AUTHORITY\SYSTEM 2/14/2020 12:00:00 AM DESKTOP-SV... Update KB4465065 NT AUTHORITY\SYSTEM 6/19/2019 12:00:00 AM DESKTOP-SV... Security Update KB4470788 NT AUTHORITY\SYSTEM 1/13/2019 12:00:00 AM DESKTOP-SV... Update KB4480056 NT AUTHORITY\SYSTEM 1/13/2019 12:00:00 AM DESKTOP-SV... Update KB4486153 NT AUTHORITY\SYSTEM 8/29/2019 12:00:00 AM
Thank you for reading this article, if you have any questions please let us know.
Thank you for visiting my site, for any scripts in these articles you are testing please make sure you have tested this script in our lower environment before you run in production.
Leave a Reply Cancel reply