[Bug] ipv4 range not used #754

Closed
opened 2025-12-29 02:23:27 +01:00 by adam · 2 comments
Owner

Originally created by @badsmoke on GitHub (Jul 29, 2024).

Is this a support request?

  • This is not a support request

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

this is set as the ip ranges

prefixes:
v6: fd7a:115c:a1e0:beef::/64
v4: 100.64.10.0/12

but the first node that logs on gets the

100.64.0.1

ipv6 works: fd7a:115c:a1e0:beef::1

Expected Behavior

the node ip should be in the set ip range, in this case something like 100.64.10.0/12

Steps To Reproduce

  1. fresh headscale installation 0.23-beta1
  2. user created
  3. preatuh key created for user
  4. node connected

Environment

- OS: Ubuntu 24.04 with docker
- Headscale version: 0.23-beta1
- Tailscale version: 1.68.1

Runtime environment

  • Headscale is behind a (reverse) proxy
  • Headscale runs in a container

Anything else?

No response

Originally created by @badsmoke on GitHub (Jul 29, 2024). ### Is this a support request? - [X] This is not a support request ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current Behavior this is set as the ip ranges prefixes: v6: fd7a:115c:a1e0:beef::/64 v4: 100.64.10.0/12 but the first node that logs on gets the 100.64.0.1 ipv6 works: fd7a:115c:a1e0:beef::1 ### Expected Behavior the node ip should be in the set ip range, in this case something like 100.64.10.0/12 ### Steps To Reproduce 1. fresh headscale installation 0.23-beta1 2. user created 3. preatuh key created for user 4. node connected ### Environment ```markdown - OS: Ubuntu 24.04 with docker - Headscale version: 0.23-beta1 - Tailscale version: 1.68.1 ``` ### Runtime environment - [X] Headscale is behind a (reverse) proxy - [X] Headscale runs in a container ### Anything else? _No response_
adam added the bug label 2025-12-29 02:23:27 +01:00
adam closed this issue 2025-12-29 02:23:28 +01:00
Author
Owner

@kradalby commented on GitHub (Jul 29, 2024):

100.64.10.0/12 is not the start of a network, it is just an address in 100.64.0.0/12, so the starter address would still be 100.64.0.1 from the beginning.

from ipcalc

$  ipcalc 10.64.10.0/12
Address:        10.64.10.0
Network:     10.64.0.0/12
Netmask:     255.240.0.0 = 12
Broadcast:   10.79.255.255

Address space:  Private Use
HostMin:     10.64.0.1
HostMax:     10.79.255.254
Hosts/Net:   1048574

You could make it narrower and achieve that as a starter address:

$ ipcalc 10.64.10.0/23
Network:        10.64.10.0/23
Netmask:     255.255.254.0 = 23
Broadcast:   10.64.11.255

Address space:  Private Use
HostMin:     10.64.10.1
HostMax:     10.64.11.254
Hosts/Net:   510
@kradalby commented on GitHub (Jul 29, 2024): `100.64.10.0/12` is not the start of a network, it is just an address in `100.64.0.0/12`, so the starter address would still be `100.64.0.1` from the beginning. from `ipcalc` ```bash $ ipcalc 10.64.10.0/12 Address: 10.64.10.0 Network: 10.64.0.0/12 Netmask: 255.240.0.0 = 12 Broadcast: 10.79.255.255 Address space: Private Use HostMin: 10.64.0.1 HostMax: 10.79.255.254 Hosts/Net: 1048574 ``` You could make it narrower and achieve that as a starter address: ```bash $ ipcalc 10.64.10.0/23 Network: 10.64.10.0/23 Netmask: 255.255.254.0 = 23 Broadcast: 10.64.11.255 Address space: Private Use HostMin: 10.64.10.1 HostMax: 10.64.11.254 Hosts/Net: 510 ```
Author
Owner

@badsmoke commented on GitHub (Jul 29, 2024):

embarrassing....thank you

@badsmoke commented on GitHub (Jul 29, 2024): embarrassing....thank you
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/headscale#754