github.com/cilium/cilium@v1.16.2/Documentation/network/multicast.rst (about) 1 .. only:: not (epub or latex or html) 2 3 WARNING: You are looking at unreleased Cilium documentation. 4 Please use the official rendered version released here: 5 https://docs.cilium.io 6 7 .. _enable_multicast: 8 9 ********************************** 10 Multicast Support in Cilium (Beta) 11 ********************************** 12 13 .. include:: ../beta.rst 14 15 The multicast capability allows user application to distribute data feeds to 16 multiple consumers in the Kubernetes cluster. 17 The container network multicast transmission technology based on eBPF focuses on solving 18 the problem of efficient multicast transmission in the container network and provides 19 support for multiple multicast protocols. 20 21 This document explains how to enable multicast support and configure Cilium and CiliumNode 22 with multicast group IP addresses and subscribers. 23 24 Prerequisites 25 ============= 26 27 This guide assumes that Cilium has been correctly installed in your 28 Kubernetes cluster. Please see :ref:`k8s_quick_install` for more 29 information. If unsure, run ``cilium status`` and validate that Cilium is up 30 and running. This guide also assumes Cilium is configured with vxlan mode, 31 which is required when using multicast capability. 32 33 Multicast only works on kernels >= 5.10 for AMD64, and on kernels >= 6.0 for AArch64. 34 35 36 Enable Multicast Feature 37 ======================== 38 39 Multicast support can be enabled by updating ``cilium-config`` ConfigMap as following: 40 41 .. code-block:: shell-session 42 43 $ cilium config set multicast-enabled true 44 ✨ Patching ConfigMap cilium-config with multicast-enabled=true... 45 ♻️ Restarted Cilium pods 46 47 48 Configure Multicast and Subscriber IPs 49 ====================================== 50 51 To use multicast with Cilium, we need to configure multicast group IP addresses and 52 subscriber list based on the application requirements. This is done by running 53 ``cilium-dbg`` command in each ``cilium-agent`` pod. 54 Then, multicast subscriber pods can send out IGMP join and multicast 55 sender pods can start sending multicast stream. 56 57 As an example, the following guide uses ``239.255.0.1`` multicast group address. 58 59 Get all CiliumNode IP addresses to be set as multicast subscribers: 60 61 .. code-block:: shell-session 62 63 $ kubectl get ciliumnodes.cilium.io 64 NAME CILIUMINTERNALIP INTERNALIP AGE 65 kind-control-plane 10.244.0.72 172.19.0.2 16m 66 kind-worker 10.244.1.86 172.19.0.3 16m 67 68 To set multicast IP address, enable multicast BPF maps in each ``cilium-agent``: 69 70 .. code-block:: shell-session 71 72 ### add multicast IP address 73 $ cilium-dbg bpf multicast group add 239.255.0.1 74 75 ### check multicast IP address 76 $ cilium-dbg bpf multicast group list 77 Group Address 78 239.255.0.1 79 80 Then, set the subscriber IP addresses in each ``cilium-agent``: 81 82 .. code-block:: shell-session 83 84 ### cilium-agent on kind-control-plane 85 $ cilium-dbg bpf multicast subscriber add 239.255.0.1 10.244.1.86 86 $ cilium-dbg bpf multicast subscriber list all 87 Group Subscriber Type 88 239.255.0.1 10.244.1.86 Remote Node 89 90 ### cilium-agent on kind-worker 91 $ cilium-dbg bpf multicast subscriber add 239.255.0.1 10.244.0.72 92 93 .. note:: 94 95 This multicast subscriber IP addresses are different CiliumNode IP addresses than your own one. 96 97 When you want to remove multicast IP addresses and subscriber list, run the following commands in the ``cilium-agent``. 98 99 .. code-block:: shell-session 100 101 $ cilium-dbg bpf multicast group delete 239.255.0.1 102 $ cilium-dbg bpf multicast subscriber delete 239.255.0.1 10.244.0.72 103 104 105 Limitations 106 =========== 107 108 * The operation needs to be done on each CiliumNode that uses multicast feature. 109 * This feature does not work with ipsec encryption between Cilium managed pod.