New
#41
OK, so I got impatient and thought I'd have another go. This time I managed to remove C:\ProgramData\Microsoft\Windows\Containers without killing my system. Well, the Start menu works, my VMs still run and I'm posting this from that machine. This may be overkill, but these were the steps I took...
Uninstalled 'Windows Defender Application Guard' in 'Turn Windows features on or off' and restarted.
Used Advanced start-up in Settings > Update & Security > Recovery to boot to a Command Prompt. CD into C:\ProgramData\Microsoft\Windows then used the commandrmdir /s containers
This removed most but not all files. There were a number of reports that 'The system cannot find the path specified', all in subfolders of the BaseImages folder.
Code:containers\BASEIM~1\84C610~1\Files\Users\WDAGUtilityAccount\AppData\Local\Packages\Microsoft.Windows.Cortana_cw5n1h2txyewy\AC\AppCache\2TZYVOBF\1\C__Windows_SystemApps_Microsoft.Windows.Cortana_cw5n1h2txyewy_cache_Desktop_10[1].txt - The system cannot find the path specified. ... containers\BASEIM~1\84C610~1\Files\Windows\System32\CatRoot\{F750E6C3-38EE-11D1-85E5-00C04FC295EE}\Microsoft-Windows-Security-SPP-Component-SKU-ProfessionalSingleLanguage-License-Package~31bf3856ad364e35~amd64~~10.0.17763.1.cat - The system cannot find the path specified.
Restarted and checked the size of Containers, it was now down to 260MB.
In Regedit, deleted the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Containers (after checking that it didn't exist on the machine that had never had Application Guard) then restarted.
In Advanced Security took ownership of Containers, granting myself Full Control at the same time, and ticking the boxes for 'Replace owner on subcontainers and objects' and 'Replace all child object permissions with inheritable permission entries from this object'.
Used File Manager to delete C:\ProgramData\Microsoft\Windows\Containers. It reported that some file paths were too long to go into the Recycle bin, did I want to permanently delete them? (This may also explain the rmdir errors earlier).
So far, everything seems to be working normally. Even SFC thinks the system is healthy.
Postscript:
Still working
I have now made a new Macrium image of this 'slimmed down' system. Mounting it and the image I restored to start this process, I see that my C: drive has now gained 4.7GB extra free space.
Last edited by Bree; 17 May 2019 at 20:33. Reason: Postscript
Thanks. After the first attempt which went wrong it seemed the obvious next step. Deleting the registry key may well have been crucial too.
As I said, I probably took more precautions than were strictly necessary, but as it worked I'm not inclined to restore the original image and try to refine the process