• Managing and Maintaining a Windows OS Image

    Home » Forums » Tools » Managing and Maintaining a Windows OS Image

    Author
    Topic
    #95932

    Managing and Maintaining a Windows OS Image

    Install and Configure PowerShell and PowerShell ISE via the WMF

    System Update Readiness Tool for Windows 7

    One thing I can suggest is find the System Update Readiness Tool for Windows 7 (KB947821) [October 2014]
    https://www.microsoft.com/en-ca/download/details.aspx?id=3132

    One thing I can suggest is find the System Update Readiness Tool for Windows 7 for x64-based Systems (KB947821) [October 2014]
    https://www.microsoft.com/en-ca/download/details.aspx?id=20858

    I am not sure if this is the Latest one but it is the Latest I could find, you may have to check further at your time of access.

    It is the equivalent of: “DISM /Online /Cleanup-Image /ScanHealth” {rather than /RestoreHealth} Run in PS as Admin in W 8 and later(I don’t know if they have migrated DISM back to W 7 now that PS is READILY available for W 7)

    Check further with the experts that we have available to us here such as the MVPs.

    Windows 8.x or higher:

    Are you doing SFC, DISM /RestoreHealth and Disk Cleanup ‘%windir%\system32\cleanmgr.exe’ on your current Image? One should be between every attempt!!!

    Restart First!!!

    There is also an ‘In Board’ Module: DISM that one can do this in Powershell ISE with camlet: “Repair-WindowsImage ‘Online’ tab.

    This is My Script that I run in POWERSHELL elevated to Admin Rights.

    ReagentC /Info
    sfc /scannow
    DISM /Online /Cleanup-Image /RestoreHealth
    DISM /Online /Cleanup-Image /AnalyzeComponentStore
    DISM /Online /Cleanup-Image /StartComponentCleanup
    DISM /Online /Cleanup-Image /AnalyzeComponentStore

    DISM /Online /Cleanup-Image /RestoreHealth /source:ESD:”C:\RecoveryImage\install.esd:1” /LimitAccess

    The Above one assumes you have this: C:\@Windows RE Install”\install.esd OR C:\RecoveryImage\install.esd already, If not, copy it from your Mounted ISO>>Sources>>install.esd FOR YOUR CURRENT IMAGE ONLY If yourS is a ‘.wim’ change all ESD to WIM, either is OK.

    OR

    DISM /Online /Cleanup-Image /RestoreHealth /source:ESD:”C:\RecoveryImage\install.esd:1″ /LimitAccess

    OR

    DISM /Online /Cleanup-Image /RestoreHealth /source:ESD:”C:\RecoveryImage\install.esd:4″ /LimitAccess

    Once that is clean, then I run, Disk Cleanup again: ‘%windir%\system32\cleanmgr.exe’

    I do the above consistently and before any Update/Upgrade and after.

    The Above one assumes you have this: C:\@Windows RE Install”\install.esd OR C:\RecoveryImage\install.esd already, If not, copy it Originally from your $Windows~BT>>Sources>>install.esd FOR YOUR CURRENT IMAGE ONLY

    When W 8 came out Microsoft directed that this Directory be used: “@Windows RE Install”
    When W 10 came out Microsoft changed it to this Directory to be used: “RecoveryImage”

    Then set up your BOOT Paths for Windows Recovery System:

    ReagentC /Info

    REAGENTC /setosimage /path “C:\@Windows RE Install” /index 1 /target C:\Windows
    ReagentC /Info

    OR

    REAGENTC /setosimage /path “C:\RecoveryImage” /index 1 /target C:\Windows
    ReagentC /Info

    OR

    REAGENTC /setosimage /path “C:\RecoveryImage” /index 4 /target C:\Windows
    ReagentC /Info

    As far as “Deferred Upgrades” are concerned, there maybe a check box in Settings>Wu>Advanced OR in GPO in “C:\Windows\System32\en-US\gpedit.msc” under “Administrative Templates>>Windows Components” I believe. It has been awhile so you would have to search if you want to use the GPO method. (W 10 ONLY, so far)

    I personally use the Registry method, on W 10, W 8.x. and W 7 too. On W 10 it looks like my Image is managed. It is, by me personally(not by WSUS or SCCM) and WU is locked down.
    The question how MUCH are you ready for Registry Editing? One can do some very real and permanent damage if you make a mistake in there!!! (That is where Registry Backups and Image Backups, setup so one can Boot in to the PC on Windows PE(Preliminary Environment).

    Registry Adjustments for ALL, W 7, W 8.1 and W 10/

    If you are I recommend NIRSoft “Registry Scanner”:

    Sofer or NirSoft has, and continues to develop, an excellent selection of free utilities…

    Like AskWoody, NirSoft is a one-person operation, so if you like and use Nir’s tools, a small donation would be appreciated.

    https://www.askwoody.com/forums/topic/nirsoft-utilities/

    See my Post Here:

    WSCC | Windows System Control Center
    https://www.askwoody.com/forums/topic/wscc-windows-system-control-center/

    This is an Ideal companion to keeping your NIRSoft Utility Tools, up to date as well as New Tools that are released.

    All Windows OS can use this if you Have OR Potentially have Windows Update DataBase Corruption:

    Perhaps some Troubleshooting or Deep Cleanup is in order?

    We have to assume you have done all of the usual Troubleshooting Disk Cleanup ‘%windir%\system32\cleanmgr.exe’ all ready….

    Latest Windows Update Troubleshooter | latestwu.diagcab for W 10.0 {W 10 Fname but W 8 & W 7 are there too)

    Latest Windows Update Troubleshooter | latestwu.diagcab for Windows
    https://support.microsoft.com/en-us/instantanswers/512a5183-ffab-40c5-8a68-021e32467565/windows-update-troubleshooter

    Deep Cleanup:

    Resolve Windows Update/Upgrade errors that may have/Did cause Windows Update DataBase Corruption
    For Deep Cleaning Up of WU Corruption Issues:

    Open a CMD Prompt with Administator Rights and C&P the script into it.
    NOTE: As much as I like PS, in this case I have had better success with CMD Line.

    This is the script I use to correct the WU DB corruption issues and will work on W 7 to W 10.0:

    net stop wuauserv
    net stop cryptSvc
    net stop bits
    net stop msiserver
    ren “C:\Windows\SoftwareDistribution” “SoftwareDistribution old”
    ren “C:\Windows\System32\catroot2” “Catroot2 old”
    net start wuauserv
    net start cryptSvc
    net start bits
    net start msiserver

    If you have run this before don’t forget to delete: “SoftwareDistribution old” and “Catroot2 old”.
    The system will recreate those directories when WU is restarted. It is always a good idea to restart the PC as well Before and After.

    NOTE:One will also lose all update history on the PC in the WU GUI.
    Note:How ever using “PSWindowsUpdate” “Get-WUList with ‘Installed’ box Checked, will over come this problem.

    How do I reset Windows Update components?

    Powershell ISE Module: Installing PSWindowsUpdate, Script: Provisioning Get-PendReboot

    I have found better success doing this with the script method rather that the Downloadable TroubleShooter, which doesn’t mead you should not use the Troubleshooter. You Should DO Both!
    Keep in mind this ‘Might’ be an MS Server/distribution problem but Which has been occurring more and more lately, it is hard to say?

    --------------------------------------

    1. Tower Totals: 2xSSD ~512GB, 2xHHD 20 TB, Memory 32GB

    SSDs: 6xOS Partitions, 2xW8.1 Main & Test, 2x10.0 Test, Pro, x64

    CPU i7 2600 K, SandyBridge/CougarPoint, 4 cores, 8 Threads, 3.4 GHz
    Graphics Radeon RX 580, RX 580 ONLY Over Clocked
    More perishable

    2xMonitors Asus DVI, Sony 55" UHD TV HDMI

    1. NUC 5i7 2cores, 4 Thread, Memory 8GB, 3.1 GHz, M2SSD 140GB
    1xOS W8.1 Pro, NAS Dependent, Same Sony above.

    -----------------

    2 users thanked author for this post.
    Reply To: Managing and Maintaining a Windows OS Image

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: