Manage Learn to apply best practices and optimize your operations.

Set Win10 RS5 Rollback Retention Interval

I don’t normally write much about the Insider Preview builds for this blog post. Practicing Enterprise admins have enough on their hands keeping up with current branch versions of the OS. But when I see new features of potential benefit, I break that restriction happily. As of Build 17682, the built-in Deployment Image Servicing and Management (DISM) command gains an interesting new capability. At the command line, you can tell it to alter the default 10-day retention period for keeping Windows.old around. That means when the next version of Windows 10 goes into production, you can set a rollback period of your choosing simply and easily. Thus, it’s piece of cake to set Win10 R5 rollback retention interval however you like it.

How to Set Win10 RS5 Rollback Retention Interval?

Here’s a PowerShell screen capture that shows me:

  • inquiring about the current interval
  • re-resetting that interval to 12 days
  • showing that changed value

Set Win10 RS5 Rollback Retention Interval.dism-examples

DISM /ONLINE is a given, because we’re working on a loaded (and running) Windows image. The new cmdlets are Get-OSUninstallWindow and Set-OSUninstallWindow.
[Click on image for full-sized view.]

The syntax for Get-OSUninstallWindow is dead simple. By itself, it shows you the current number of days the OS will keep Windows.old around, thereby allowing rollback to occur. Set-OSUninstallWindows takes an integer value for the /Value attribute. It resets the retention interval to whatever number of days you specify. Thus, I show the intial value as a default of 10 days. I reset that to 12 days, and use Get-OSUninstallWindow again to show the change has been applied.

What’s Your OSInstallWindow Choice?

It’s whatever you want it to be. If you build canonical images for deployment, you can use this DISM command on a running instance of that canonical OS to make this change while it’s online. Note that MS Docs “DISM operating system uninstall command-line options” includes this warning: “OEMs shouldn’t use this setting in imaging or manufacturing scenarios. This setting is for IT administrators.” That said, I don’t see a downside to changing this in a canonical image prior to its deployment to testing or production. And then, your rollback interval will be whatever you choose!

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.