adds OfficeStaging and SystemTemp
This commit is contained in:
+24
-3
@@ -120,10 +120,11 @@ selections, and mixtures of presets with other values also fail before cleanup.
|
||||
| Variable | Default | Purpose |
|
||||
| --- | --- | --- |
|
||||
| `CleanupReportOnly` | true | Assess all categories versus apply enabled categories only |
|
||||
| `CleanupTempDays` | 7 | Temp files, installers, browser cache, Apple downloads |
|
||||
| `CleanupTempDays` | 7 | Temp files, installers, abandoned Office staging, browser cache, Apple downloads |
|
||||
| `CleanupDiagnosticDays` | 30 | CBS, WER archives, dumps, Revit journals |
|
||||
| `CleanupBackupDays` | 30 | Downloads, backups, time spent in Recycle Bin |
|
||||
| `CleanupSystemTemp` | true | Windows Temp, including EVTX, misc logs, AppxErrorReport, Chocolatey |
|
||||
| `CleanupSystemTemp` | true | Windows Temp and SystemTemp, including EVTX, misc logs, AppxErrorReport, Chocolatey; excludes Office staging |
|
||||
| `CleanupOfficeStaging` | true | Recognized abandoned Office deployment media, using CleanupTempDays; preserves diagnostics and deferred-user helpers |
|
||||
| `CleanupUserTemp` | true | Registered user profiles' Local Temp; AutoCAD `.ac$` only with AutoCAD closed |
|
||||
| `CleanupServiceTemp` | true | LocalService, NetworkService, SYSTEM profile temp folders |
|
||||
| `CleanupCBSArchives` | true | `CbsPersist_*.log` and `CbsPersist_*.cab` |
|
||||
@@ -218,6 +219,22 @@ termination can leave a temporary slot behind; future runs skip occupied slots.
|
||||
|
||||
## Deletion and operational boundaries
|
||||
|
||||
- `OfficeStaging` checks the execution account's temp directory, Windows Temp and
|
||||
SystemTemp, registered user/service profile temp directories, and legacy
|
||||
ProgramData, under `EmberkomOfficeDeployment`. It runs on clients and servers.
|
||||
The deployment mutex must be available, process inventory must succeed, and no
|
||||
recognized installer may be running. Each workspace must have a GUID name and a
|
||||
bounded, recognizable `options.json`; its directory, identity and every payload
|
||||
artifact must be older than `CleanupTempDays`. Recent, linked, locked, unrecognized
|
||||
or process-referenced workspaces are retained, including in report-only estimates.
|
||||
- Office cleanup deletes only named payload artifacts (ODT, companion installers,
|
||||
old GetHelp downloads and cache manifests). It preserves logs, options, XML,
|
||||
helper scripts, locks, task markers, unknown files and the workspace itself.
|
||||
Generic temp scans exclude this subtree, so they cannot bypass the dedicated
|
||||
option, retention or active-deployment checks. Report-only lists eligible media
|
||||
even when `CleanupOfficeStaging=false`; apply skips that disabled category.
|
||||
Process and mutex skips remain visible in the compact report; per-folder
|
||||
retention reasons are available through verbose output.
|
||||
- Inspect each file's modification time; an old parent never authorizes deletion
|
||||
of newer children. Ordinary cache/temp directories are retained.
|
||||
- Use literal local paths, verify containment, and skip reparse points and linked
|
||||
@@ -262,13 +279,17 @@ Coverage includes disabled-category estimates, separate report groups, unique
|
||||
totals for overlapping categories, and disabled categories remaining untouched in
|
||||
apply mode. Preset tests verify exact handler membership, cumulative selections,
|
||||
RMM scope preservation, None disabling native work, and the server exclusions.
|
||||
Output tests cover the duplicate-object regression, a 22-category preview under
|
||||
Output tests cover the duplicate-object regression, a 23-category preview under
|
||||
4 KiB including diagnostics, separate enabled/disabled sections, and preservation
|
||||
of diagnostic notes. Regression checks ensure DISM analysis is absent and report
|
||||
diagnostics launch no native programs.
|
||||
Hibernation/VSS tests cover usage in category MiB columns, zero for absence,
|
||||
unknown sizes after access failures, cross-drive storage, server exclusions, no
|
||||
duplicate diagnostic lines, and usage staying out of savings totals.
|
||||
Office staging tests cover Windows SystemTemp and legacy ProgramData, complete
|
||||
artifact selection, identity/age/link/lock/process guards, deployment mutex
|
||||
contention, disabled categories, server support, generic-temp exclusion, and
|
||||
preservation of diagnostics and deferred-user files.
|
||||
|
||||
References: [OS ProductType](https://learn.microsoft.com/en-us/windows/win32/cimwin32prov/win32-operatingsystem),
|
||||
[Disk Cleanup](https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/cleanmgr),
|
||||
|
||||
Reference in New Issue
Block a user