{"record":{"id":"011e0b8be8fa5e34","repo":"vectordotdev/vector","slug":"ipv6-multicast-is-not-supported","errorCode":null,"errorMessage":"IPv6 multicast is not supported","messagePattern":"IPv6 multicast is not supported","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/sources/socket/udp.rs","lineNumber":195,"sourceCode":"        let listenfd = ListenFd::from_env();\n        let socket = try_bind_udp_socket(config.address, listenfd)\n            .await\n            .map_err(|error| {\n                emit!(SocketBindError {\n                    mode: SocketMode::Udp,\n                    error,\n                })\n            })?;\n\n        if !config.multicast_groups.is_empty() {\n            socket.set_multicast_loop_v4(true).unwrap();\n            let listen_addr = match config.address() {\n                SocketListenAddr::SocketAddr(SocketAddr::V4(addr)) => addr,\n                SocketListenAddr::SocketAddr(SocketAddr::V6(_)) => {\n                    // We could support Ipv6 multicast with the\n                    // https://doc.rust-lang.org/std/net/struct.UdpSocket.html#method.join_multicast_v6 method\n                    // and specifying the interface index as `0`, in order to bind all interfaces.\n                    unimplemented!(\"IPv6 multicast is not supported\")\n                }\n                SocketListenAddr::SystemdFd(_) => {\n                    unimplemented!(\"Multicast for systemd fd sockets is not supported\")\n                }\n            };\n            for group_addr in config.multicast_groups {\n                let interface = config.multicast_interface.unwrap_or(*listen_addr.ip());\n                socket\n                    .join_multicast_v4(group_addr, interface)\n                    .map_err(|error| {\n                        emit!(SocketMulticastGroupJoinError {\n                            error,\n                            group_addr,\n                            interface,\n                        })\n                    })?;\n                info!(message = \"Joined multicast group.\", group = %group_addr);\n            }","sourceCodeStart":177,"sourceCodeEnd":213,"githubUrl":"https://github.com/vectordotdev/vector/blob/bdb87aeaa4c4ff27c0ba643c1c77b21bf2ef4013/src/sources/socket/udp.rs#L177-L213","documentation":"The socket UDP source binds a listener and, when multicast_groups is configured, joins each group. IPv4 multicast is supported via join_multicast_v4, but an IPv6 listen address (SocketListenAddr::SocketAddr(SocketAddr::V6)) combined with multicast hits an explicit unimplemented!() panic: IPv6 multicast joining is not implemented in this source.","triggerScenarios":"Configuring a socket UDP source with an IPv6 listen address (e.g. \"[::]:514\" or \"[ff02::1]:514\") together with multicast_groups set; the source construction path reaches the SocketAddr::V6 arm and panics before binding.","commonSituations":"Deploying Vector for IPv6 multicast log collection (e.g. IPv6-only networks or multicast syslog); copying an IPv4 multicast config and swapping the address to IPv6; Kubernetes hosts advertising IPv6 addresses.","solutions":["Use an IPv4 listen address (e.g. \"0.0.0.0:514\") with IPv4 multicast groups instead.","Remove multicast_groups from the config if plain unicast UDP on IPv6 is all that is needed.","If IPv6 multicast is required, run a local relay that joins the group and forwards to Vector over unicast.","Contribute support using UdpSocket::join_multicast_v6 with interface index 0, as noted in the source comment."],"exampleFix":"// before (panics)\naddress = \"[::]:514\"\nmulticast_groups = [\"224.0.0.1\"]\n// after\naddress = \"0.0.0.0:514\"\nmulticast_groups = [\"224.0.0.1\"]","handlingStrategy":"validation","validationCode":"// Validate the socket UDP source config before deploy\nconst addr = config.address || \"\";\nif (config.multicast_groups?.length && addr.includes(\":\") && addr.startsWith(\"[\")) {\n  throw new Error(\"IPv6 listen address with multicast_groups is unsupported by the socket UDP source\");\n}","typeGuard":"function isIpv4ListenAddress(address) {\n  return !address.trim().startsWith(\"[\");\n}","tryCatchPattern":"// Catch source startup panics at the supervisor level\nmatch vector_run(config) {\n  Err(e) if e.to_string().contains(\"IPv6 multicast is not supported\") => {\n    fallback_to_unicast_or_ipv4(config);\n  }\n  other => other?,\n}","preventionTips":["Always pair multicast_groups with an IPv4 bind address in socket UDP configs.","Lint Vector configs in CI for IPv6 + multicast combinations.","Check the component docs' limitations section before enabling multicast.","Prefer an explicit unicast relay on IPv6 networks instead of native multicast."],"tags":["network","udp","ipv6","multicast","sockets"],"backgroundTag":"operation-not-supported","analyzedSha":"bdb87aeaa4c4ff27c0ba643c1c77b21bf2ef4013","analyzedAt":"2026-09-16T02:53:35.741Z","contentChangedAt":"2026-09-16T02:53:35.741Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}