{"record":{"id":"5defb1c35b366395","repo":"netbirdio/netbird","slug":"sync-response-persistence-is-disabled","errorCode":null,"errorMessage":"sync response persistence is disabled","messagePattern":"sync response persistence is disabled","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"client/internal/engine.go","lineNumber":2419,"sourceCode":"\t\tif err := e.syncStore.Clear(); err != nil {\n\t\t\tlog.Warnf(\"failed to clear persisted sync response: %v\", err)\n\t\t}\n\t\te.syncStore = nil\n\t\treturn\n\t}\n\n\te.syncStore = syncstore.New(e.syncStoreDir)\n}\n\n// GetLatestSyncResponse returns the stored sync response if persistence is enabled\nfunc (e *Engine) GetLatestSyncResponse() (*mgmProto.SyncResponse, error) {\n\t// Hold the lock for the whole Get so the store cannot be cleared\n\t// (disabled / engine close) mid-call.\n\te.syncRespMux.RLock()\n\tdefer e.syncRespMux.RUnlock()\n\n\tif e.syncStore == nil {\n\t\treturn nil, errors.New(\"sync response persistence is disabled\")\n\t}\n\n\t//nolint:nilnil\n\treturn e.syncStore.Get()\n}\n\n// GetWgAddr returns the wireguard address\nfunc (e *Engine) GetWgAddr() netip.Addr {\n\tif e.wgInterface == nil {\n\t\treturn netip.Addr{}\n\t}\n\treturn e.wgInterface.Address().IP\n}\n\n// GetWgV6Addr returns the IPv6 overlay address of the WireGuard interface.\nfunc (e *Engine) GetWgV6Addr() netip.Addr {\n\tif e.wgInterface == nil {\n\t\treturn netip.Addr{}","sourceCodeStart":2401,"sourceCodeEnd":2437,"githubUrl":"https://github.com/netbirdio/netbird/blob/93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c/client/internal/engine.go#L2401-L2437","documentation":"handleClientStatus (proxy/internal/debug/handler.go:431) got a live client but client.Status() returned an error, and the handler answers 500 with the error text appended. Status() aggregates the embedded client's internal state, so a non-nil error means the client could not produce its status — typically because its management stream/sync machinery is in a failed state.","triggerScenarios":"Calling the status debug endpoint while the per-account client's connection to management is broken (gRPC stream down, login expired) or its internal collectors returned an error; the client exists in the registry but is unhealthy.","commonSituations":"Inspecting a client mid-reconnect; management temporarily unreachable so status collection fails; client shutting down concurrently with the status call.","solutions":["Read the appended err.Error() in the response body — it states whether the failure is the management connection or internal state.","Check the clients overview / health endpoints to see if the account's client is connected at all.","Retry once the client re-establishes its management sync; if stuck, restart the proxy or the affected account's client."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"// Status collection can fail transiently while the client reconnects.\nfor i := 0; i < 3; i++ {\n    resp, err := http.Get(statusURL)\n    if err == nil && resp.StatusCode == http.StatusOK {\n        break\n    }\n    time.Sleep(2 * time.Second)\n}","preventionTips":["Correlate status 500s with the client's connected state from the overview page.","Prefer the health/readiness endpoints for alerting; use per-client status for debugging.","Retry after reconnect windows before escalating."],"tags":["proxy","debug","grpc","observability"],"backgroundTag":null,"analyzedSha":"93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c","analyzedAt":"2026-08-16T03:09:19.136Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}