NAME
Add-DcsObjectImmutability
SYNOPSIS
Adds immutability to an existing parent object.
SYNTAX
Add-DcsObjectImmutability [ -ParentObject] <String> -RetentionPeriod <DateTime> [ -Connection <String>] [ -PipelineVariable <String>] [ <CommonParameters> ]
DESCRIPTION
Adds immutability to an existing parent object. Currently, immutability is supported only for snapshots.
PARAMETERS
- -ParentObject <String>
- Name or ID of the parent object.
-
- Required: true
- Position: 1
- Default value:
- Accept pipeline input: true
- Accept wildcard characters: false
-
- -RetentionPeriod <DateTime>
- The date and time of the immutability retention period.
- One way to provide the RetentionPeriod parameter would be by piping a variable created by invoking New-Object with the TypeName parameter of DateTime with the correct arguments (see Help for New-Object, Get-Date).
- The RetentionPeriod parameter can also be provided in a string with the date and time. An example of the format to use is "Tuesday, March 29, 2011 2:51:00 PM".
-
- Required: true
- Position: named
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
- -Connection <String>
- Alias representing the connection to the server group. If not specified, the default connection will be used.
-
- Required: false
- Position: named
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
- -PipelineVariable <String>
-
- Required: false
- Position: named
- Default value:
- Accept pipeline input: false
- Accept wildcard characters: false
-
- <CommonParameters>
- This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, OutBuffer, PipelineVariable, and OutVariable. For more information, see about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
-
INPUTS
OUTPUTS
ImmutableDataObject that identifies the immutability.
NOTES
Also see Verify-DcsObjectImmutability, Get-DcsObjectImmutability.
EXAMPLES
-------------- Example 1 Adds immutabilty to the snapsot --------------
Add-DcsObjectImmutability -ParentObject "Virtual disk 1 @ 8/12/2025 10:58:05 AM UTC" -RetentionPeriod "8/13/2025 10:58:05 AM"
Adds immutability to the snapshot "Virtual disk 1 @ 8/12/2025 10:58:05 AM UTC".
ParentObjectId | : | V.{25C53AAB-7384-11F0-A4E7-00155D020673}-00000001--V.{25C53AAB-7384-11F0-A4E7-00155D020673}-00000006 |
Hash | : | |
ImmutableObjectTimeStamp | : | 8/12/2025 11:03:25 AM |
ExpiryTimestamp | : | 8/13/2025 5:58:05 PM |
State | : | Failed |
VerificationTimeStamp | : | 1/1/0001 12:00:00 AM |
VerificationState | : | NotStarted |
SequenceNumber | : | 3707619 |
Id | : | 3bdfbf2227d246b0974789379ce404b1 |
Caption | : | Immutable Virtual disk 1 @ 8/12/2025 10:58:05 AM UTC on SSV2 |
ExtendedCaption | : | Immutable Virtual disk 1 @ 8/12/2025 10:58:05 AM UTC on SSV2 expires - 8/13/2025 5:58:05 PM Internal : False |
Internal | : | False |