An Azure networking service that is used to provision private networks and optionally to connect to on-premises datacenters.
For an Azure VNet private IP, there isn’t a native concept of “reserving” a single IP in a subnet as a standalone resource the way Public IPs work. Azure only guarantees a private IP is held if it is attached to something like a NIC or a Load Balancer frontend configuration. If nothing owns it, it’s just part of the free pool and can be taken by anything.
So if you want a private IP that survives Kubernetes cluster or Service teardown, you have to anchor that IP to an Azure resource that persists independently of the cluster. The usual pattern is to pre-create an Azure Standard Load Balancer with a frontend IP configuration set to a specific static private IP from your subnet.
Example of creating that frontend IP on a load balancer:
az network lb create \
--resource-group <rg> \
--name <lb-name> \
--sku Standard \
--vnet-name <vnet> \
--subnet <subnet> \
--frontend-ip-name <frontend-name> \
--private-ip-address 10.0.0.50
That effectively “reserves” 10.0.0.50 because it is now owned by the load balancer frontend config. This resource can live independently of AKS and will not be deleted when the cluster is torn down.
Then, instead of letting Kubernetes create its own load balancer, you make your Service attach to this existing one using annotations:
apiVersion: v1
kind: Service
metadata:
name: my-service
annotations:
service.beta.kubernetes.io/azure-load-balancer-resource-group: <rg>
service.beta.kubernetes.io/azure-load-balancer-name: <lb-name>
spec:
type: LoadBalancer
loadBalancerIP: 10.0.0.50
ports:
- port: 80
selector:
app: my-app
Now the important behavior is that the IP is not being “reserved by Kubernetes”. It is reserved because the Azure Load Balancer frontend owns it, and Kubernetes is simply reusing that frontend. As long as you do not delete that load balancer resource, the IP will persist across cluster and Service recreation.
If you instead only do:
spec:
loadBalancerIP: 10.0.0.50
without pre-creating and owning that IP via an Azure resource, there is no guarantee. It will work only if the IP is free at that moment, and it can be lost or reassigned when the Service or cluster is deleted.
So the correct mental model in Azure VNet is that private IP persistence requires binding the IP to a durable Azure resource such as a Load Balancer frontend. Kubernetes alone cannot reserve or hold a private IP across its own lifecycle.
If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.
hth
Marcin
and “up-vote” wherever the information provided helps you, this can be beneficial to other community members.