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

[Bug] Tailscale Client Fails to Resolve DNS #2209

Open
4 tasks done
W1BTR opened this issue Oct 23, 2024 · 3 comments
Open
4 tasks done

[Bug] Tailscale Client Fails to Resolve DNS #2209

W1BTR opened this issue Oct 23, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@W1BTR
Copy link

W1BTR commented Oct 23, 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

Seems more like a Tailscale bug, but the Tailscale client on Windows often fails to connect on startup. It's stuck on "connecting..." despite my machine having an active Ethernet connection.

In the logs, it says it's failing to resolve my headscale server's domain, but my dns servers (8.8.8.8 and 8.8.4.4) passed to me from my router work fine, and I can properly ping all common dns servers from cmd. I can also browse the internet just fine. I can also visit the domain for my headscale server just fine, and ping it properly.

2024-10-23T09:26:25.779-04:00: [v1] v1.76.3-t02acaa00e-g551df6588 peers: 37569296/7424000 1080/248 2128/4636 109014776/59720396
2024-10-23T09:26:26.190-04:00: control: trying bootstrapDNS("derp16d.tailscale.com", "2607:f740:17::475") for "headscale.mydomain.com" ...
2024-10-23T09:26:26.225-04:00: control: bootstrapDNS("derp16d.tailscale.com", "2607:f740:17::475") for "headscale.mydomain.com" error: Get "https://derp16d.tailscale.com/bootstrap-dns?q=headscale.mydomain.com": dial tcp [2607:f740:17::475]:443: connectex: A socket operation was attempted to an unreachable network.
2024-10-23T09:26:26.226-04:00: control: [v1] TryLogin: fetch control key: Get "https://headscale.mydomain.com/key?v=106": failed to resolve "headscale.mydomain.com": no DNS fallback candidates remain for "headscale.mydomain.com"
2024-10-23T09:26:26.226-04:00: control: [v1] sendStatus: authRoutine-report: state:authenticating
2024-10-23T09:26:26.226-04:00: control: authRoutine: [v1] backoff: 25712 msec
2024-10-23T09:26:26.226-04:00: Received error: fetch control key: Get "https://headscale.mydomain.com/key?v=106": failed to resolve "headscale.mydomain.com": no DNS fallback candidates remain for "headscale.mydomain.com"

Note that I changed to domain for privacy.

I can sometimes get it going by disconnecting and reconnecting my internet after restarting the Tailscale service.

Expected Behavior

I'd expect it to connect right away using the DNS from my host machine. It almost looks like it's trying to use the tailscale magic dns, but that wont work since it's not running yet.

Steps To Reproduce

Not sure what's unique about my environment, but all I can think of:

  1. Using ethernet with another secondary ethernet adapter and wifi enabled but not in use
  2. Start Windows

Environment

- OS: Windows 10
- Headscale version: 0.23.0
- Tailscale version: 1.76.3

Runtime environment

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

Anything else?

More logs: https://paste.yunohost.org/onebulayar.log

@W1BTR W1BTR added the bug Something isn't working label Oct 23, 2024
@hopleus
Copy link
Contributor

hopleus commented Oct 25, 2024

  1. What does HeadScale have to do with this if you say the problem is DNS resolution on your machine?
  2. Have you tried changing the configuration and connecting to HeadScale without using a domain, but directly by IP?

@W1BTR
Copy link
Author

W1BTR commented Oct 25, 2024

For clarification, DNS does work fine for everything other than the Tailscale app, even with the headscale server's domain.

I do believe it is a bug with the Tailscale app, but the docs for Headscale say to make sure and send all issues, even those with the Tailscale app to the Headscale Github, so I was following that. Every time I restart the Tailscale service, it proceeds to work.

Ill have to try using an IP, I didnt think of that. Will report back.

@nblock
Copy link
Collaborator

nblock commented Oct 26, 2024

[…] but the docs for Headscale say to make sure and send all issues, even those with the Tailscale app to the Headscale Github, so I was following that.

That should probably be fixed in the docs. Do you have a pointer to the specific section?

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

3 participants