For each additional CNI type, a “NetworkAttachmentDefinition” is generated (see the Multus docs for more information on this).Ĭreated pods can invoke this annotation to easily add new interfaces, e.g.: apiVersion: v1 kind: Pod metadata: name: ubuntu annotations: k8s.v1./networks: flannel, flannel spec: containers: - name: ubuntu image: ubuntu command: The mechanism Multus uses is to create a new Custom Resource Definition (CRD) to describe the additional interface mechanism. The initial, default interface is still used as normal, but additional interfaces are now available when specified during Pod creation. It is really a CNI manager, which allows the creation of multiple interfaces, which can then be controlled by the same or different CNI plugins. Although it is disguised as a CNI plugin, Multus doesn’t really do anything more than load other CNI plugins. This is the issue Multus was designed to solve. There are plenty of cases where it may be desirable to have additional network capability: ![]() But, without Multus, you are limited to using one, and they in turn are all limited to a single interface. ![]() There are many varied and useful CNI plugins to address all sorts of usage scenarios. By comparison, another popular CNI is Calico, which instead uses Border Gateway Protocol (BGP) to route traffic between hosts. Each node allocates IP addresses within a subnet for local communication, and Flannel takes care of encapsulating traffic between nodes. ![]() Flannel configures a layer 3 IPv4 overlay network. The CNI plugin is called when a container is created, creates and adds an interface, connects the interface to the host network via a bridge and then configures the interface, usually with an additional IP Address Management component to supply an address and routes.Ī typical (and often the default) example of a CNI plugin is Flannel. ![]() The whole purpose of CNI is to have a framework for dynamically allocating network resources over the lifecycle of a container. Kubernetes itself manages this interface using plugins.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |