Skip to content

Datapath Models: CCA practice questions

Cilium offers two ways to move pod traffic between nodes, plus special datapaths for some clouds, and the right choice depends on what the underlying network can do.

By Ibrahim Yesilay · Published · Updated

Independent community practice, not affiliated with or endorsed by CNCF or The Linux Foundation.

What Datapath Models covers in CCA

Cilium offers two ways to move pod traffic between nodes, plus special datapaths for some clouds, and the right choice depends on what the underlying network can do.

Encapsulation is what you get without any configuration. All nodes form a mesh of UDP tunnels, VXLAN by default on port 8472 or Geneve on port 6081 when tunnel-protocol is set to geneve, and the matching port must be open between nodes. The only requirement is that nodes can reach each other over IP, so the network does not need to know the pod CIDRs, nodes can span several routing domains, and new nodes join the mesh automatically. Tunnels also carry metadata: Cilium puts the source security identity in the header so the receiving node can skip one identity lookup. The cost is MTU. VXLAN adds 50 bytes to each packet, which lowers throughput; jumbo frames shrink the relative overhead. In the default overlay, traffic to a remote pod leaves through the cilium_vxlan interface.

Native routing is enabled with routing-mode: native and needs ipv4-native-routing-cidr, the range in which pod addresses are routable. Packets not addressed to a local endpoint are handed to the Linux routing table as if a local process had sent them, and Cilium turns on IP forwarding. The network must now route pod addresses. Either a router knows every pod CIDR and nodes use it as their default route, which is how cloud integrations work, or every node gets routes to every other node's pods. When all nodes share one layer 2 segment, auto-direct-node-routes: true installs those routes; across layer 3 boundaries a routing daemon such as BGP must distribute them. Per-endpoint routing, enable-endpoint-routes, routes traffic straight to each pod's veth instead of through cilium_host.

The AWS ENI datapath, selected with ipam: eni, gives pods addresses from Elastic Network Interfaces, so they are routable in the VPC without SNAT and can receive security groups. Its limits are the number of ENI addresses per instance type and EC2 API rate limits. On Google Cloud, gke.enabled=true switches on Kubernetes host scope IPAM, native routing and per-endpoint routes, using alias IP ranges.

Service traffic from outside the cluster has its own forwarding modes. By default NodePort and LoadBalancer traffic to a remote backend is SNAT-ed, so replies return through the receiving node. Setting loadBalancer.mode=dsr makes backends answer the client directly and keeps the client source address visible to policy, at the price of a lower advertised MTU; a hybrid mode uses DSR for TCP and SNAT for UDP.

Key points

  • Default is VXLAN encapsulation on 8472/UDP; Geneve uses 6081/UDP.
  • Native routing requires routing-mode: native plus ipv4-native-routing-cidr.
  • auto-direct-node-routes only works when nodes share one L2 network.
  • VXLAN costs 50 bytes of MTU per packet.
  • loadBalancer.mode=dsr preserves the client IP; SNAT is the default.

Three sample questions

12 CCA questions on Datapath Models, 12 with explanations. How practice works

Question 1

Which Cilium datapath mode does NOT use overlay encapsulation for pod-to-pod traffic across nodes?
  1. A.VXLAN
  2. B.Geneve
  3. C.Native routing
  4. D.IPsec

Correct answer: C

Native routing (or direct routing) does not use encapsulation for pod-to-pod traffic. Instead, it routes traffic directly between nodes using the underlying network infrastructure. VXLAN and Geneve are overlay encapsulation protocols, and IPsec provides encryption but is typically used with encapsulation.

Question 2

What happens if you set enable-endpoint-routes: true in Cilium configuration?
  1. A.Packets are encapsulated in VXLAN for pod-to-pod communication
  2. B.Direct routes to each endpoint are installed in the host routing table
  3. C.All traffic is forced through the Cilium proxy for L7 policy enforcement
  4. D.Network policies are enforced at the endpoint level instead of the node level

Correct answer: B

Setting enable-endpoint-routes: true in Cilium configuration causes direct routes to each endpoint to be installed in the host routing table. This can improve performance in some scenarios by bypassing the need for SNAT or tunneling.

Question 3

Cilium is installed without any routing options. Which routing mode does it use for traffic between nodes?
  1. A.Encapsulation with VXLAN tunnels
  2. B.Encapsulation with Geneve tunnels
  3. C.Native routing through the Linux routing table
  4. D.Native routing with BGP route distribution

Correct answer: A

With no configuration Cilium runs in encapsulation mode, the mode with the fewest network requirements; nodes form a tunnel mesh and the tunnel protocol defaults to vxlan. Why the other options are wrong. "Native routing through the Linux routing table": Native routing must be enabled with routing-mode: native. "Encapsulation with Geneve tunnels": Geneve is supported but VXLAN is the default protocol. "Native routing with BGP route distribution": BGP is optional and not the default.

Sources: CNCF CCA curriculum (CCA_Curriculum.pdf), Cilium docs: Routing, Cilium docs: System Requirements

Practice this topic

Focus mode keeps every question on Datapath Models until you leave it. 10 free guest answers, then a free account; no credit card.

Or open CCA practice across all topics.

Sources

The explanation above was checked against these official documents.

Frequently asked questions

When should I choose native routing over tunnels?

When the network can route pod CIDRs, for example in clouds with routable pod addresses or with BGP, and you want to avoid encapsulation overhead. Otherwise tunnels have the fewest requirements.