WindowsUpdateが終わらないときの対応 (備忘録)

PowerShell

バッチファイルを作成して「管理者として実行」

「WindowsUpdateのキャッシュフォルダを削除」と「Bitsキューを削除」

windows-update.bat

echo 自動更新サービスと BITS サービスの停止
net stop usosvc
net stop dosvc
net stop wuauserv
net stop bits

echo SoftwareDistribution フォルダーのリネーム
ren %SystemRoot%\SoftwareDistribution SoftwareDistribution.old
ren %systemroot%\System32\catroot2 catroot2.old

rem BITS のジョブを削除
rem del %AllUsersProfile%\Microsoft\Network\Downloader\qmgr0.dat
rem del %AllUsersProfile%\Microsoft\Network\Downloader\qmgr1.dat
del /q %AllUsersProfile%\Microsoft\Network\Downloader\*

echo 自動更新サービスと BITS サービスの開始
net start bits
net start wuauserv
net start dosvc
net start usosvc

手動でインストールも可能

「KB〜〜〜」で検索してダブルクリックしてインストールする

https://qiita.com/embed-contents/link-card#qiita-embed-content__ffed073bb0ab50d87bd57b4851756e08
https://qiita.com/embed-contents/link-card#qiita-embed-content__5f749e3f2401f3eafa215c7d8339911e

Windows Update に関する参考サイト

https://qiita.com/embed-contents/link-card#qiita-embed-content__501e49deb68628aff282ff664c0f85a5
https://qiita.com/embed-contents/link-card#qiita-embed-content__a33412531d6d6443faa951d9ce234c4e
https://qiita.com/embed-contents/link-card#qiita-embed-content__8432b4da748fada407e12019aed58236
https://qiita.com/embed-contents/link-card#qiita-embed-content__a9625824e0d8f78294d5cb926a19b2cf
https://qiita.com/embed-contents/link-card#qiita-embed-content__7468b82e2d1b7560b1a974150005d3fc

コメント