Part 10: IPAM Deep Dive Quiz
Cilium 1.20.2 (stable, 2026-09-16) · 2026-10-15. Items marked [1.21 pre-release] come from v1.21.0-pre.3.
A CNI ADD allocates a Pod IP through
POST /ipam, then the CNI plugin crashes before the endpoint is created. When does the agent release that IP, without any restart?- A) After the 10 minute expiration timer set at allocation expires
- B) Only when the agent restarts and restores endpoints
- C) Immediately, because the REST connection closed
- D) After 180 seconds, the
--excess-ip-release-delaydefault
Show Answer
Answer: A) After the 10 minute expiration timer set at allocation expires
Explanation: The CNI plugin requests the allocation with the expiration flag set, so the agent starts a 10 minute timer (
defaults.IPAMExpiration). Endpoint creation stops the timer; if it never happens, the timer releases the IP. The 180 second value belongs to ENI excess-IP release in the operator.With the 1.20.2 Helm defaults for cluster-pool (
10.0.0.0/8, IPv4 mask size 24), how many nodes can receive a PodCIDR from that CIDR, and how many addresses does each node block hold?- A) 16,384 nodes, 1,024 addresses each
- B) 256 nodes, 65,536 addresses each
- C) 65,536 nodes, 256 addresses each
- D) 65,536 nodes, 254 usable addresses by definition of the mask
Show Answer
Answer: C) 65,536 nodes, 256 addresses each
Explanation: Nodes per pool CIDR is
2^(nodeMask - poolMask) = 2^(24 - 8) = 65,536, and each block holds2^(32 - 24) = 256addresses. Usable Pod IPs are fewer because the network/broadcast addresses and the router, health and ingress addresses are taken out of the block.What limits the gap between the pool prefix length and the node mask for an IPv6 cluster-pool in the 1.20.2 allocator?
- A) The gap must be at least 64 bits so each node gets a /64, regardless of pool size
- B) The gap must not exceed 16 bits (
clusterSubnetMaxDiff), because the allocator uses an uncompressed bitmap - C) There is no limit, only the node mask must not exceed /128, since the bitmap is compressed
- D) The gap must be exactly 8 bits, matching the IPv4 default
Show Answer
Answer: B) The gap must not exceed 16 bits (
clusterSubnetMaxDiff), because the allocator uses an uncompressed bitmapExplanation:
pkg/ipam/cidrsetrejects an IPv6 node mask more than 16 bits longer than the pool prefix (ErrCIDRSetSubNetTooBig). IPv4 only requires the node mask to be at most 32. The Helm defaultsfd00::/104with/120sit exactly at the 16-bit limit.In multi-pool IPAM, which order does Cilium use to choose the pool for a new Pod?
- A) CiliumPodIPPool selectors, then Pod annotation, then namespace annotation, then the
defaultpool unlessrequire-pool-matchis set - B) Always the
defaultpool; annotations and selectors only affect masquerading and LB IPAM - C) Namespace annotation, then Pod annotation, then
default; CiliumPodIPPool selectors are only used for LB IPAM - D) Pod annotation (
ipv4-pool/ipv6-poolbeforeip-pool), then namespace annotation, then CiliumPodIPPool selectors, thendefaultunlessrequire-pool-matchis set
Show Answer
Answer: D) Pod annotation (
ipv4-pool/ipv6-poolbeforeip-pool), then namespace annotation, then CiliumPodIPPool selectors, thendefaultunlessrequire-pool-matchis setExplanation: Pod annotations win over namespace annotations, which win over
podSelector/namespaceSelectormatches. With no match, the pool named byipam-default-ip-pool(defaultdefault) is used unless the Pod or namespace hasipam.cilium.io/require-pool-match: "true", which blocks allocation. Selection happens once at Pod creation.- A) CiliumPodIPPool selectors, then Pod annotation, then namespace annotation, then the
A Pod matches the selectors of two different CiliumPodIPPools for the same address family and has no pool annotation. What happens?
- A) Allocation fails with an error and an event, because exactly one pool per family must match
- B) The pool whose name sorts first alphabetically is used, and an event is logged
- C) The Pod receives one address from each matching pool and both are routed
- D) The
defaultpool is used as a tie-breaker and the selectors are ignored
Show Answer
Answer: A) Allocation fails with an error and an event, because exactly one pool per family must match
Explanation: Selector-based selection requires exactly one matching pool per family. Multiple matches produce an error (
multiple CiliumPodIPPools match pod ...) and the Pod stays inContainerCreating. Fix it by tightening the selectors or by annotating the Pod or namespace explicitly.Which statement about ENI prefix delegation in Cilium 1.20.2 is correct?
- A) It works on any EC2 instance type and hands out /24 prefixes, falling back to /28 when the subnet is full
- B) It works on any instance type and mixes /32 and /28 allocations freely on the same node, switching per Pod based on the subnet
- C) It requires
ipam.mode=multi-pooland aCiliumPodIPPoolwhose CIDRs list the prefixes to be delegated - D) Only on Nitro or bare-metal instances, it allocates /28 prefixes, is skipped on a node already holding secondary /32 IPs, and falls back to /32 when the subnet lacks prefixes
Show Answer
Answer: D) Only on Nitro or bare-metal instances, it allocates /28 prefixes, is skipped on a node already holding secondary /32 IPs, and falls back to /32 when the subnet lacks prefixes
Explanation: The operator checks for a Nitro hypervisor or bare metal, skips prefix mode on nodes that already have secondary IPs (no mixed mode), and on
InsufficientPrefixesInSubnetstops allocating prefixes on that node and usesAssignPrivateIpAddresses. The unit is a /28 (16 addresses, /80 for IPv6). ENI mode has no CiliumPodIPPool.How does the 1.20 ENI allocator hand EC2 interface state to the agent?
- A) The operator writes individual IPs to
spec.ipam.pooland the agent reports usage instatus.ipam.used, exactly as in 1.19, with no ENI status written - B) The agent calls the EC2 API directly with its own credentials and the operator only garbage-collects ENIs
- C) The operator writes ENIs to
status.eni.enis; the agent converts them to /32 and /28 CIDRs inspec.ipam.pools.allocated(pooldefault) and reports demand inspec.ipam.pools.requested - D) Each ENI becomes its own CiliumPodIPPool selected with the
ip-poolannotation, created by the operator
Show Answer
Answer: C) The operator writes ENIs to
status.eni.enis; the agent converts them to /32 and /28 CIDRs inspec.ipam.pools.allocated(pooldefault) and reports demand inspec.ipam.pools.requestedExplanation: 1.20 moved ENI to the multi-pool allocator: only the operator calls EC2, the agent derives allocated CIDRs from the ENI inventory and writes requested capacity back. The
spec.ipam.pool/status.ipam.usedmodel is the 1.19 and 1.18 CRD allocator. ENI mode has no CiliumPodIPPool orip-poolannotation.- A) The operator writes individual IPs to
[1.21 pre-release] You currently pass
--aws-use-primary-addressdirectly to the Cilium operator. What must you do before moving to 1.21?- A) Nothing; the flag is only deprecated and still works as an operator flag in 1.21
- B) Remove it and set
eni.nodeSpec.usePrimaryAddress=true(agent flag--eni-use-primary-address) - C) Set it on the
CiliumPodIPPoolfor the default pool underspec.ipv4.pool[] - D) Move it to the agent as
--aws-use-primary-address, keeping the same name
Show Answer
Answer: B) Remove it and set
eni.nodeSpec.usePrimaryAddress=true(agent flag--eni-use-primary-address)Explanation: The operator flag is removed in 1.21 so that the per-node
CiliumNode.spec.eni.use-primary-addressis the single source of truth. Helm users are unaffected because the chart only ever wired the agent-side value. This is a pre-release change (v1.21.0-pre.3).[1.21 pre-release] What is
spec.ipv4.pool[].reservedRangesincilium.io/v2CiliumPodIPPoolused for?- A) To exclude addresses from every node block so they can be handed out as static Service IPs by LB IPAM pools
- B) To make
maskSizemutable on a live pool without recreating existing node blocks - C) To reserve addresses for the router, health and ingress endpoints on every node block
- D) To keep an old CIDR in
cidrsso existing node blocks keep working while no new blocks are carved from it, enabling gradual migration to a new CIDR
Show Answer
Answer: D) To keep an old CIDR in
cidrsso existing node blocks keep working while no new blocks are carved from it, enabling gradual migration to a new CIDRExplanation: Reserving the whole old CIDR means Cilium preserves existing allocations but allocates new PodCIDR blocks only from the other CIDRs. After all node groups have migrated, the old CIDR and its
poolentry are removed. Eachpool[].cidrmust be one ofcidrs;maskSizestays immutable.Two
CiliumLoadBalancerIPPoolresources contain overlapping blocks. What does LB IPAM do?
- A) It marks the later pool as Conflicting (
cilium.io/PoolConflict) and allocates nothing from it - B) It rejects the second pool at admission through a validating webhook
- C) It merges them into one pool and allocates from the union of their blocks
- D) It splits the overlapping range evenly between the two pools by Service count
Show Answer
Answer: A) It marks the later pool as Conflicting (cilium.io/PoolConflict) and allocates nothing from it
Explanation: LB IPAM does not merge or reject overlapping pools. The later one is flagged Conflicting, shown in the Conflicting print column and the lbipam_conflicting_pools metric (the exact runtime prefix, cilium_ or cilium_operator_, is unverified), and no allocation happens from it. Editing a live pool can also reassign existing Service IPs, so prefer adding a pool or setting disabled: true.