You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: Learn how to troubleshoot Azure Microsoft.Network failed Provisioning State.
3
+
description: Learn about the meaning of various provisioning states and how to troubleshoot Azure Microsoft.Network failed Provisioning State.
4
4
services: networking
5
5
author: stegag
6
-
7
6
ms.service: virtual-network
8
7
ms.custom: devx-track-azurepowershell
9
8
ms.topic: how-to
10
-
ms.date: 04/08/2022
9
+
ms.date: 03/21/2023
11
10
ms.author: stegag
12
11
---
13
12
14
13
# Troubleshoot Azure Microsoft.Network failed provisioning state
15
14
16
-
This article helps understand the meaning of various provisioning states for Microsoft.Network resources and how to effectively troubleshoot situations when the state is **Failed**.
15
+
This article helps you understand the meaning of various provisioning states for Microsoft.Network resources. You can effectively troubleshoot situations when the state is **Failed**.
The provisioning state is the status of a user-initiated, control-plane operation on an Azure Resource Manager resource.
21
+
The provisioning state is the status of a user-initiated, control-plane operation on an Azure Resource Manager resource.
23
22
24
23
| Provisioning state | Description |
25
24
|---|---|
26
25
| Updating | Resource is being created or updated. |
27
-
| Failed | Last operation on the resource was not successful. |
28
-
| Succeeded | Last operation on the resource was successful. |
29
-
| Deleting | Resource is being deleted. |
30
-
| Migrating | Seen when migrating from Azure Service Manager to Azure Resource Manager. |
26
+
| Failed | Last operation on the resource wasn't successful. |
27
+
| Succeeded | Last operation on the resource was successful. |
28
+
| Deleting | Resource is being deleted. |
29
+
| Migrating | Seen when migrating from Azure Service Manager to Azure Resource Manager. |
31
30
32
-
These states are just metadata properties of the resource and are independent from the functionality of the resource itself.
33
-
Being in a failed state does not necessarily mean that the resource is not functional, in fact in most cases it can continue operating and servicing traffic without issues.
31
+
These states are metadata properties of the resource. They're independent from the functionality of the resource itself. Being in the failed state doesn't necessarily mean that the resource isn't functional. In most cases, it can continue operating and serving traffic without issues.
34
32
35
-
However in several scenariosfurther operations on the resource or on other resources that depend on it may fail if the resource is in failed state, so the state needs to be reverted back to succeeded before executing other operations.
33
+
In several scenarios, if the resource is in the failed state, further operations on the resource or on other resources that depend on it might fail. You need to revert the state back to succeeded before running other operations.
36
34
37
-
For example, you cannot execute an operation on a VirtualNetworkGateway if it has a dependent VirtualNetworkGatewayConnection object in failed state and viceversa.
35
+
For example, you can't run an operation on a `VirtualNetworkGateway` if it has a dependent `VirtualNetworkGatewayConnection` object in failed state.
38
36
39
37
## Restoring succeeded state through a PUT operation
40
38
41
-
The correct way to restore succeeded state is to execute another write (PUT) operation on the resource.
39
+
To restore succeeded state, run another write (`PUT`) operation on the resource.
42
40
43
-
Most times, the issue that caused the previous operation might no longer be current, hence the newer write operation should be successful and restore the provisioning state.
41
+
The issue that caused the previous operation might no longer be current. The newer write operation should be successful and restore the provisioning state.
44
42
45
-
The easiest way to achieve this task is to use Azure PowerShell. You will need to issue a resource-specific "Get" command that fetches all the current configuration for the impacted resource as it is deployed. Next, you can execute a "Set" command (or equivalent) to commit to Azure a write operation containing all the resource properties as they are currently configured.
43
+
The easiest way to achieve this task is to use Azure PowerShell. Issue a resource-specific *Get* command that fetches all the current configuration for the resource. Next, run a *Set* command, or equivalent, to commit to Azure a write operation that contains all the resource properties as currently configured.
46
44
47
45
> [!IMPORTANT]
48
-
> 1. Executing a "Set" command on the resource without running a "Get" first will result in overwriting the resource with default settings which might be different from those you currently have configured. Do not just run a "Set" command unless resetting settings is intentional.
49
-
> 2. Executing a "Get" and "Set" operation using third party software or otherwise any tool using older API version may also result in loss of some settings, as those may not be present in the API version with which you have executed the command.
46
+
>
47
+
> - Running a `Set` command on the resource without first running a `Get` results in overwriting the resource with default settings. Those settings might be different from the ones you currently have configured. Don't just run a `Set` command unless you intend to reset to default.
48
+
> - Running a `Get` and `Set` operation using third party software or any tool using older API version might also result in loss of some settings. Those settings might not be present in the API version with which you run the command.
50
49
>
51
50
## Azure PowerShell cmdlets to restore succeeded provisioning state
1. Install the latest version of the Azure Resource Manager PowerShell cmdlets. For more information, see [Install and configure Azure PowerShell](/powershell/azure/install-az-ps).
56
+
1. Install the latest version of the Azure Resource Manager PowerShell cmdlets. For more information, see [Install the Azure Az PowerShell module](/powershell/azure/install-az-ps).
58
57
59
58
2. Open your PowerShell console with elevated privileges, and connect to your account. Use the following example to help you connect:
60
59
61
60
```azurepowershell-interactive
62
61
Connect-AzAccount
63
62
```
63
+
64
64
3. If you have multiple Azure subscriptions, check the subscriptions for the account.
5. Run the resource-specific commands listed below to reset the provisioning state to succeeded.
75
-
75
+
76
+
5. Run the resource-specific commands in the following sections to reset the provisioning state.
77
+
76
78
> [!NOTE]
77
-
>Every sample command in this article uses "your_resource_name" for the name of the Resource and "your_resource_group_name" for the name of the Resource Group. Make sure to replace these strings with the appropriate Resource and Resource Group names according to your deployment.
79
+
>Every sample command in this article uses `your_resource_name` for the name of the resource and `your_resource_group_name` for the name of the resource group. Make sure to replace these strings with the appropriate resource and resource group names for your deployment.
> **Microsoft.Network/expressRouteGateways** are those gateways deployed within a Virtual WAN. If you have a standalone gateway of ExpressRoute type in your Virtual Network you need to execute the commands related to [Microsoft.Network/virtualNetworkGateways](#microsoftnetworkvirtualnetworkgateways).
126
+
> `Microsoft.Network/expressRouteGateways` are deployed within a Virtual WAN. If you have a standalone ExpressRoute gateway in your virtual network, run the commands related to [Microsoft.Network/virtualNetworkGateways](#microsoftnetworkvirtualnetworkgateways).
> 1.**Microsoft.Network/vpnGateways** are those gateways deployed within a Virtual WAN. If you have a standalone gateway of VPN type in your Virtual Network you need to execute the commands related to [Microsoft.Network/virtualNetworkGateways](#microsoftnetworkvirtualnetworkgateways).
245
-
> 2. Most Virtual WAN related resources such as vpnGateways leverage the "Update" cmdlet and not the "Set" for write operations.
252
+
>
253
+
> -`Microsoft.Network/vpnGateways` are deployed within a Virtual WAN. If you have a standalone VPN gateway in your virtual network, run the commands related to [Microsoft.Network/virtualNetworkGateways](#microsoftnetworkvirtualnetworkgateways).
254
+
> - Most Virtual WAN related resources, such as vpnGateways, use the `Update` cmdlet, not the `Set` for write operations.
> Most Virtual WAN related resources such as vpnSites leverage the "Update" cmdlet and not the "Set" for write operations.
254
-
255
261
262
+
> [!NOTE]
263
+
> Most Virtual WAN related resources, such as vpnSites, use the `Update` cmdlet, not the `Set`, for write operations.
256
264
257
265
## Next steps
258
266
259
-
If the command executed didn't fix the failed state, it should return an error code for you.
267
+
If the command that you ran didn't resolve the failed state, it should return an error code.
260
268
Most error codes contain a detailed description of what the problem might be and offer hints to solve it.
261
269
262
-
Open a support ticket with [Microsoft support](https://portal.azure.com/?#blade/Microsoft_Azure_Support/HelpAndSupportBlade) if you're still experiencing issues.
263
-
Make sure you specify to the Support Agent both the error code you received in the latest operation, as well as the timestamp of when the operation was executed.
270
+
If you're still experiencing issues, open a support ticket with [Microsoft support](https://portal.azure.com/?#blade/Microsoft_Azure_Support/HelpAndSupportBlade). Specify to the support agent both the error code that you received in the latest operation and the timestamp when you ran the operation.
0 commit comments