Loading your shipping rates.
List on eBay with our App! Try it for free now!

Setup Prod Offscrub Apr 2026

$tasksToDisable = @( "Microsoft\Windows\DiskDiagnostic*", "Microsoft\Windows\Power Efficiency Diagnostics*" )

| Service Name | Required? | OffScrub Action | |--------------|-----------|------------------| | Spooler | Yes (printing) | Keep | | WSearch | No (search indexing) | Disable | | SysMain | No (Superfetch) | Disable | | Themes | Yes (UI stability) | Keep | The most common production-ready implementation is a PowerShell script that wraps Set-Service , Stop-Process , and Disable-ScheduledTask .

If you manage a Windows environment—especially one involving Remote Desktop Services (RDS), Citrix, or VMware Horizon—you’ve likely heard of OffScrub . It’s a powerful script from Microsoft’s SysInternals suite (specifically part of PSExec and the Windows Assessment Toolkit) used to selectively disable or stop non-essential background processes, services, and scheduled tasks. setup prod offscrub

Why would you do this in production? To , improve session density, or eliminate application conflicts on shared servers. However, running OffScrub incorrectly in production can break critical services, crash applications, or orphan user sessions.

foreach ($svc in $servicesToStop) if (Get-Service -Name $svc -ErrorAction SilentlyContinue) Stop-Service $svc -Force Set-Service $svc -StartupType Disabled Write-Host "Disabled: $svc" improve session density

Get-Service | Where-Object $_.StartType -eq "Disabled" | Export-Clixml -Path "C:\OffScrubBackup\services_before.xml" Restore script:

Do not run OffScrub on domain controllers or SQL servers without overrides. $tasksToDisable = @( "Microsoft\Windows\DiskDiagnostic*"

$backup = Import-Clixml -Path "C:\OffScrubBackup\services_before.xml" foreach ($svc in $backup) Set-Service $svc.Name -StartupType $svc.StartType

Use Infrastructure as Code (Terraform + Ansible) to version-control your OffScrub configuration. Treat your optimizations like application code—with tests and rollbacks. Have you deployed OffScrub in production? Share your exclusion list or horror story in the comments below.

Write-Host "Starting Production OffScrub - $(Get-Date)"

When done correctly, OffScrub can significantly reduce memory and CPU overhead on VDI/RDSH hosts, sometimes improving user density by 15–25%. When done wrong, it can take down a production farm in minutes.