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

Tailscale client v1.48.x: Multiple instances of routes in headscale and --exit-node advertisement dns name not working #1539

Closed
PowershellScripter opened this issue Sep 5, 2023 · 12 comments
Labels
bug Something isn't working
Milestone

Comments

@PowershellScripter
Copy link

PowershellScripter commented Sep 5, 2023

NOTE** I opened a ticket with tailscale but they are saying they may not be able to help because im using headscale even though its with their client

What is the issue?
Latest changes to tailscale client are causing double instances of the same route to show.

v1.48.x
image

v1.46.1
image

Also, tailscale client not following machine name for --exit-node=, only IP:
v1.46.1-latest

image

Steps to reproduce
Mutliple route instances:
installed v1.48.1 client and setup auth devices. verified routes are duplicating. removed device and re-added multiple times and still same result. Verified routes show multiple times in the headscale server, both windows and linux displaying same result.
verified 1.48.0 also affected.

got ahold of v1.46.1 and tested mutliple times and not able to replicate the issue on v1.46.1 compared to v1.48.x

Exit-Node machine name usage:
tailscale clients show up as advertised exit nodes and I can use --exit-node=IP, but cannot use --exit-node=name; regardless of version

Tested everything in containers and straight VMs, all issues point to the client being the offensor

OS
Linux, Windows

Tailscale version
1.46.1, 1.48.0, 1.48.1

@PowershellScripter PowershellScripter added the bug Something isn't working label Sep 5, 2023
@winterheart
Copy link
Contributor

Got same issue, doubles routes on recent tailscale client, mine version is 1.50.1-ERR-BuildInfo

@zc-devs
Copy link

zc-devs commented Dec 3, 2023

Got the same issue.
Tailscale Linux client v1.54.0, Headscale v0.22.3. 1.46.1 works fine.
Android client 1.55.47 works as intended.


As a workaround we can rollout version 1.46.1, approve routes and then upgrade to the latest version ('1.54.0' at time of writing).


If we add another route TS_ROUTES=10.1.0.0/16, then it duplicates again:

$ headscale routes list
ID | Machine  | Prefix      | Advertised | Enabled | Primary
30 | vm1      | 10.1.0.0/16 | true       | false   | false
31 | vm1      | 10.1.0.0/16 | true       | false   | false

As a workaround we can enable one route and delete another:

$ headscale routes enable -r 30
$ headscale routes delete -r 31
$ headscale routes list
ID | Machine  | Prefix      | Advertised | Enabled | Primary
30 | vm1      | 10.1.0.0/16 | true       | true    | true

@kradalby
Copy link
Collaborator

kradalby commented Dec 9, 2023

Please try the code in the current main branch, there was some changes to this logic in #1564.

@kradalby kradalby added this to the v0.23.0 milestone Dec 10, 2023
@kradalby
Copy link
Collaborator

0.23.0-alpha2 addresses a series of issues with node synchronisation, online status and subnet routers, please test this release and report back if the issue still persist.

In addition, please verify that the issue also appears in tailscales control panel before posting issues on the client, most of the times, Headscale is the problem and we do not want to cause extra work for them unnecessarily.

@kradalby
Copy link
Collaborator

kradalby commented Jan 4, 2024

Does this issue happen with v0.22.3 and 1.48.1?

If it does, I will separate this from the v0.23.0 so we can address it later.

@PowershellScripter
Copy link
Author

Does this issue happen with v0.22.3 and 1.48.1?

If it does, I will separate this from the v0.23.0 so we can address it later.

Tried to test this but when using the alpha image, its now requiring a DERP private key?
Nothing has been changed with my headscale instance config from the old to the new, and I was not required to have a DERP private key previously. I also removed all headscale data to try a brand new instance and still same issue.

image

@kradalby
Copy link
Collaborator

If you have embedded DERP activated, you now need to give it a path for a private key:
https://github.com/juanfont/headscale/blob/main/CHANGELOG.md?plain=1#L32-L33

@zc-devs
Copy link

zc-devs commented Jan 26, 2024

Hi.
I've not been using Tail/Headscale for a while. So, seems this is my last check before decommissioning.

# tailscale version
1.58.2
  tailscale commit: 6a2a8457f0d62c775bfee3e350d2b34d85eda0f5
  other commit: 8c7d4563e46a1856053912ac067fc5036c2d2b3e
  go version: go1.21.5
image: ghcr.io/juanfont/headscale:0.23.0-alpha3
# tailscale up --advertise-exit-node --login-server=https://headscale.example.com

$ headscale nodes list
ID | Hostname         | Name             | MachineKey | NodeKey | User  | IP addresses                   | Ephemeral | Last seen          
| Expiration          | Connected | Expired
15 | ts               | ts               | [/qRA5]    | [Dd3II] | infra | 100.64.0.10, fd7a:115c:a1e0::a | false     | 2024-01-26 10:58:42
| 0001-01-01 00:00:00 | online    | no

$ headscale routes list
ID | Node     | Prefix      | Advertised | Enabled | Primary
50 | ts       | 0.0.0.0/0   | true       | false   | -
51 | ts       | ::/0        | true       | false   | -

Bug with duplicated routes doesn't reproduce anymore.


Off-topic. Headscale UI's Device View doesn't work on Headscale 0.23.0-alpha3.

GET https://headscale.example.com/api/v1/machine
Status 404

@kradalby
Copy link
Collaborator

Could you please test if this is still the case with https://github.com/juanfont/headscale/releases/tag/v0.23.0-alpha5 ?

@kradalby
Copy link
Collaborator

Could you please try the newest alpha (https://github.com/juanfont/headscale/releases/tag/v0.23.0-alpha6) and report back?

@kradalby
Copy link
Collaborator

Could you try the newest alpha (https://github.com/juanfont/headscale/releases/tag/v0.23.0-alpha10) and report back? If we do not hear back I will assume it has been resolved.

@kradalby
Copy link
Collaborator

I believe fixes in https://github.com/juanfont/headscale/releases/tag/v0.23.0-alpha12 should resolve this issue, let me now if not and we will reopen it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants