Skip to content

NotFound","message":"Resource /subscription........Microsoft.Network/loadBalancers/VMSSNAME6LB not found. #13639

Open

Description

[Template Name goes here](VM Scale Set with autoscale running an IIS WebApp)

Issue Details

When I try to deploy main.bicep after creating resopurce group I get the error message

{"status":"Failed","error":{"code":"DeploymentFailed","target":"/subscriptions/f151ee3f-4725-460d-8e3b-82512dfda843/resourceGroups/bicepquickstart/providers/Microsoft.Resources/deployments/main","message":"At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details.","details":[{"code":"InvalidResourceReference","message":"Resource /subscriptions/f151ee3f-4725-460d-8e3b-82512dfda843/resourceGroups/BICEPQUICKSTART/providers/Microsoft.Network/loadBalancers/VMSSNAME6LB referenced by resource /subscriptions/f151ee3f-4725-460d-8e3b-82512dfda843/resourceGroups/BICEPQUICKSTART/providers/Microsoft.Compute/virtualMachineScaleSets/vmssname6 was not found. Please make sure that the referenced resource exists, and that both resources are in the same region.","details":[{"code":"NotFound","message":"Resource /subscriptions/f151ee3f-4725-460d-8e3b-82512dfda843/resourceGroups/BICEPQUICKSTART/providers/Microsoft.Network/loadBalancers/VMSSNAME6LB not found."}]}]}}

In spite of the fact that VMSSNAME6LB is created as you can notice in the azure screen

image

Repro steps (if necessary, delete otherwise)

  1. Create resource group
  2. az deployment group create --resource-group bicepquickstart --parameters vmssName=vmssfrombicep --template-file main.bicep
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions