After successfully building the openziti/ziti
project on this armv6 device, a Raspi Zero v1.3, I was also able to run ziti-router
and successfully enrolled and verified that the expected certificates were generated.
However, when I attempted ziti-router run
I always get this error:
{
"error": "error connecting ctrl (context deadline exceeded)",
"file": "/home/kb/ziti/ziti-router/subcmd/run.go:119",
"func": "github.com/openziti/ziti/ziti-router/subcmd.run",
"level": "fatal",
"msg": "error starting",
"time": "2022-05-31T04:29:35.818Z"
}
Hypothesis: RESTY, the Go library, is configured with a max timeout for REST requests, and this device requires more time.
Here is the full startup log.
kb@kpizero1:~/ziti-router $ sudo ./ziti-router run ./config.yml --verbose |& tee /tmp/ziti-router-raspi-zero-fatal-startup.debug
{"file":"/home/kb/ziti/ziti/cmd/ziti/util/updates.go:48","func":"github.com/openziti/ziti/ziti/cmd/ziti/util.LogReleaseVersionCheck","level":"debug","msg":"this build of ziti-router is unreleased v0.0.0","time":"2022-05-31T04:29:34.210Z"}
{"arch":"arm","build-date":"2020-01-01 01:01:01","configFile":"./config.yml","file":"/home/kb/ziti/ziti-router/subcmd/run.go:75","func":"github.com/openziti/ziti/ziti-router/subcmd.run","go-version":"go1.18.2","level":"info","msg":"starting ziti-router","os":"linux","revision":"local","routerId":"MoXZ8iOp3Y","time":"2022-05-31T04:29:34.278Z","version":"v0.0.0"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/edge@v0.21.222/router/internal/edgerouter/config.go:139","func":"github.com/openziti/edge/router/internal/edgerouter.(*Config).LoadConfigFromMap","level":"warning","msg":"Invalid heartbeat interval [0] (min: 60, max: 10), setting to default [60]","time":"2022-05-31T04:29:34.288Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/forwarder/faulter.go:64","func":"github.com/openziti/fabric/router/forwarder.(*Faulter).run","level":"info","msg":"started","time":"2022-05-31T04:29:34.296Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:266","func":"github.com/openziti/fabric/router.(*Router).showOptions","level":"info","msg":"ctrl = {\"OutQueueSize\":4,\"MaxQueuedConnects\":1,\"MaxOutstandingConnects\":16,\"ConnectTimeout\":1000000000,\"DelayRxStart\":false,\"WriteTimeout\":0}","time":"2022-05-31T04:29:34.324Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:272","func":"github.com/openziti/fabric/router.(*Router).showOptions","level":"info","msg":"metrics = {\"ReportInterval\":60000000000,\"MessageQueueSize\":10}","time":"2022-05-31T04:29:34.361Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/edge@v0.21.222/router/internal/apiproxy/proxy.go:45","func":"github.com/openziti/edge/router/internal/apiproxy.Start","level":"debug","msg":"API Proxy disabled","time":"2022-05-31T04:29:34.321Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:471","func":"github.com/openziti/fabric/router.(*Router).initializeHealthChecks","level":"info","msg":"starting health check with ctrl ping initially after 15s, then every 30s, timing out after 15s","time":"2022-05-31T04:29:34.390Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/forwarder/scanner.go:58","func":"github.com/openziti/fabric/router/forwarder.(*Scanner).run","level":"info","msg":"started","time":"2022-05-31T04:29:34.296Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/xweb/registry.go:45","func":"github.com/openziti/fabric/xweb.WebHandlerFactoryRegistryImpl.Add","level":"debug","msg":"adding xweb factory with binding: health-checks","time":"2022-05-31T04:29:34.410Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:350","func":"github.com/openziti/fabric/router.(*Router).startXlinkDialers","level":"info","msg":"started Xlink dialer with binding [transport]","time":"2022-05-31T04:29:34.442Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/edge@v0.21.222/router/xgress_edge/factory.go:168","func":"github.com/openziti/edge/router/xgress_edge.(*Factory).CreateListener","level":"debug","msg":"xgress edge listener options: mtu=65536\nrandomDrops=false\ndrop1InN=100\ntxQueueSize=1\ntxPortalStartSize=16384\ntxPortalMaxSize=4194304\ntxPortalMinSize=16384\ntxPortalIncreaseThresh=224\ntxPortalIncreaseScale=1\ntxPortalRetxThresh=64\ntxPortalRetxScale=0.75\ntxPortalDupAckThresh=64\ntxPortalDupAckScale=0.9\nrxBufferSize=4194304\nretxStartMs=200\nretxScale=1.5\nretxAddMs=0\nmaxCloseWait=30s\ngetCircuitTimeout=30s\nlookupApiSessionTimeout=5s\nlookupSessionTimeout=5s\nchannel.outQueueSize=4\nchannel.connectTimeout=1s\nchannel.maxOutstandingConnects=16\nchannel.maxQueuedConnects=1\n","time":"2022-05-31T04:29:34.451Z"}
{"address":{},"file":"/home/kb/go/pkg/mod/github.com/openziti/edge@v0.21.222/router/xgress_edge/listener.go:69","func":"github.com/openziti/edge/router/xgress_edge.(*listener).Listen","level":"info","msg":"starting channel listener","time":"2022-05-31T04:29:34.465Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/metrics/pool_metrics.go:50","func":"github.com/openziti/fabric/metrics.GoroutinesPoolMetricsConfigF.func1.1","idleTime":10000000000,"level":"info","maxQueueSize":1,"maxWorkers":16,"minWorkers":1,"msg":"starting goroutine pool","poolType":"pool.listener.xgress_edge","time":"2022-05-31T04:29:34.494Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/edge@v0.21.222/router/xgress_edge/accept.go:108","func":"github.com/openziti/edge/router/xgress_edge.(*Acceptor).Run","level":"info","msg":"starting","time":"2022-05-31T04:29:34.516Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:399","func":"github.com/openziti/fabric/router.(*Router).startXgressListeners","level":"info","msg":"created xgress listener [edge] at [tls:0.0.0.0:443]","time":"2022-05-31T04:29:34.513Z"}
{"file":"/home/kb/go/pkg/mod/github.com/openziti/fabric@v0.17.137/router/router.go:399","func":"github.com/openziti/fabric/router.(*Router).startXgressListeners","level":"info","msg":"created xgress listener [tunnel] at []","time":"2022-05-31T04:29:34.523Z"}
{"_context":"tls:50a2078f-50d2-4ae0-ab87-0a7c2359ec96.production.netfoundry.io:80","file":"/home/kb/go/pkg/mod/github.com/openziti/channel@v0.18.37/reconnecting_dialer.go:68","func":"github.com/openziti/channel.(*reconnectingDialer).Create","level":"debug","msg":"started","time":"2022-05-31T04:29:34.536Z"}
{"_context":"tls:50a2078f-50d2-4ae0-ab87-0a7c2359ec96.production.netfoundry.io:80","file":"/home/kb/go/pkg/mod/github.com/openziti/channel@v0.18.37/reconnecting_dialer.go:77","func":"github.com/openziti/channel.(*reconnectingDialer).Create","level":"debug","msg":"exited","time":"2022-05-31T04:29:35.805Z"}
{"error":"error connecting ctrl (context deadline exceeded)","file":"/home/kb/ziti/ziti-router/subcmd/run.go:119","func":"github.com/openziti/ziti/ziti-router/subcmd.run","level":"fatal","msg":"error starting","time":"2022-05-31T04:29:35.818Z"}
Here is the config.yml
v: 3
identity:
cert: certs/client.cert.pem
server_cert: certs/server.cert.pem
key: certs/client.key.pem
ca: certs/intermediate-chain.pem
ctrl:
endpoint: tls:***redacted***.production.netfoundry.io:80
link:
dialers:
- binding: transport
healthChecks:
ctrlPingCheck:
interval: 30s
timeout: 15s
initialDelay: 15s
edge:
csr:
country: US
province: NC
locality: Charlotte
organization: NetFoundry
organizationalUnit: Ziti
sans:
ip:
- 127.0.0.1
- 192.168.0.128
listeners:
- binding: edge
address: tls:0.0.0.0:443
options:
advertise: 192.168.0.128:443
- binding: tunnel
options:
lanIf: wlan0
mode: host
web: []