Table of Contents

Remove-CafLocks

Removes locks from the resource group with the given name and retrieves the removed lock objects.

Syntax

Remove-CafLocks
    [-ResourceGroupName <string>]
    [-Scope <string>]
    [-WaitSeconds <int>]
    [-AllLockLevels]

Description

This will try to remove all locks which are not defined by Azure internally from the given resource group. It will return an array of all the locks that were removed which can be passed to Restore-CafLocks later.

Example

Remove-CafLocks

Parameter

-ResourceGroupName
The name of the resource group to remove the lock from.

Property Value
Type: string
Default value: None
Required: False

-Scope
The scope of the lock. If this is set, the ResourceGroupName parameter will be ignored.

Property Value
Type: string
Default value: None
Required: False

-WaitSeconds The number of seconds to wait after removing each lock before returning. This delay is required because Azure may return before the lock removal has fully propagated.

Property Value
Type: int
Default value: 10
Required: False

-AllLockLevels
If set all lock levels will be removed. By default only CanNotDelete is removed.

Property Value
Type: SwitchParameter
Default value: False
Required: False

See also