Remove-AzureStorSimpleAccessControlRecord

Deletes an access control record from the service configuration.

Note

The cmdlets referenced in this documentation are for managing legacy Azure resources that use Azure Service Manager (ASM) APIs. This legacy PowerShell module isn't recommended when creating new resources since ASM is scheduled for retirement. For more information, see Azure Service Manager retirement.

The Az PowerShell module is the recommended PowerShell module for managing Azure Resource Manager (ARM) resources with PowerShell.

Syntax

Remove-AzureStorSimpleAccessControlRecord
      -ACRName <String>
      [-WaitForComplete]
      [-Force]
      [-Profile <AzureSMProfile>]
      [<CommonParameters>]
Remove-AzureStorSimpleAccessControlRecord
      -ACR <AccessControlRecord>
      [-WaitForComplete]
      [-Force]
      [-Profile <AzureSMProfile>]
      [<CommonParameters>]

Description

The Remove-AzureStorSimpleAccessControlRecord cmdlet deletes an access control record from the service configuration.

Examples

Example 1: Remove an Access Controlaccess control recordaccess control

PS C:\>Remove-AzureStorSimpleAccessControlRecord -ACRName "Acr10" -WaitForComplete -Force
VERBOSE: ClientRequestId: 574aeb7f-fbc9-46d5-bc68-1bfe4487bd8b_PS
VERBOSE: ClientRequestId: 985afe84-ef95-47cb-8c8f-df094530334b_PS
VERBOSE: About to run a job to remove your ACR! 
VERBOSE: ClientRequestId: 7eb7e1a0-2288-44da-b64c-5bf86a6b9aaf_PS


JobId        : f7934db5-8363-4152-b38e-b9a5d91f97b9
JobResult    : Succeeded
JobStatus    : Completed
ErrorCode    : 
ErrorMessage : 
JobSteps     : {}

VERBOSE: The job created for your delete operation has completed successfully.

This command deletes the access control record named Acr10. This command specifies the WaitForComplete parameter, and, therefore, the command waits until the operation is complete, and then returns a TaskStatusInfo object.

Example 2: Remove an Access Controlaccess control record by using the pipelineAccess Controlaccess controlaccess control

PS C:\>Get-AzureStorSimpleAccessControlRecord -ACRName "Acr10" | Remove-AzureStorSimpleAccessControlRecord -Force 
VERBOSE: ClientRequestId: ff8d8bd6-4c92-4ab6-8fde-e9344a253da3_PS
VERBOSE: ClientRequestId: f71c74f3-33b9-40d1-b8d5-12363e98412f_PS
VERBOSE: ClientRequestId: d5d809d0-ec22-4e45-97ee-a56edc41e503_PS
VERBOSE: About to create a job to remove your ACR! 
VERBOSE: ClientRequestId: 6ffa6bc8-37b3-49ff-bafc-721b360f09cb_PS
294a0208-a43f-4d80-b824-2319cd77c5e6
VERBOSE: The delete task is submitted successfully. Please use the command Get-AzureStorSimpleTask -InstanceId
294a0208-a43f-4d80-b824-2319cd77c5e6 for tracking the task's status

This command uses the Get-AzureStorSimpleAccessControlRecord to get the AccessControlRecord named Acr10, and then passes that object to the current cmdlet by using the pipeline operator. The command starts the operation that removes the AccessControlRecord object, and then returns a TaskResponse object. To see the status of the task, use the Get-AzureStorSimpleTask cmdlet.

Parameters

-ACR

Specifies an AccessControlRecord object to delete. To obtain an AccessControlRecord object, use the Get-AzureStorSimpleAccessControlRecord cmdlet.

Type:AccessControlRecord
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-ACRName

Specifies a name of the access control record to delete.

Type:String
Aliases:Name
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-Force

Indicates that this cmdlet does not prompt you for confirmation.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Profile

Specifies an Azure profile.

Type:AzureSMProfile
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WaitForComplete

Indicates that this cmdlet waits for the operation to complete before it returns control to the Windows PowerShell console.

Type:SwitchParameter
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

AccessControlRecord

This cmdlet accepts an AccessControlRecord object. An AccessControlRecord object contains the following fields:

  • GlobalId (String)
  • InitiatorName (String)
  • InstanceId (String)
  • Name (String)
  • OperationInProgress (OperationInProgress)
  • VolumeCount (int)

Outputs

TaskStatusInfo, TaskResponse

This cmdlet returns a TaskStatusInfo object if you specify the WaitForComplete parameter. If you do not specify that parameter, it returns a TaskResponse object.