你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

Remove-AzPrivateDnsVirtualNetworkLink

Removes a virtual network link from a resource group.

Syntax

Remove-AzPrivateDnsVirtualNetworkLink
      -ResourceGroupName <String>
      -ZoneName <String>
      -Name <String>
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-AzPrivateDnsVirtualNetworkLink
      -InputObject <PSPrivateDnsVirtualNetworkLink>
      [-Overwrite]
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]
Remove-AzPrivateDnsVirtualNetworkLink
      -ResourceId <String>
      [-PassThru]
      [-DefaultProfile <IAzureContextContainer>]
      [-WhatIf]
      [-Confirm]
      [<CommonParameters>]

Description

The Remove-AzPrivateDnsVirtualNetworkLink cmdlet permanently deletes a private Domain Name System (DNS) link from a specified resource group. You can pass a PSPrivateDnsVirtualNetworkLink object using the Link parameter or by using the pipeline operator, or alternatively you can specify the Name ZoneName and ResourceGroupName parameters. You can use the Confirm parameter and $ConfirmPreference Windows PowerShell variable to control whether the cmdlet prompts you for confirmation. When specifying the link using a PSPrivateDnsVirtualNetworkLink object (passed via the pipeline or Link parameter), the link is not deleted if it has been changed in Azure Private DNS since the local PSPrivateDnsVirtualNetworkLink object was retrieved. This provides protection for concurrent zone changes. This can be suppressed using the Overwrite parameter, which deletes the zone regardless of concurrent changes.

Examples

Remove-AzPrivateDnsVirtualNetworkLink -ResourceGroupName "MyResourceGroup" -ZoneName "myzone.com" -Name "mylink"

This command removes the link named mylink linked to zone myzone.com from the resource group named MyResourceGroup.

Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

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

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure

Type:IAzureContextContainer
Aliases:AzContext, AzureRmContext, AzureCredential
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

The virtual network link object to remove.

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

-Name

Specifies the name of the link to be deleted. You must also specify the ResourceGroupName and ZoneName parameter. Alternatively, you can specify the link using the Link parameter.

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

-Overwrite

When specifying the zone using a PSPrivateDnsVirtualNetworkLink object (passed via the pipeline or Link parameter), the zone is not deleted if it has been changed in Azure DNS since the local PSPrivateDnsVirtualNetworkLink object was retrieved. This provides protection for concurrent zone changes. This can be suppressed using the Overwrite parameter, which deletes the zone regardless of concurrent changes.

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

-PassThru

Used for passing the result (boolean) of the operation delete virtual network link further down the pipeline.

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

-ResourceGroupName

Specifies the name of the resource group that contains the link to remove. You must also specify the ZoneName and Name parameter. Alternatively, you can specify the DNS zone using a PSPrivateDnsVirtualNetworkLink object, passed via either the pipeline or the Link parameter.

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

-ResourceId

Specifies the ARM resource ID of the link.

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

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

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

-ZoneName

Specifies the name of the private DNS zone that the link is associated with. You must also specify the ResourceGroupName and Name parameter. Alternatively, you can specify the link using the Link parameter.

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

Inputs

PSPrivateDnsVirtualNetworkLink

String

Outputs

Boolean