Cmdlets

Choose a cmdlet from the list on the left or search for a specific cmdlet. Choose a cmdlet from the list or search for a specific cmdlet.
About Help  Providers  Aliases  Modules
 

Disable-ComputerRestore

Disable-ComputerRestore

Microsoft.PowerShell.Core

Synopsis

Disables the System Restore feature on the specified file system drive.

Syntax

Disable-ComputerRestore [-Drive] [-Confirm] [-WhatIf] [<CommonParameters>]

Detailed Description

The Disable-ComputerRestore cmdlet turns off the System Restore feature on one or more file system drives. As a result, attempts to restore the computer do not affect the specified drive.

To disable System Restore on any drive, it must be disabled on the system drive, either first or concurrently.

To re-enable System Restore, use the Enable-ComputerRestore cmdlet. To find the state of System Restore for each drive, use Rstrui.exe.

System restore points and the ComputerRestore cmdlets are supported only on client operating systems, such as Windows 7, Windows Vista, and Windows XP.

Parameters

-Confirm <SwitchParameter>

Aliases

cf

Required?

false

Position

named

Default value

False

Accept pipeline input?

False

Accept wildcard characters?

false

-Drive <String[]>

Aliases

none

Required?

true

Position

0

Default value

None

Accept pipeline input?

False

Accept wildcard characters?

false

-WhatIf <SwitchParameter>

Aliases

wi

Required?

false

Position

named

Default value

False

Accept pipeline input?

False

Accept wildcard characters?

false

Input Type

None

Return Type

None

Notes

* To run this cmdlet on Windows Vistaand later versions of Windows, open Windows PowerShell with the Run as administrator option.

To find the file system drives that are eligible for system restore, in System in Control Panel, see the System Protection tab. To open this tab in Windows PowerShell, type `SystemPropertiesProtection`.

This cmdlet uses the Windows Management Instrumentation (WMI) SystemRestore class.

*

Examples

Example 1: Disable System Restore on the specified drive

This command disables System Restore on the C: drive.

PS C:\>Disable-ComputerRestore -Drive "C:\"

Example 2: Disable System Restore on multiple drives

This command disables System Restore on the C: and D: drives. The command uses the Drive parameter, but it omits the Drive parameter name.

PS C:\>Disable-ComputerRestore "C:\", "D:\"

Online Version
Checkpoint-Computer
Enable-ComputerRestore
Get-ComputerRestorePoint
Restart-Computer
Restore-Computer