Service of type LoadBalancer stuck with `EXTERNAL-IP <pending>`; events show `Error syncing load balancer: failed to ensure load balancer: ... AuthorizationFailed ... 'Microsoft.Network/virtualNetworks/subnets/read'`.
IntermediateTroubleshootingAKS and ACR Errors
Answer
Likely causes → The cluster's control-plane identity lacks rights on a custom VNet subnet (in another RG), or on the RG of a pre-created public IP.
Diagnose →
kubectl describe svc web -n shop | sed -n '/Events/,$p'
az aks show -g rg -n aks --query identity.principalId -o tsv
Fix → Grant Network Contributor on the subnet (or VNet) to the cluster identity; for static IPs in another RG, grant it on that RG and use the azure-load-balancer-resource-group annotation.
Prevent → Include cluster identity network roles in the cluster IaC.
More on AKS and ACR Errors
Pods show `ImagePullBackOff` with `failed to authorize: failed to fetch anonymous token: unexpected status from GET request to https://acrshop.azurecr.io/oauth2/token?...: 401 Unauthorized`.Beginner`Failed to pull image "acrshop.azurecr.io/shop/web:v3": ... manifest unknown` or `not found`.Beginner`ImagePullBackOff` with `dial tcp: lookup acrshop.azurecr.io on 168.63.129.16:53: no such host` or connection timeouts to the registry.Advanced`exec /usr/local/bin/python: exec format error` in pod logs right after deploying a new image.BeginnerPods are `Pending`: `0/3 nodes are available: 3 Insufficient cpu. preemption: 0/3 nodes are available: 3 No preemption victims found for incoming pod.`BeginnerCluster autoscaler events show `pod didn't trigger scale-up: 1 max node group size reached` or `NotTriggerScaleUp`.Intermediate