I have a design and looking at 2 technologies (OpenZiti and Nebula) to see if this would work for connecting 20k IoT devices. Currently we use OpenVPN which works great but the setup is ok and not perfect. It gets the job done. This is where I am looking to see how OpenZiti can help with this setup. I have OpenZiti setup internally for our developers and works great! Have not had issues at all from developers. Nevertheless, I do have questions for this feat when it comes to our 20k IoT devices:
How does OpenZiti handle cellular data where there can be disconnects and reconnects after 12 hours to more than 2 days of disconnection/reconnection?
Does OpenZiti utilize NTP servers to keep in sync with the clients when communicating back to OpenZiti?
Does OpenZiti support DNS servers as well for easier sshing into these devices?
How does load balancing work? I know you have HA clustering which is still confusing to me in documentation. Tried setting this up myself and caused it to crash on several occasions.
on the clock question, ziti itself doesnt do ntp, keeping time in sync is on the device os. that matters more than you might expect because the certs and auth tokens are all time based, so a device that wakes up after two days with a drifted clock can fail auth until ntp catches up. for the disconnects, a device thats offline is just offline, and when it comes back the tunneler reauthenticates and builds a fresh session rather than needing the old connection kept alive. id test that sleep and wake cycle early, thats usually where iot fleets bite.
Hi @MacFee, sorry for the delay. Looks like we lost sight of this one.
Awesome! That's great to hear, thanks for sharing.
To your four questions...
Cellular data won't (to my knowledge) affect anything. When your device wakes up it'll reauthenticate to the overlay and things should be fine. You should definitely look into tuning the startup of the tunnel though. Look into -r|--refresh N set service polling interval in seconds (default 10) and set that much higher if you care about your bandwidth. There's tradeoffs to be had here though as that changes the interval affect how quickly (or not) updates are sent to the devices
OpenZiti has nothing to do with time as the other commenter mentions. That's an OS-level thing.
I'm not sure i understand the question. OpenZiti relies on the underlying OS for DNS to access routers and controllers if they are configured as FQDN entries. If they are IPs DNS would only be necessary when the tunneler dials an outbound connection. Whatever is in the host config is what is dialed by the tunneler. If it's a FQDN, the OS needs to be able to resolve the FQDN and the IP needs to be routable for a connection to work.
This is a loaded question and the only answer is 'it depends on what you mean'. For the REST API and ziti CLI access you should be able to put that behind a LB without issue but I expect that's not your question... For sdk clients, the sdk and the controller are expected to handle the various urls for controllers and devices connect to routers already in a LB way. I'm not sure if I'm understanding the questoin properly.
"Causing it to crash" -- seems odd. Are you saying the controllers panic or the tunnelers crash? Or both? Or some combination?
+1 to everything @TheLumberjack said on reconnects and time sync. On the disconnect question, a device's identity is an X.509 certificate, not a session, so a device offline for a few days just re-authenticates when it comes back. Certificate expiry is something to consider - the tunneler renews its cert automatically whenever it's online, so only a device unavailable for months would possibly need re-enrollment. Devices only ever dial outbound, so CGNAT and rotating carrier IPs are non-issues.
Some additional notes:
DNS for SSH into the devices: I read this not as "how does OpenZiti resolve names" but "how do I name 20k devices so I can ssh into the right one."
Intercepts give you naming without external DNS: an intercepting tunneler runs its own nameserver that resolves the hostnames of services that identity is authorized to reach, wildcards included (*.fleet.ziti style; the wildcard has to be the leftmost label). The general reference is the intercept.v1 config page: Tunneler config type intercept.v1 | NetFoundry Documentation
For SSH into 20k individual devices, don't have to model it as 20k services with 20k hostnames. You can create one SSH service that every device hosts with bindUsingEdgeIdentity: true - each device's service is then addressed by its identity name, and the client picks the device by setting the identity in its dial options. The zssh utility works this way: zssh user@device-identity-name reaches one specific device out of the fleet ( GitHub - openziti-test-kitchen/zssh: Ziti SSH · GitHub ).
Load balancing / HA: Three different layers get called "HA," which can add to any confusion:
HA for your services. Multiple identities can host the same service. Precedence (required / default / failed) plus health checks give you failover, and the terminator strategy (smartrouting by default, or weighted / random) decides how new sessions spread across the healthy hosts. failover keeps sessions on the same instance, horizontal scaling balances new sessions across instances. This is in the services overview: Ziti services | NetFoundry Documentation
Data plane. Scale by adding edge routers. Devices connect outbound to them and smart routing spreads traffic across paths. There's no load balancer to configure.
Control plane. Controller clustering. Which version were you on? Controller HA was beta for a long time and went GA in OpenZiti v2.0. Make sure you run v2.0+ with three controllers (odd number, Raft quorum). Docs: Controller clustering | NetFoundry Documentation