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

Receiving/being assigned a local IPv4 address takes 15-20 seconds after joining a network. Changing system time after zerotier service has started on windows makes joining networks impossible. #2296

Open
MarcellVokk opened this issue May 18, 2024 · 6 comments

Comments

@MarcellVokk
Copy link

MarcellVokk commented May 18, 2024

After joining a network, it takes somewhere between 15 to 20 seconds for zerotier to assign a local ipv4 address to the connecting node. This is especialy frustrating because our application requires us to wait for this address before moving on to the next step. I'd apreciate if someone would look into this. Awesome project btw, keep up the good work!

@MarcellVokk
Copy link
Author

MarcellVokk commented May 18, 2024

This is a video demonstrating the issue. It apears to be consistent, it doesn't just hapen to me. My internet is very good, I doubt that would be the problem. As a naive user, I would expect the ip address to be assigned and be accessible immediately after joining a network has completed.

2024-05-18.18-02-43.mp4

@MarcellVokk
Copy link
Author

MarcellVokk commented May 19, 2024

Possibly related issue I discovered recently:

Changing system time on windows (in my case, I rolled the time back 1 hours) after the zerotier service is started makes joining networks impossible, the network status remains stuck on 'REQUESTING_CONFIGURATION'.

@MarcellVokk MarcellVokk changed the title Receiving/being assigned a local IPv4 address takes 15-20 seconds after joining a network. Receiving/being assigned a local IPv4 address takes 15-20 seconds after joining a network. Changing system time after zerotier service has started on windows makes joining networks impossible. May 19, 2024
@laduke
Copy link
Contributor

laduke commented May 20, 2024

Hello, it will always take some time to set up the interface. The client has to talk to something on the internet to get the information to do you. You will need some kind of wait/check in your scripts no matter what.

@MarcellVokk
Copy link
Author

Yeah of course, we already do implement a system that waits for the ip to be received and be configured, but I just wish it could be faster that's all... Would self-hosting my own controller help in this situation?

@laduke
Copy link
Contributor

laduke commented May 21, 2024

It depends on your connection to the controller. If the device is just coming online for the first time ever, it might take some time.
https://docs.zerotier.com/routertips#is-my-device-relaying

@MarcellVokk
Copy link
Author

By device, are you refering to the network device created when joining a room, or the users machine? The zerotier service is started as soon as the machine starts as far as I'm aware (but we make sure the service is started before we try to join any networks of course).

And about relaying, that's actualy a whole other thing.
After running a test on our playerbase (we have an application that basicaly uses zerotier to connect people so they can play LAN games online, sort of like hamachi or radmin) of roughly 1,000 players from all around the world, we have discovered that forcing the clients to use tcp relaying greatly reduced network latency (we host our own relays). With default configuration, the games were practicaly unplayable due to lag, with the relay, it's a lot better, altough compared to something like radmin, which is a similar VPN service, it's still significantly slower. Each game typicaly has 2-4 players, and every game gets its own zerotier network. (If there are any tips on how to reduce latency even further I'd be happy to hear them!)

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

2 participants