IP space is exhausted

5,651

Just came across this error myself. The documentation is here: https://cloud.google.com/kubernetes-engine/docs/how-to/alias-ips (search for "creation failed: IP space" on that page)

If you look at the table right below it. The "Pod Cidr" space you outlined above 10.129.11.0/24 is the same as "Recommended Pod address range" (right column) in the table. You must have set the "subnet size for nodes" (left column) for your vm to /24, which would reserve 252 ip's for your one vm.

Subnet size for nodes == Alias Ip Range in the their VM creation interface. When creating a VM, click "Management, security, disks, networking, sole tenancy" -> "Networking" tab -> "Show alias IP ranges".

Set the Alias IP range to /29 and now your VM will only request 4 internal ip's.

Share:
5,651

Related videos on Youtube

chux0519
Author by

chux0519

Updated on September 18, 2022

Comments

  • chux0519
    chux0519 over 1 year

    I have an issue about GKE/GCE.

    I'm using GKE under shared VPC(alias ip) and I have 4 machines of 2 node pools. When I try to add more node pools(because I want to have more type of machines), it keeps pending and I switched to the GCE/Instance groups tab, it says the IP space is exhausted. But I only have 4 machines in total, the ip range should be enough for 1024(10.129.16.0/22 + 10.130.16.0/22).

    Does each node pool will preserve some ip? Like 512 per pool maybe? So when I tried to create more pool, it fails.

    Here is a screenshot:

    [gce instance group error]

    enter image description here

    • Daniel t.
      Daniel t. over 5 years
      How many pods do you have in your cluster? With alias IPs in GKE, containers are assigned IPs from secondary range. Can you post output of gcloud compute networks describe us-east1-ai-pro-secondary-129-a73f3058f217db64 --region us-east1 --project common-prod as well.
    • chux0519
      chux0519 over 5 years
      @Danielt. thank you for your reply, I actually don't have permission, so I have to ask my admin to run this command and I will give feedback as soon as possible.
    • Sunny J.
      Sunny J. over 5 years
      What region was this in? Are you able to create GCE instances outside of GKE in that subnet? Are you hitting any network quotas? Are you able to reserve IPs in that range on their own? Is this still affecting you?
    • chux0519
      chux0519 over 5 years
      Thank you all guys. I just noticed that each node will preserve 256 IP, so in theory I can only have 4 node at the same time. But I can't find any doc about this. I will add a picture to prove this. So, the solution is I should contact to my leader and request more IPs.