Direct connections and relays
FlowMesh looks for a working connection path between two devices. When network conditions allow, they can connect directly; when they can’t, a relay is used. A response over a relay path does not mean something is wrong with the mesh network.
Check the current path
Replace the example address with the peer’s actual mesh IP address:
flowmesh ping --until-direct=false -c 3 100.64.0.2The responses show the path and latency. A direct connection usually shows the peer’s network endpoint; a relayed response may show DERP(...). Don’t judge whether a connection is direct from the latency figure alone.
By default, flowmesh ping tries to establish a direct connection. When it only gets relayed responses, it may return a non-zero exit code and report direct connection not established; this is different from “no response at all”. When you only want to check reachability, use --until-direct=false as above.
Mesh network relay modes
The mesh network’s relay mode is pushed from the console. Sign in to the Wanflow Console and open the target mesh network. On the 设置 (Settings) tab, under 网络配置 (Network configuration), you can see 组网模式 (Mesh mode), and under 中继节点 (Relay nodes) you can see the relay regions the mesh network uses. relayMode in the Linux status JSON shows the current mode; it may be empty if mesh network information hasn’t been received yet.
| Mode | Behavior |
|---|---|
auto | Tries a direct connection and uses a relay when needed |
prefer | Doesn’t initiate direct connection probes, but may still respond to probes from the peer, so devices on the same LAN may still connect directly |
strict | Direct connections are forbidden; communicates only over allowed relay paths |
If your business requires traffic to always go through a relay, choose strict mode; “prefer relay” is not a guarantee that direct connections are blocked.
Check network conditions
flowmesh netcheckThis command checks latency and NAT characteristics against the relay list pushed by the control server. If the client hasn’t received the relay list yet, it refuses to run the check rather than falling back to a built-in default relay list.
When a connection is slow, first confirm the actual path, then check upstream bandwidth, packet loss on both ends, and relay latency. Application throughput is also affected by device CPU, the service itself and link load, so you can’t estimate download speed from node probe latency alone.
To dig further, use sudo flowmesh debug paths on Linux to see why a path was chosen, and refer to Troubleshooting.