_________________________________________________________________________________________________
1. Generate a Report for installed Hotfix-Update-ServicePack for Bulk Servers.
Please send me a mail at <bshwjt@gmail.com> . If you are getting any issue with this Script.
HotfixReport.zip - You will get two files in "HotfixReport.zip". See the help file for additonal information.
Run that Script. You will get a report(txt) for installed Hotfix for bulk Computers and get an additional output(txt) for unreachable computers.
$computers = Get-Content "c:\scripts\dclist.txt" $Patch = "KB3144756" foreach ($computer in $computers) { if (get-hotfix -id $Patch -ComputerName $computer -ErrorAction SilentlyContinue) { Add-content "KB3144756 is Present in $computer" -path "$env:USERPROFILE\Desktop\Hotfix-Present.log" } Else { Add-content "KB3144756 is not Present in $computer" -path "$env:USERPROFILE\Desktop\Missing-Hotfix.log" } }
$computers = Get-Content "c:\scripts\dclist.txt" $Patch = "KB3144756" foreach ($computer in $computers) { if (get-hotfix -id $Patch -ComputerName $computer -ErrorAction SilentlyContinue) { Add-content "KB3144756 is Present in $computer" -path "$env:USERPROFILE\Desktop\Hotfix-Present.log" } Else { Add-content "KB3144756 is not Present in $computer" -path "$env:USERPROFILE\Desktop\Missing-Hotfix.log" } }
###------------------------------### ### Author : Biswajit Biswas-----### ###--MCC, MCSA, MCTS, CCNA, SME--### ###Email<bshwjt@gmail.com>-------### ###------------------------------### ###/////////..........\\\\\\\\\\\### ###///////////.....\\\\\\\\\\\\\\### function Hotfixreport { $computers = Get-Content C:\computers.txt $ErrorActionPreference = 'Stop' ForEach ($computer in $computers) { try { Get-HotFix -cn $computer | Select-Object PSComputerName,HotFixID,InstalledOn,InstalledBy -last 3 | FT -AutoSize } catch { Add-content $computer -path "$env:USERPROFILE\Desktop\Notreachable_Servers.txt" } } } Hotfixreport > "$env:USERPROFILE\Desktop\Hotfixreport.txt"
###------------------------------### ### Author : Biswajit Biswas-----### ###--MCC, MCSA, MCTS, CCNA, SME--### ###Email<bshwjt@gmail.com>-------### ###------------------------------### ###/////////..........\\\\\\\\\\\### ###///////////.....\\\\\\\\\\\\\\### function Hotfixreport { $computers = Get-Content C:\computers.txt $ErrorActionPreference = 'Stop' ForEach ($computer in $computers) { try { Get-HotFix -cn $computer | Select-Object PSComputerName,HotFixID,InstalledOn,InstalledBy -last 3 | FT -AutoSize } catch { Add-content $computer -path "$env:USERPROFILE\Desktop\Notreachable_Servers.txt" } } } Hotfixreport > "$env:USERPROFILE\Desktop\Hotfixreport.txt"
Note: Posts are provided “AS IS” without warranty of any kind, either expressed or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose.