enFlowMeshCLI quick reference

CLI quick reference

This page is for the Linux FlowMesh client. Reading normal status usually doesn’t require root; changing settings requires root or an authorized operator. On OpenWrt, manage persistent settings through LuCI / UCI where possible.

View status

CommandPurpose
flowmesh statusShows the status of this device and its peers; exit code is 0 only when Running
flowmesh status --jsonShows machine-readable status, BackendState and Health
flowmesh ipShows this device’s mesh IP address
flowmesh ping --until-direct=false -c 3 100.64.0.2Probes the example peer, accepting direct or relayed responses
flowmesh whois 100.64.0.2Shows node information for the example address
flowmesh netcheckChecks the current relay list and NAT characteristics
flowmesh dns statusShows the DNS configuration in effect
flowmesh exit-node listLists available exit nodes
flowmesh serve statusShows background service sharing configuration
flowmesh metrics printPrints metrics in Prometheus format
flowmesh bugreportGenerates a local diagnostic file; doesn’t upload it automatically

Replace the example IP with the actual device address. Running means the engine is running; it doesn’t mean every peer and service port is reachable.

Connection and settings

CommandPurpose
sudo flowmesh downPauses the connection; keeps the login and settings
sudo flowmesh upTries to reconnect; if non-default settings exist, you must provide the full parameters as prompted
sudo flowmesh logoutContacts the control server to log out the node, and restores default settings
sudo flowmesh set --hostname=office-serverChanges the device name
sudo flowmesh set --accept-routes=trueAccepts approved subnet routes
sudo flowmesh set --accept-dns=falseStops automatically taking over system DNS
sudo flowmesh set --exit-node=Stops using an exit node
sudo flowmesh set --shields-up=trueBlocks incoming connections; keeps responses to connections this device initiates

Connecting for the first time requires the control server address and valid credentials. For a complete example, see the Linux installation guide.

set changes only the options you give it. up requires you to explicitly keep all existing non-default options; up --reset restores any options you don’t give to their defaults. Don’t treat the three as equivalent.

Further diagnostics

flowmesh debug prefs
sudo flowmesh debug paths

debug prefs is for checking the current settings, and debug paths shows peer paths and why they were chosen. Debug output may include information such as device addresses; review it before sharing.

Command success vs. service success

  • By default, flowmesh ping aims to establish a direct connection and may return a non-zero exit code when it only gets relayed responses.
  • For flowmesh dns query, check the response body; don’t rely on the exit code alone to decide whether resolution succeeded.
  • logout may fail when the control server is unreachable; in that case, don’t assume the server has revoked the device identity.
  • A successful set --advertise-routes means the local advertisement setting was submitted; an admin still needs to approve it and the accessing devices need to accept the routes.

For complete steps, see Subnet routes, Exit nodes and Troubleshooting.