Cilium ENI Mode + Gateway API Deep-dive Configuration
This document is a deep-dive guide for the Gateway API Adoption Guide. It provides a practical guide for combining Cilium ENI mode with Gateway API for high-performance networking.
Cilium ENI mode is a high-performance networking solution that directly utilizes AWS Elastic Network Interfaces to assign VPC IP addresses to pods. Combined with Gateway API, it achieves both standardized L7 routing and eBPF-based ultra-low latency processing.
1. What is Cilium ENI Mode?โ
Cilium ENI mode directly uses AWS ENI to assign VPC IP addresses to pods. Key features:
- AWS ENI Direct Use: Each pod receives a real VPC IP, fully integrating with AWS networking (Security Groups, NACLs, VPC Flow Logs)
- eBPF-based High-Performance Networking: 10x+ performance improvement over iptables with minimal CPU overhead
- Native Routing: No overlay encapsulation (VXLAN/Geneve), using VPC routing tables directly
2. Architecture Overviewโ
NLB (L4) โ eBPF TPROXY (transparent proxy) โ Cilium Envoy (L7 Gateway) โ Backend Pods (ENI IPs)
Key Componentsโ
- NLB: Managed L4 load balancer, microsecond latency
- eBPF TPROXY: XDP-level packet interception, lock-free per-CPU processing
- Cilium Envoy: L7 processing, HTTPRoute/TLSRoute implementation
- Cilium Operator: ENI lifecycle management, IP pool management
- Cilium Agent (DaemonSet): eBPF program management, CNI plugin
- Hubble: Real-time network flow observability, L7 protocol visibility
3. Prerequisitesโ
4. Installation Flowโ
For new clusters: disable VPC CNI โ install Gateway API CRDs โ install Cilium via Helm โ create Gateway resources.
For existing clusters: downtime required (5-10 min) for VPC CNI removal and Cilium installation.
5. Gateway API Resource Configurationโ
Standard HTTPRoute, traffic splitting (canary), header-based routing, URL rewrite, and role separation patterns are all supported identically to other Gateway API implementations.
6. Performance Optimizationโ
- NLB + Cilium Envoy: ~3.5ms total vs ~15ms with ALB+NGINX
- Prefix Delegation: 16x fewer ENI attach operations
- BPF tuning: Pre-allocated maps, Maglev load balancing
- XDP acceleration: 10x packet filtering, 80% CPU reduction for DDoS
| ์ธ์คํด์ค ํ์ | vCPU | ๋ฉ๋ชจ๋ฆฌ | ๋คํธ์ํฌ ๋์ญํญ | ENI | IP/ENI | ๊ถ์ฅ ์ฉ๋ |
|---|---|---|---|---|---|---|
m7g.xlarge | 4 | 16GB | ์ต๋ 12.5Gbps | 4 | 15 | ๋ฒ์ฉ, ๋น์ฉ ํจ์จ |
c7gn.xlarge | 4 | 8GB | ์ต๋ 30Gbps | 4 | 15 | ๊ณ ์ฑ๋ฅ ๊ฒ์ดํธ์จ์ด |
m7g.2xlarge | 8 | 32GB | ์ต๋ 15Gbps | 4 | 15 | ์ค๊ท๋ชจ ์ํฌ๋ก๋ |
c7gn.4xlarge | 16 | 32GB | ์ต๋ 50Gbps | 8 | 30 | ๋๊ท๋ชจ ํธ๋ํฝ |
m7g.8xlarge | 32 | 128GB | 25Gbps | 8 | 30 | ๊ณ ๋ฐ๋ ํ๋ |
c7gn.12xlarge | 48 | 96GB | 100Gbps | 15 | 50 | ์ด๊ณ ์ฑ๋ฅ |
7. Operations & Observabilityโ
Hubble provides real-time flow observation, service maps, L7 protocol visibility (HTTP, gRPC, Kafka, DNS), and Prometheus metric export.
8. BGP Control Plane v2โ
For hybrid environments needing on-premises to EKS traffic routing via BGP. Not required when using NLB in pure AWS environments.
9. Hybrid Nodes Architecture and AI/ML Workloadsโ
For EKS Hybrid Nodes combining cloud and on-premises GPU nodes, Cilium serves as a unified CNI. Recommended architecture: Cilium CNI + Cilium Gateway API + llm-d for minimized component count with optimal performance.