Set-WssDrive
Changes drive name or whether to enable snapshots.
Set-WssDrive
[-Name] <String>
[[-NewName] <String>]
[[-SnapshotsEnabled] <Boolean>]
[-Force]
[-Confirm]
[-WhatIf]
Set-WssDrive
[-Drive] <Drive>
[[-NewName] <String>]
[[-SnapshotsEnabled] <Boolean>]
[-Force]
[-Confirm]
[-WhatIf]
Set-WssDrive
[-ID] <Guid>
[[-NewName] <String>]
[[-SnapshotsEnabled] <Boolean>]
[-Force]
[-Confirm]
[-WhatIf]
The Set-WssDrive cmdlet changes the name of a drive or whether to enable snapshots for a drive. You can specify a drive by using its name or its GUID, or you can use the Get-WssDrive cmdlet to obtain a Drive object. To specify a new drive name, use the NewName parameter. To specify whether to enable snapshots, use the SnapShotsEnabled parameter.
PS C:\>$Drive = Get-WssDrive -ID b6b093a2-1860-4172-a4a5-07ce2aebfa13 PS C:\> Set-WssDrive -Drive $Drive -NewName "Sarah Jones Volume"
This example renames a drive. The first command uses the Get-WssDrive cmdlet to get a Drive object that has the specified GUID, and stores it in the $Drive variable.
The second command changes the name of the drive represented by the object stored in the $Drive variable to Sarah Jones Volume.
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies a Drive object. To obtain a Drive object, use the Get-WssDrive cmdlet.
Type: | Drive |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Forces the command to run without asking for user confirmation.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the GUID of a drive.
Type: | Guid |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the name of a drive.
Type: | String |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies a new name for the drive.
Type: | String |
Position: | 2 |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Indicates whether to enable snapshots on the drive.
Type: | Boolean |
Position: | 3 |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Drive