Files
management-scripts/Cleanup-SystemLogFiles.ps1
T
2020-09-07 20:18:06 -04:00

2 lines
252 B
PowerShell

## This script will delete runaway CBS logs that can take up 100's of GB on an endpoint
Get-ChildItem -Path "${Env:WINDIR}\Logs\CBS" -File | Where { ( $_.Name -like "CbsPersist_*.log" ) -or ( $_.Name -like "CbsPersist_*.cab" ) } | Remove-Item -Force