Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Internal error occurred: failed to allocate a serviceIP: range is ful #818

Open
1 of 5 tasks
alexellis opened this issue Oct 19, 2023 · 6 comments
Open
1 of 5 tasks
Labels
kind/bug Categorizes issue or PR as related to a bug.
Milestone

Comments

@alexellis
Copy link

How to use it?

  • kwok
  • kwokctl --runtime=docker (default runtime)
  • kwokctl --runtime=binary
  • kwokctl --runtime=nerdctl
  • kwokctl --runtime=kind

What happened?

I created a cluster with 220 nodes, then ran an operator that creates a Deployment and a Service per CR, and created 5000 different CRs across 4 namespaces, totalling 20,000 Deployments and Services.

Internal error occurred: failed to allocate a serviceIP: range is full

This happend with only ~ 220-250 services in the whole cluster.

What did you expect to happen?

As per normal K8s, the service IPs are allocated normally. 5k per namespace is well within limits.

How can we reproduce it (as minimally and precisely as possible)?

Write a bash for loop to create > 255 services.

Anything else we need to know?

No response

Kwok version

$ kwok --version
kwok version v0.4.0 go1.20.7 (linux/amd64)

$ kwokctl --version
kwokctl version v0.4.0 go1.20.7 (linux/amd64)

OS version

```console Linux bq 5.15.0-86-generic #96~20.04.1-Ubuntu SMP Thu Sep 21 13:23:37 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

NAME="Ubuntu"
VERSION="20.04.6 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.6 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

</details>
@alexellis alexellis added the kind/bug Categorizes issue or PR as related to a bug. label Oct 19, 2023
@wzshiming
Copy link
Member

wzshiming commented Oct 20, 2023

As this error message indicates the ip is exhausted, you can try using MultiCIDRServiceAllocator to allow more ips to be used, or to modify --service-cluster-ip-range=, need to recreate cluster.

# ~/.kwok/kwok.yaml

kind: KwokctlConfiguration
apiVersion: config.kwok.x-k8s.io/v1alpha1
componentsPatches:
- name: kube-apiserver
  extraArgs:
  - key: service-cluster-ip-range
    value: "10.96.0.0/12"
- name: kube-controller-manager
  extraArgs:
  - key: service-cluster-ip-range
    value: "10.96.0.0/12"

@alexellis
Copy link
Author

Thanks for the reply. Is it possible to use a single /24 CIDR instead with a 192.168.x.x range?

@wzshiming
Copy link
Member

wzshiming commented Oct 23, 2023

As the code of apiserver seems impossible.

@wzshiming wzshiming added this to the v1.0 milestone Dec 18, 2023
@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue as fresh with /remove-lifecycle stale
  • Close this issue with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Mar 17, 2024
@wzshiming
Copy link
Member

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Mar 18, 2024
@Vivekgaddigi
Copy link

any update on this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
Status: 🆕 New
Development

No branches or pull requests

5 participants