none
Windows Update get full KB file name RRS feed

  • Question

  • I have a script which check some specific KB on server:

        if (!(Get-HotFix -Id 'KB4509095' -ErrorAction Ignore ))  
            {
            Write-Host 'KB4509095 not found'
            $kbFileName = (Join-Path $env:temp "windows10.0-kb4509095-x64_db55fad56f519812591f059826f4938733ec66da.msu")
            Invoke-WebRequest -Uri 'http://download.windowsupdate.com/d/msdownload/update/software/secu/2019/07/windows10.0-kb4509095-x64_db55fad56f519812591f059826f4938733ec66da.msu' -OutFile $kbFileName
            Start-Process -FilePath "wusa.exe" -NoNewWindow -ArgumentList $kbFileName -Wait
            Write-Host 'KB4509095 was installed'
            Remove-Item -Path $kbFileName
            }

    I was able to get a full KB http file path before from Microsoft Update before. Now it looks like I can only download file manually. How can I get full http address for a particular KB number?

    Thank you,

    Dmitriy 

    Monday, August 12, 2019 6:12 PM

Answers