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

docker network create fails because of wrong subnet in /run/flannel/subnet.env #2052

Open
blinkinglight opened this issue Sep 13, 2024 · 0 comments

Comments

@blinkinglight
Copy link

Expected Behavior

Current Behavior

source /run/flannel/subnet.env
# docker network create --attachable=true --subnet=${FLANNEL_SUBNET} -o "com.docker.network.driver.mtu"=${FLANNEL_MTU} flannel
Error response from daemon: invalid network config:
invalid subnet 10.5.31.1/24: it should be 10.5.31.0/24

Possible Solution

Steps to Reproduce (for bugs)

  1. run etcd on public ip
  2. run 1st flanneld -etcd-endpoints [public ip of etcd] and run docker network create --attachable=true --subnet=${FLANNEL_SUBNET} -o "com.docker.network.driver.mtu"=${FLANNEL_MTU} flannel
  3. run on 2nd host flanneld -etcd-endpoints [public ip of etcd] and run docker network create --attachable=true --subnet=${FLANNEL_SUBNET} -o "com.docker.network.driver.mtu"=${FLANNEL_MTU} flannel <- this command now fails

Context

https://github.com/flannel-io/flannel/blob/master/Documentation/running.md

Your Environment

  • Flannel version: latest from context
  • Backend used (e.g. vxlan or udp): vxlan
  • Etcd version: latest docker from context
  • Kubernetes version (if used):
  • Operating System and version: ubuntu 22.04
  • Link to your project (optional):
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant