I was trying to create a GKE cluster and it failed with the error
GKE cluster creation fails because the network "default" does not have available private IP space in 10.0.0.0/8 to reserve a /14 block
I'm assuming this is because I already have a bunch of clusters running and each cluster consumes some amount of address space. But I don't understand CIDR notation well enough to understand how this limits the number of clusters I can create simultaneously.
Could some please explain this?
There are 64 /14 ranges in the 10.0.0.0/8 IP space. But you can't actually create that many clusters because the VMs themselves use up a /16 range that cannot be reused by a cluster because the IPs for the pods would overlap with IPs assigned to VMs. You also need a contiguous /14 block (262k IP addresses) for your cluster.
If you don't have an available /14 range in your network, you can ask for a smaller range to be assigned for your cluster (using the --cluster-ipv4-cidr
flag) with the caveat that you must provide the explicit block (e.g. 10.0.0.0/16) rather than letting GKE choose one for you.