{"record":{"id":"2c40f5bd602e1da8","repo":"netbirdio/netbird","slug":"unsupported-daemon-address-protocol-v","errorCode":null,"errorMessage":"unsupported daemon address protocol: %v","messagePattern":"unsupported daemon address protocol: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"client/cmd/service_socket.go","lineNumber":59,"sourceCode":"\tlistener, err := net.Listen(network, address)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\treturn &socketListener{Listener: listener, network: network, address: address}, nil\n}\n\nfunc parseListenAddress(addr string) (string, string, error) {\n\tnetwork, address, ok := strings.Cut(addr, \"://\")\n\tif !ok || network == \"\" || address == \"\" {\n\t\treturn \"\", \"\", fmt.Errorf(\"address must be in [unix|tcp|npipe]://[path|host:port|name] format: %q\", addr)\n\t}\n\n\tswitch network {\n\tcase \"unix\", \"tcp\", \"npipe\":\n\t\treturn network, address, nil\n\tdefault:\n\t\treturn \"\", \"\", fmt.Errorf(\"unsupported daemon address protocol: %v\", network)\n\t}\n}\n\nfunc removeStaleUnixSocket(path string) {\n\tstat, err := os.Lstat(path)\n\tif err != nil {\n\t\tif !os.IsNotExist(err) {\n\t\t\tlog.Debugf(\"stat socket file: %v\", err)\n\t\t}\n\t\treturn\n\t}\n\n\tif stat.Mode()&os.ModeSocket == 0 {\n\t\treturn\n\t}\n\n\tif !isStaleUnixSocket(path) {\n\t\treturn","sourceCodeStart":41,"sourceCodeEnd":77,"githubUrl":"https://github.com/netbirdio/netbird/blob/93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c/client/cmd/service_socket.go#L41-L77","documentation":"The --daemon-addr value carried a scheme, but it is not one of the three the daemon serves: unix, tcp, or npipe. The unsupported scheme is echoed back verbatim, and matching is case-sensitive.","triggerScenarios":"--daemon-addr http://localhost:8080, udp://..., grpc://..., or a casing/typo variant like TCP:// or unix2://.","commonSituations":"Confusing the daemon IPC socket with the management URL (https://...) and passing that to --daemon-addr; hand-written configs with uppercase schemes.","solutions":["Use exactly unix, tcp, or npipe as the scheme","Point management URLs at --management-url, not --daemon-addr","Fix casing and typos, e.g. tcp://127.0.0.1:8080","Reinstall the service with the corrected address"],"exampleFix":"# before\nnetbird service run --daemon-addr http://127.0.0.1:8080\n# after\nnetbird service run --daemon-addr tcp://127.0.0.1:8080","handlingStrategy":"validation","validationCode":"func supportedDaemonScheme(a string) bool {\n\tn, _, ok := strings.Cut(a, \"://\")\n\tif !ok {\n\t\treturn false\n\t}\n\tswitch n {\n\tcase \"unix\", \"tcp\", \"npipe\":\n\t\treturn true\n\t}\n\treturn false\n}","typeGuard":"func isKnownDaemonNetwork(a string) (string, bool) {\n\tn, _, ok := strings.Cut(a, \"://\")\n\tswitch n {\n\tcase \"unix\", \"tcp\", \"npipe\":\n\t\treturn n, ok\n\t}\n\treturn \"\", false\n}","tryCatchPattern":"network, address, err := parseListenAddress(addr)\nif err != nil {\n\tif strings.Contains(err.Error(), \"unsupported daemon address protocol\") {\n\t\t// fix the scheme; the value is well-formed but wrong\n\t}\n\treturn err\n}","preventionTips":["Reserve --daemon-addr for IPC schemes, send management URLs to --management-url","Use lowercase schemes","Lint config templates for the three allowed schemes"],"tags":["daemon","socket","configuration","cli","go"],"backgroundTag":null,"analyzedSha":"93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c","analyzedAt":"2026-08-16T03:09:19.136Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}