|
| 1 | +--- |
| 2 | +title: include file |
| 3 | +description: include file |
| 4 | +services: virtual-network-manager |
| 5 | +author: mbender-ms |
| 6 | +ms.service: azure-virtual-network-manager |
| 7 | +ms.topic: include |
| 8 | +ms.date: 02/02/2026 |
| 9 | +ms.author: mbender |
| 10 | +ms.custom: include file |
| 11 | +--- |
| 12 | + |
| 13 | +## Create a Virtual Network Manager instance |
| 14 | + |
| 15 | +Deploy a Virtual Network Manager instance with the defined scope and access that you need. You can create a Virtual Network Manager instance using the Azure portal, Azure CLI, or Azure PowerShell. |
| 16 | + |
| 17 | +# [Portal](#tab/azure-portal) |
| 18 | + |
| 19 | +1. Sign in to the [Azure portal](https://portal.azure.com/). |
| 20 | + |
| 21 | +1. Select **+ Create a resource** and search for **Network Manager**. Then select **Network Manager** > **Create** to begin setting up Virtual Network Manager. |
| 22 | + |
| 23 | +1. On the **Basics** tab, enter or select the following information: |
| 24 | + |
| 25 | + | Setting | Value | |
| 26 | + | ------- | ----- | |
| 27 | + | **Subscription** | Select the subscription containing your existing virtual networks. | |
| 28 | + | **Resource group** | Select the existing resource group where you want to deploy Virtual Network Manager. | |
| 29 | + | **Name** | Enter a name for your Virtual Network Manager instance. | |
| 30 | + | **Region** | Select a region for your Virtual Network Manager instance. Virtual Network Manager can manage virtual networks in any region. The selected region is where the Virtual Network Manager instance will be deployed. | |
| 31 | + | **Description** | *(Optional)* Provide a description about this Virtual Network Manager instance and the task it's managing. | |
| 32 | + | [Features](../../../virtual-network-manager/concept-network-manager-scope.md#features) | Select the features you need from the dropdown list: </br> - **Connectivity**: Enables the creation of a full mesh or hub-and-spoke network topology between virtual networks within the scope. </br> - **Security Admin**: Enables the creation of global network security rules. </br> - **Routing**: Enables the creation and management of user-defined routes at scale. | |
| 33 | + |
| 34 | +1. Select the **Management scope** tab or **Next: Management scope** to continue. |
| 35 | + |
| 36 | +1. On the **Management scope** tab, select **+ Add**. |
| 37 | + |
| 38 | +1. In the **Add scopes** pane, select the subscriptions or management groups containing your existing virtual networks, and choose **Select**. |
| 39 | + |
| 40 | +1. Select **Review + create** to validate your configuration. |
| 41 | + |
| 42 | +1. After validation passes, select **Create** to deploy the Virtual Network Manager instance. |
| 43 | + |
| 44 | +# [Azure CLI](#tab/azure-cli) |
| 45 | + |
| 46 | +1. Sign in to Azure and set your subscription context: |
| 47 | + |
| 48 | + ```azurecli-interactive |
| 49 | + az login |
| 50 | + az account set --subscription "<subscription-id>" |
| 51 | + ``` |
| 52 | +
|
| 53 | +1. Install or update the Virtual Network Manager extension: |
| 54 | +
|
| 55 | + ```azurecli-interactive |
| 56 | + az extension add --name virtual-network-manager |
| 57 | + az extension update --name virtual-network-manager |
| 58 | + ``` |
| 59 | +
|
| 60 | +1. Create a Virtual Network Manager instance using [az network manager create](/cli/azure/network/manager#az-network-manager-create). Replace the placeholder values with your specific information: |
| 61 | +
|
| 62 | + ```azurecli-interactive |
| 63 | + az network manager create \ |
| 64 | + --name "<network-manager-name>" \ |
| 65 | + --location "<region>" \ |
| 66 | + --resource-group "<existing-resource-group-name>" \ |
| 67 | + --scope-accesses "Connectivity" "SecurityAdmin" \ |
| 68 | + --network-manager-scopes subscriptions="/subscriptions/<subscription-id>" \ |
| 69 | + --description "<optional-description>" |
| 70 | + ``` |
| 71 | +
|
| 72 | + > [!NOTE] |
| 73 | + > For management group scope, use: `managementGroups="/providers/Microsoft.Management/managementGroups/<management-group-id>"` |
| 74 | + > Ensure the specified resource group already exists in your subscription. |
| 75 | +
|
| 76 | +# [Azure PowerShell](#tab/azure-powershell) |
| 77 | +
|
| 78 | +1. Sign in to Azure and set your subscription context: |
| 79 | +
|
| 80 | + ```azurepowershell-interactive |
| 81 | + Connect-AzAccount |
| 82 | + Set-AzContext -Subscription "<subscription-id>" |
| 83 | + ``` |
| 84 | +
|
| 85 | +1. Install or update the Azure PowerShell module: |
| 86 | +
|
| 87 | + ```azurepowershell-interactive |
| 88 | + Install-Module -Name Az.Network -Force |
| 89 | + ``` |
| 90 | +
|
| 91 | +1. Define the scope and access type for your Virtual Network Manager instance: |
| 92 | +
|
| 93 | + ```azurepowershell-interactive |
| 94 | + # Define subscription scope |
| 95 | + $subscriptionId = "<subscription-id>" |
| 96 | + [System.Collections.Generic.List[string]]$subGroup = @() |
| 97 | + $subGroup.Add("/subscriptions/$subscriptionId") |
| 98 | + |
| 99 | + # Define access types |
| 100 | + [System.Collections.Generic.List[String]]$access = @() |
| 101 | + $access.Add("Connectivity") |
| 102 | + $access.Add("SecurityAdmin") |
| 103 | + |
| 104 | + # Create scope object |
| 105 | + $scope = New-AzNetworkManagerScope -Subscription $subGroup |
| 106 | + ``` |
| 107 | +
|
| 108 | +1. Create the Virtual Network Manager instance using [New-AzNetworkManager](/powershell/module/az.network/new-aznetworkmanager): |
| 109 | +
|
| 110 | + ```azurepowershell-interactive |
| 111 | + $networkManagerParams = @{ |
| 112 | + Name = "<network-manager-name>" |
| 113 | + ResourceGroupName = "<existing-resource-group-name>" |
| 114 | + Location = "<region>" |
| 115 | + NetworkManagerScope = $scope |
| 116 | + NetworkManagerScopeAccess = $access |
| 117 | + Description = "<optional-description>" |
| 118 | + } |
| 119 | + |
| 120 | + $networkManager = New-AzNetworkManager @networkManagerParams |
| 121 | + ``` |
| 122 | +
|
| 123 | + > [!NOTE] |
| 124 | + > Ensure the specified resource group already exists in your subscription. |
| 125 | +
|
| 126 | +--- |
| 127 | +
|
| 128 | +> [!IMPORTANT] |
| 129 | +> Virtual Network Manager requires specific permissions within the defined scope. Ensure you have the necessary [Azure RBAC roles](../../../virtual-network-manager/concept-network-manager-scope.md#permissions) before creating the instance. |
| 130 | +
|
| 131 | +The Virtual Network Manager instance is now created and ready to manage your existing virtual networks within the defined scope. You can proceed to create network groups and configurations to organize and manage your virtual networks. |
0 commit comments