{"id":5114,"date":"2021-12-14T16:20:00","date_gmt":"2021-12-15T00:20:00","guid":{"rendered":"https:\/\/www.xh86.me\/?p=5114"},"modified":"2021-12-18T17:58:28","modified_gmt":"2021-12-19T01:58:28","slug":"cilium-1-11-%e5%8f%91%e5%b8%83%ef%bc%8c%e5%b8%a6%e6%9d%a5%e5%86%85%e6%a0%b8%e7%ba%a7%e6%9c%8d%e5%8a%a1%e7%bd%91%e6%a0%bc%e3%80%81%e6%8b%93%e6%89%91%e6%84%9f%e7%9f%a5%e8%b7%af%e7%94%b1","status":"publish","type":"post","link":"https:\/\/www.xh86.me\/?p=5114","title":{"rendered":"Cilium 1.11 \u53d1\u5e03\uff0c\u5e26\u6765\u5185\u6838\u7ea7\u670d\u52a1\u7f51\u683c\u3001\u62d3\u6251\u611f\u77e5\u8def\u7531&#8230;."},"content":{"rendered":"<div class=\"wxsyncmain\">\n<section style=\"color: black; line-height: 1.6; letter-spacing: 0px; word-break: break-word; text-align: left; font-size: 15px; font-family: Arial;\" data-tool=\"mdnice\u7f16\u8f91\u5668\" data-website=\"https:\/\/www.mdnice.com\" data-mpa-powered-by=\"yiban.io\"><\/section>\n<section style=\"color: black; line-height: 1.6; letter-spacing: 0px; word-break: break-word; text-align: left; font-size: 15px; font-family: Arial;\" data-tool=\"mdnice\u7f16\u8f91\u5668\" data-website=\"https:\/\/www.mdnice.com\">\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-bd74b2a236cf5b4f1df5321aca9301db.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-bd74b2a236cf5b4f1df5321aca9301db.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.4736394557823129\" data-type=\"png\" data-w=\"1176\" \/><\/div><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u9879\u76ee\u5df2\u9010\u6e10\u6210\u4e3a\u4e07\u4f17\u77a9\u76ee\u4e4b\u661f\uff0c\u6211\u4eec\u5f88\u81ea\u8c6a\u80fd\u591f\u6210\u4e3a\u8be5\u9879\u76ee\u7684\u6838\u5fc3\u4eba\u5458\u3002\u51e0\u5929\u524d\uff0c\u6211\u4eec\u53d1\u5e03\u4e86\u5177\u6709\u8bf8\u591a\u65b0\u529f\u80fd\u7684 Cilium 1.11 \u7248\u672c\uff0c\u8fd9\u662f\u4e00\u4e2a\u4ee4\u4eba\u5174\u594b\u7684\u7248\u672c\u3002\u8bf8\u591a\u65b0\u529f\u80fd\u4e2d\u4e5f\u5305\u62ec\u4e86\u4e07\u4f17\u671f\u5f85\u7684 Cilium Service Mesh \u7684 Beta \u7248\u672c\u3002\u5728\u672c\u7bc7\u6587\u7ae0\u4e2d\uff0c\u6211\u4eec\u5c06\u6df1\u5165\u63a2\u8ba8\u5176\u4e2d\u7684\u90e8\u5206\u65b0\u529f\u80fd\u3002<\/p>\n<section class=\"mp_profile_iframe_wrp\"><\/section>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Service Mesh \u6d4b\u8bd5\u7248\u672c\uff08Beta\uff09<\/span><\/h2>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728\u63a2\u8ba8 1.11 \u7248\u672c\u4e4b\u524d\uff0c\u8ba9\u6211\u4eec\u5148\u4e86\u89e3\u4e00\u4e0b Cilium \u793e\u533a\u5ba3\u5e03\u7684 Service Mesh \u7684\u65b0\u529f\u80fd\u3002<\/p>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-a6c237add32758246f1ad2981c0059cd.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-a6c237add32758246f1ad2981c0059cd.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.18591772151898733\" data-type=\"png\" data-w=\"1264\" \/><\/div><\/figure>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u57fa\u4e8e eBPF \u6280\u672f\u7684 Service Mesh \uff08Beta\uff09\u7248\u672c<\/strong>\uff1a \u5b9a\u4e49\u4e86\u65b0\u7684\u670d\u52a1\u7f51\u683c\u80fd\u529b\uff0c\u8fd9\u5305\u62ec L7 \u6d41\u91cf\u7ba1\u7406\u548c\u8d1f\u8f7d\u5747\u8861\u3001TLS \u7ec8\u6b62\u3001\u91d1\u4e1d\u96c0\u53d1\u5e03\u3001\u8ffd\u8e2a\u7b49\u8bf8\u591a\u80fd\u529b\u3002<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u96c6\u6210\u4e86 Kubernetes Ingress (Beta) \u529f\u80fd<\/strong>\uff1a \u901a\u8fc7\u5c06 eBPF \u548c Envoy \u7684\u5f3a\u52bf\u8054\u5408\uff0c\u5b9e\u73b0\u4e86\u5bf9 Kubernetes Ingress \u7684\u652f\u6301\u3002<\/section>\n<\/li>\n<\/ul>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u7f51\u7ad9\u7684\u4e00\u7bc7\u6587\u7ae0\u8be6\u7ec6\u4ecb\u7ecd\u4e86<span style=\"font-weight: bold; color: #00a971;\">Service Mesh Beta \u7248\u672c<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[1]<\/sup>\uff0c\u5176\u4e2d\u4e5f\u5305\u62ec\u4e86\u5982\u4f55\u53c2\u4e0e\u5230\u8be5\u529f\u80fd\u7684\u5f00\u53d1\u3002\u5f53\u524d\uff0c\u8fd9\u4e9b Beta \u529f\u80fd\u662f Cilium \u9879\u76ee\u4e2d\u7684\u4e00\u90e8\u5206\uff0c\u5728\u5355\u72ec<span style=\"font-weight: bold; color: #00a971;\">\u5206\u652f<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[2]<\/sup>\u8fdb\u884c\u5f00\u53d1\uff0c\u53ef\u72ec\u7acb\u8fdb\u884c\u6d4b\u8bd5\u3001\u53cd\u9988\u548c\u4fee\u6539\uff0c\u6211\u4eec\u671f\u5f85\u5728 2022 \u5e74\u521d Cilium 1.12 \u7248\u672c\u53d1\u5e03\u4e4b\u524d\u5408\u5165\u5230 Cilium \u4e3b\u5206\u652f\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Cilium 1.11<\/span><\/h2>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium 1.11 \u7248\u672c\u5305\u62ec\u4e86 Kubernetes \u989d\u5916\u529f\u80fd\uff0c\u53ca\u5355\u72ec\u90e8\u7f72\u7684\u8d1f\u8f7d\u5747\u8861\u5668\u3002<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">OpenTelemetry \u652f\u6301<\/strong>\uff1aHubble L3-L7 \u53ef\u89c2\u6d4b\u6027\u6570\u636e\u652f\u6301 OpenTelemetry \u8ddf\u8e2a\u548c\u5ea6\u91cf\uff08Metrics\uff09\u683c\u5f0f\u7684\u5bfc\u51fa\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[3]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Kubernetes APIServer \u7b56\u7565\u5339\u914d<\/strong>\uff1a\u65b0\u7684\u7b56\u7565\u5b9e\u4f53\u7528\u4e8e\u7b80\u5355\u65b9\u4fbf\u5730\u521b\u5efa\u8fdb\u51fa Kubernetes API Server \u6d41\u91cf\u7684\u7b56\u7565\u6a21\u578b\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[4]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u62d3\u6251\u611f\u77e5\u7684\u8def\u7531<\/strong>\uff1a\u589e\u5f3a\u8d1f\u8f7d\u5747\u8861\u80fd\u529b\uff0c\u57fa\u4e8e\u62d3\u6251\u611f\u77e5\u5c06\u6d41\u91cf\u8def\u7531\u5230\u6700\u8fd1\u7684\u7aef\u70b9\uff0c\u6216\u4fdd\u6301\u5728\u540c\u4e00\u4e2a\u5730\u533a\uff08Region\uff09\u5185\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[5]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">BGP \u5ba3\u544a Pod CIDR<\/strong>\uff1a\u4f7f\u7528 BGP \u5728\u7f51\u7edc\u4e2d\u5ba3\u544a Pod CIDR \u7684 IP \u8def\u7531\u3002\uff08<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[6]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u670d\u52a1\u540e\u7aef\u6d41\u91cf\u7684\u4f18\u96c5\u7ec8\u6b62<\/strong>\uff1a\u652f\u6301\u4f18\u96c5\u7684\u8fde\u63a5\u7ec8\u6b62\uff0c\u901a\u8fc7\u8d1f\u8f7d\u5747\u8861\u5411\u7ec8\u6b62\u7684 Pod \u53d1\u9001\u7684\u6d41\u91cf\u53ef\u4ee5\u6b63\u5e38\u5904\u7406\u540e\u7ec8\u6b62\u3002(<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[7]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u4e3b\u673a\u9632\u706b\u5899\u7a33\u5b9a\u7248<\/strong>\uff1a\u4e3b\u673a\u9632\u706b\u5899\u529f\u80fd\u5df2\u5347\u7ea7\u4e3a\u751f\u4ea7\u53ef\u7528\u7684\u7a33\u5b9a\u7248\u672c\u3002\uff08<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[8]<\/sup>\uff09<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u63d0\u9ad8\u8d1f\u8f7d\u5747\u8861\u5668\u6269\u5c55\u6027<\/strong>\uff1aCilium \u8d1f\u8f7d\u5747\u8861\u652f\u6301\u8d85\u8fc7 64K \u7684\u540e\u7aef\u7aef\u70b9\u3002(<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[9]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u63d0\u9ad8\u8d1f\u8f7d\u5747\u8861\u5668\u8bbe\u5907\u652f\u6301<\/strong>\uff1a\u8d1f\u8f7d\u5747\u8861\u7684\u52a0\u901f XDP \u5feb\u901f\u8def\u5f84\u73b0\u5728\u652f\u6301 bond \u8bbe\u5907\uff08<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[10]<\/sup>) \u540c\u65f6\uff0c\u53ef\u66f4\u666e\u904d\u5730\u7528\u4e8e\u591a\u8bbe\u5907\u8bbe\u7f6e\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[11]<\/sup>)\u3002<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Kube-Proxy-replacement \u652f\u6301 istio<\/strong>\uff1aCilium \u7684 kube-proxy \u66ff\u4ee3\u6a21\u5f0f\u4e0e Istio sidecar \u90e8\u7f72\u6a21\u5f0f\u517c\u5bb9\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[12]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Egress \u51fa\u53e3\u7f51\u5173\u7684\u4f18\u5316<\/strong>\uff1aEgress \u7f51\u5173\u80fd\u529b\u589e\u5f3a\uff0c\u652f\u6301\u5176\u4ed6\u6570\u636e\u8def\u5f84\u6a21\u5f0f\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[13]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u6258\u7ba1 IPv4\/IPv6 \u90bb\u5c45\u53d1\u73b0<\/strong>\uff1a\u5bf9 Linux \u5185\u6838\u548c Cilium \u8d1f\u8f7d\u5747\u8861\u5668\u8fdb\u884c\u4e86\u6269\u5c55\uff0c\u5220\u9664\u4e86\u5176\u5185\u90e8 ARP \u5e93\uff0c\u5c06 IPv4 \u7684\u4e0b\u4e00\u8df3\u53d1\u73b0\u4ee5\u53ca\u73b0\u5728\u7684 IPv6 \u8282\u70b9\u59d4\u6258\u7ed9\u5185\u6838\u7ba1\u7406\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[14]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u57fa\u4e8e\u8def\u7531\u7684\u8bbe\u5907\u68c0\u6d4b<\/strong>\uff1a\u5916\u90e8\u7f51\u7edc\u8bbe\u5907\u57fa\u4e8e\u8def\u7531\u7684\u81ea\u52a8\u68c0\u6d4b\uff0c\u4ee5\u63d0\u9ad8 Cilium \u591a\u8bbe\u5907\u8bbe\u7f6e\u7684\u7528\u6237\u4f53\u9a8c\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[15]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Kubernetes Cgroup \u589e\u5f3a<\/strong>\uff1a\u5728 cgroup v2 \u6a21\u5f0f\u4e0b\u96c6\u6210\u4e86 Cilium \u7684 kube-proxy-replacement \u529f\u80fd\uff0c\u540c\u65f6\uff0c\u5bf9 cgroup v1\/v2 \u6df7\u5408\u6a21\u5f0f\u4e0b\u7684 Linux \u5185\u6838\u8fdb\u884c\u4e86\u589e\u5f3a\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[16]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Cilium Endpoint Slices<\/strong>\uff1aCilium \u57fa\u4e8e CRD \u6a21\u5f0f\u80fd\u591f\u66f4\u52a0\u9ad8\u6548\u5730\u4e0e Kubernetes \u7684\u63a7\u5236\u5e73\u9762\u4ea4\u4e92\uff0c\u5e76\u4e14\u4e0d\u9700\u8981\u4e13\u6709 ETCD \u5b9e\u4f8b\uff0c\u8282\u70b9\u4e5f\u53ef\u6269\u5c55\u5230 1000+\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[17]<\/sup>)<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u96c6\u6210 Mirantis Kubernetes \u5f15\u64ce<\/strong>\uff1a\u652f\u6301 Mirantis Kubernetes \u5f15\u64ce\u3002 (<span style=\"font-weight: bold; color: #00a971;\">\u66f4\u591a\u8be6\u60c5<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[18]<\/sup>)<\/section>\n<\/li>\n<\/ul>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u4ec0\u4e48\u662f Cilium \uff1f<\/span><\/h2>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u662f\u4e00\u4e2a\u5f00\u6e90\u8f6f\u4ef6\uff0c\u4e3a\u57fa\u4e8e Kubernetes \u7684 Linux \u5bb9\u5668\u7ba1\u7406\u5e73\u53f0\u4e0a\u90e8\u7f72\u7684\u670d\u52a1\uff0c\u900f\u660e\u5730\u63d0\u4f9b\u670d\u52a1\u95f4\u7684\u7f51\u7edc\u548c API \u8fde\u63a5\u53ca\u5b89\u5168\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u5e95\u5c42\u662f\u57fa\u4e8e Linux \u5185\u6838\u7684\u65b0\u6280\u672f eBPF\uff0c\u53ef\u4ee5\u5728 Linux \u7cfb\u7edf\u4e2d\u52a8\u6001\u6ce8\u5165\u5f3a\u5927\u7684\u5b89\u5168\u6027\u3001\u53ef\u89c1\u6027\u548c\u7f51\u7edc\u63a7\u5236\u903b\u8f91\u3002 Cilium \u57fa\u4e8e eBPF \u63d0\u4f9b\u4e86\u591a\u96c6\u7fa4\u8def\u7531\u3001\u66ff\u4ee3 kube-proxy \u5b9e\u73b0\u8d1f\u8f7d\u5747\u8861\u3001\u900f\u660e\u52a0\u5bc6\u4ee5\u53ca\u7f51\u7edc\u548c\u670d\u52a1\u5b89\u5168\u7b49\u8bf8\u591a\u529f\u80fd\u3002\u9664\u4e86\u63d0\u4f9b\u4f20\u7edf\u7684\u7f51\u7edc\u5b89\u5168\u4e4b\u5916\uff0ceBPF \u7684\u7075\u6d3b\u6027\u8fd8\u652f\u6301\u5e94\u7528\u534f\u8bae\u548c DNS \u8bf7\u6c42\/\u54cd\u5e94\u5b89\u5168\u3002\u540c\u65f6\uff0cCilium \u4e0e Envoy \u7d27\u5bc6\u96c6\u6210\uff0c\u63d0\u4f9b\u4e86\u57fa\u4e8e Go \u7684\u6269\u5c55\u6846\u67b6\u3002\u56e0\u4e3a eBPF \u8fd0\u884c\u5728 Linux \u5185\u6838\u4e2d\uff0c\u6240\u4ee5\u5e94\u7528\u6240\u6709 Cilium \u529f\u80fd\uff0c\u65e0\u9700\u5bf9\u5e94\u7528\u7a0b\u5e8f\u4ee3\u7801\u6216\u5bb9\u5668\u914d\u7f6e\u8fdb\u884c\u4efb\u4f55\u66f4\u6539\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8bf7\u53c2\u9605 <strong style=\"color: #00a971;\">[Cilium \u7b80\u4ecb]<\/strong> \u90e8\u5206\uff0c\u4e86\u89e3 Cilium \u66f4\u8be6\u7ec6\u7684\u4ecb\u7ecd\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">OpenTelemetry \u652f\u6301<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-a546de3288e87ac99cc9259452254d04.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-a546de3288e87ac99cc9259452254d04.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.5882061446977205\" data-type=\"png\" data-w=\"2018\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">Jaeger UI \u663e\u793a Hubble \u6570\u636e\u6d41<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u65b0\u7248\u672c\u589e\u52a0\u4e86\u5bf9 <span style=\"font-weight: bold; color: #00a971;\">OpenTelemetry<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[19]<\/sup> \u7684\u652f\u6301\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">OpenTelemetry \u662f\u4e00\u4e2a CNCF \u9879\u76ee\uff0c\u5b9a\u4e49\u4e86\u9065\u6d4b\u534f\u8bae\u548c\u6570\u636e\u683c\u5f0f\uff0c\u6db5\u76d6\u4e86\u5206\u5e03\u5f0f\u8ddf\u8e2a\u3001\u6307\u6807\u548c\u65e5\u5fd7\u3002\u8be5\u9879\u76ee\u63d0\u4f9b\u4e86 SDK \u548c\u8fd0\u884c\u5728 Kubernetes \u4e0a\u7684\u6536\u96c6\u5668\u3002\u901a\u5e38\uff0c\u5e94\u7528\u7a0b\u5e8f\u76f4\u63a5\u68c0\u6d4b\u66b4\u9732 OpenTelemetry \u6570\u636e\uff0c\u8fd9\u79cd\u68c0\u6d4b\u6700\u5e38\u4f7f\u7528 OpenTelemetry SDK \u5728\u5e94\u7528\u7a0b\u5e8f\u5185\u5b9e\u73b0\u3002OpenTelemetry \u6536\u96c6\u5668\u7528\u4e8e\u4ece\u96c6\u7fa4\u4e2d\u7684\u5404\u79cd\u5e94\u7528\u7a0b\u5e8f\u6536\u96c6\u6570\u636e\uff0c\u5e76\u5c06\u5176\u53d1\u9001\u5230\u4e00\u4e2a\u6216\u591a\u4e2a\u540e\u7aef\u3002CNCF \u9879\u76ee <span style=\"font-weight: bold; color: #00a971;\">Jaeger<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[20]<\/sup> \u662f\u53ef\u7528\u4e8e\u5b58\u50a8\u548c\u5448\u73b0\u8ddf\u8e2a\u6570\u636e\u7684\u540e\u7aef\u4e4b\u4e00\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"font-weight: bold; color: #00a971;\">\u652f\u6301 OpenTelemetry \u7684 Hubble \u9002\u914d\u5668<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[21]<\/sup>\u662f\u4e00\u4e2a\u9644\u52a0\u7ec4\u4ef6\uff0c\u53ef\u4ee5\u90e8\u7f72\u5230\u8fd0\u884c Cilium \u7684\u96c6\u7fa4\u4e0a\uff08Cilium \u7248\u672c\u6700\u597d\u662f 1.11\uff0c\u5f53\u7136\u4e5f\u5e94\u8be5\u9002\u7528\u4e8e\u65e7\u7248\u672c\uff09\u3002\u8be5\u9002\u914d\u5668\u662f\u4e00\u4e2a\u5d4c\u5165\u4e86 Hubble \u63a5\u6536\u5668\u7684 OpenTelemetry \u6536\u96c6\u5668\uff0c\u6211\u4eec\u63a8\u8350\u4f7f\u7528 <span style=\"font-weight: bold; color: #00a971;\">OpenTelemetry Operator<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[22]<\/sup> \u8fdb\u884c\u90e8\u7f72\uff08\u8be6\u89c1<span style=\"font-weight: bold; color: #00a971;\">\u7528\u6237\u6307\u5357<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[23]<\/sup>\uff09\u3002Hubble \u9002\u914d\u5668\u4ece Hubble \u8bfb\u53d6\u6d41\u91cf\u6570\u636e\uff0c\u5e76\u5c06\u5176\u8f6c\u6362\u4e3a\u8ddf\u8e2a\u548c\u65e5\u5fd7\u6570\u636e\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Hubble \u9002\u914d\u5668\u6dfb\u52a0\u5230\u652f\u6301 OpenTelemetry \u7684\u96c6\u7fa4\u4e2d\uff0c\u53ef\u5bf9\u7f51\u7edc\u4e8b\u4ef6\u548c\u5e94\u7528\u7ea7\u522b\u9065\u6d4b\u63d0\u4f9b\u6709\u4ef7\u503c\u7684\u53ef\u89c2\u6d4b\u6027\u3002\u5f53\u524d\u7248\u672c\u901a\u8fc7 OpenTelemetry SDK \u63d0\u4f9b\u4e86 HTTP \u6d41\u91cf\u548c spans \u7684\u5173\u8054\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u611f\u77e5\u62d3\u6251\u7684\u8d1f\u8f7d\u5747\u8861<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-56c9fb316e237fea500f82bd1e68566f.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-56c9fb316e237fea500f82bd1e68566f.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.592391304347826\" data-type=\"png\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">\u611f\u77e5\u62d3\u6251\u7684\u8d1f\u8f7d\u5747\u8861<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Kubernetes \u96c6\u7fa4\u5728\u8de8\u591a\u6570\u636e\u4e2d\u5fc3\u6216\u53ef\u7528\u533a\u90e8\u7f72\u662f\u5f88\u5e38\u89c1\u7684\u3002\u8fd9\u4e0d\u4ec5\u5e26\u6765\u4e86\u9ad8\u53ef\u7528\u6027\u597d\u5904\uff0c\u800c\u4e14\u4e5f\u5e26\u6765\u4e86\u4e00\u4e9b\u64cd\u4f5c\u4e0a\u7684\u590d\u6742\u6027\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u76ee\u524d\u4e3a\u6b62\uff0cKubernetes \u8fd8\u6ca1\u6709\u4e00\u4e2a\u5185\u7f6e\u7684\u7ed3\u6784\uff0c\u53ef\u4ee5\u57fa\u4e8e\u62d3\u6251\u7ea7\u522b\u63cf\u8ff0 Kubernetes service \u7aef\u70b9\u7684\u4f4d\u7f6e\u3002\u8fd9\u610f\u5473\u7740\uff0cKubernetes \u8282\u70b9\u57fa\u4e8e\u670d\u52a1\u8d1f\u8f7d\u5747\u8861\u51b3\u7b56\u9009\u62e9\u7684 service \u7aef\u70b9\uff0c\u53ef\u80fd\u4e0e\u8bf7\u6c42\u670d\u52a1\u7684\u5ba2\u6237\u5728\u4e0d\u540c\u7684\u53ef\u7528\u533a\u3002 \u8fd9\u79cd\u573a\u666f\u4e0b\u4f1a\u5e26\u6765\u8bf8\u591a\u526f\u4f5c\u7528\uff0c\u53ef\u80fd\u662f\u4e91\u670d\u52a1\u8d39\u7528\u589e\u52a0\uff0c\u901a\u5e38\u7531\u4e8e\u6d41\u91cf\u8de8\u8d8a\u591a\u4e2a\u53ef\u7528\u533a\uff0c\u4e91\u63d0\u4f9b\u5546\u4f1a\u989d\u5916\u6536\u53d6\u8d39\u7528\uff0c\u6216\u8bf7\u6c42\u5ef6\u8fdf\u589e\u52a0\u3002\u66f4\u5e7f\u6cdb\u5730\u8bf4\uff0c\u6211\u4eec\u9700\u8981\u6839\u636e\u62d3\u6251\u7ed3\u6784\u5b9a\u4e49 service \u7aef\u70b9\u7684\u4f4d\u7f6e\uff0c \u4f8b\u5982\uff0c\u670d\u52a1\u6d41\u91cf\u5e94\u8be5\u5728\u540c\u4e00\u8282\u70b9\uff08node\uff09\u3001\u540c\u4e00\u673a\u67b6\uff08rack\uff09\u3001\u540c\u4e00\u6545\u969c\u5206\u533a\uff08zone\uff09\u3001\u540c\u4e00\u6545\u969c\u5730\u533a\uff08region\uff09\u3001\u540c\u4e91\u63d0\u4f9b\u5546\u7684\u7aef\u70b9\u4e4b\u95f4\u8fdb\u884c\u8d1f\u8f7d\u5747\u8861\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Kubernetes v1.21 \u5f15\u5165\u4e86\u4e00\u4e2a\u79f0\u4e3a<span style=\"font-weight: bold; color: #00a971;\">\u62d3\u6251\u611f\u77e5\u8def\u7531<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[24]<\/sup>\u7684\u529f\u80fd\u6765\u89e3\u51b3\u8fd9\u4e2a\u9650\u5236\u3002\u901a\u8fc7\u5c06 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">service.kubernetes.io\/topology-aware-hints<\/code> \u6ce8\u89e3\u88ab\u8bbe\u7f6e\u4e3a <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">auto<\/code> \uff0c\u5728 service \u7684 EndpointSlice \u5bf9\u8c61\u4e2d\u8bbe\u7f6e\u7aef\u70b9\u63d0\u793a\uff0c\u63d0\u793a\u7aef\u70b9\u8fd0\u884c\u7684\u5206\u533a\u3002\u5206\u533a\u540d\u4ece\u8282\u70b9\u7684 topology.kubernetes.io\/zone \u6807\u7b7e\u83b7\u53d6\u3002 \u5982\u679c\u4e24\u4e2a\u8282\u70b9\u7684\u5206\u533a\u6807\u7b7e\u503c\u76f8\u540c\uff0c\u5219\u88ab\u8ba4\u4e3a\u5904\u4e8e\u540c\u4e00\u62d3\u6251\u7ea7\u522b\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8be5\u63d0\u793a\u4f1a\u88ab Cilium \u7684 kube-proxy \u66ff\u4ee3\u6765\u5904\u7406\uff0c\u5e76\u4f1a\u6839\u636e EndpointSlice \u63a7\u5236\u5668\u8bbe\u7f6e\u7684\u63d0\u793a\u6765\u8fc7\u6ee4\u8def\u7531\u7684\u7aef\u70b9\uff0c\u8ba9\u8d1f\u8f7d\u5747\u8861\u5668\u4f18\u5148\u9009\u62e9\u540c\u4e00\u5206\u533a\u7684\u7aef\u70b9\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8be5 Kubernetes \u529f\u80fd\u76ee\u524d\u5904\u4e8e Alpha \u9636\u6bb5\uff0c\u56e0\u6b64\u9700\u8981\u4f7f\u7528&#8211;feature-gate \u542f\u7528\u3002\u66f4\u591a\u4fe1\u606f\u8bf7\u53c2\u8003<span style=\"font-weight: bold; color: #00a971;\">\u5b98\u65b9\u6587\u6863<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[25]<\/sup>\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Kubernetes APIServer \u7b56\u7565\u5339\u914d<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-1db6df090b4b50b31988eeeb0589fe43.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-1db6df090b4b50b31988eeeb0589fe43.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.6389496717724289\" data-type=\"png\" data-w=\"914\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">Hubble UI \u663e\u793a apiserver \u7f51\u7edc\u7b56\u7565<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u6258\u7ba1 Kubernetes \u73af\u5883\uff0c\u5982 GKE\u3001EKS \u548c AKS \u4e0a\uff0ckube-apiserver \u7684 IP \u5730\u5740\u662f\u4e0d\u900f\u660e\u7684\u3002\u5728\u4ee5\u524d\u7684 Cilium \u7248\u672c\u4e2d\uff0c\u6ca1\u6709\u63d0\u4f9b\u6b63\u89c4\u7684\u65b9\u5f0f\u6765\u7f16\u5199 Cilium \u7f51\u7edc\u7b56\u7565\uff0c\u5b9a\u4e49\u5bf9 kube-apiserver \u7684\u8bbf\u95ee\u63a7\u5236\u3002\u8fd9\u6d89\u53ca\u4e00\u4e9b\u5b9e\u73b0\u7ec6\u8282\uff0c\u5982\uff1aCilium \u5b89\u5168\u8eab\u4efd\u5206\u914d\uff0ckube-apiserver \u662f\u90e8\u7f72\u5728\u96c6\u7fa4\u5185\uff0c\u8fd8\u662f\u90e8\u7f72\u5728\u96c6\u7fa4\u5916\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4e3a\u4e86\u89e3\u51b3\u8fd9\u4e2a\u95ee\u9898\uff0cCilium 1.11 \u589e\u52a0\u4e86\u65b0\u529f\u80fd\uff0c\u4e3a\u7528\u6237\u63d0\u4f9b\u4e00\u79cd\u65b9\u6cd5\uff0c\u5141\u8bb8\u4f7f\u7528\u4e13\u7528\u7b56\u7565\u5bf9\u8c61\u5b9a\u4e49\u8fdb\u51fa apiserver \u6d41\u91cf\u7684\u8bbf\u95ee\u63a7\u5236\u3002\u8be5\u529f\u80fd\u7684\u5e95\u5c42\u662f\u5b9e\u4f53\u9009\u62e9\u5668\uff0c\u80fd\u591f\u89e3\u6790\u9884\u7559\u7684 kube-apiserver \u6807\u7b7e\u542b\u4e49\uff0c \u5e76\u53ef\u81ea\u52a8\u5e94\u7528\u5728\u4e0e kube-apiserver \u5173\u8054\u7684 IP \u5730\u5740\u4e0a\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5b89\u5168\u56e2\u961f\u5c06\u5bf9\u8fd9\u4e2a\u65b0\u529f\u80fd\u7279\u522b\u611f\u5174\u8da3\uff0c\u56e0\u4e3a\u5b83\u63d0\u4f9b\u4e86\u4e00\u4e2a\u7b80\u5355\u7684\u65b9\u6cd5\u6765\u5b9a\u4e49\u5bf9 pod \u7684 Cilium \u7f51\u7edc\u7b56\u7565\uff0c\u5141\u8bb8\u6216\u7981\u6b62\u8bbf\u95ee kube-apiserver\u3002\u4e0b\u9762 CiliumNetworkPolicy \u7b56\u7565\u7247\u6bb5\u5b9a\u4e49\u4e86 kube-system \u547d\u540d\u7a7a\u95f4\u5185\u7684\u6240\u6709 Cilium \u7aef\u70b9\u5141\u8bb8\u8bbf\u95ee kube-apiserver\uff0c \u9664\u6b64\u4e4b\u5916\u7684\u6240\u6709 Cilium \u7aef\u70b9\u7981\u6b62\u8bbf\u95ee kube-apiserver\u3002<\/p>\n<pre style=\"margin-top: 10px; margin-bottom: 10px; margin: 12px auto; border-radius: 5px; box-shadow: 0 1px 2px -2px rgba(0,0,0,.16), 0 3px 6px 0 rgba(0,0,0,.12), 0 5px 12px 4px rgba(0,0,0,.09) !important;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><code style=\"overflow-x: auto; padding: 16px; color: #abb2bf; display: -webkit-box; font-family: Operator Mono, Consolas, Monaco, Menlo, monospace; font-size: 12px; -webkit-overflow-scrolling: touch; padding-top: 15px; background: #282c34; border-radius: 5px;\"><span style=\"color: #d19a66; line-height: 26px;\">apiVersion:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">cilium.io\/v2<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">kind:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">CiliumNetworkPolicy<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">metadata:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">name:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">allow-to-apiserver<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">namespace:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">kube-system<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">spec:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">endpointSelector:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">{}<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">egress:<\/span>\r\n\u00a0\u00a0<span style=\"color: #61aeee; line-height: 26px;\">-<\/span>\u00a0<span style=\"color: #d19a66; line-height: 26px;\">toEntities:<\/span>\r\n\u00a0\u00a0\u00a0\u00a0<span style=\"color: #61aeee; line-height: 26px;\">-<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">kube-apiserver<\/span>\r\n<\/code><\/pre>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">BGP \u5ba3\u544a Pod CIDR<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-118f559b27502158363398068103d24a.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-118f559b27502158363398068103d24a.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.26902173913043476\" data-type=\"png\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">BGP \u5ba3\u544a Pod CIDR \u7684\u793a\u610f\u56fe<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u968f\u7740\u79c1\u6709 Kubernetes \u73af\u5883\u7684\u65e5\u76ca\u5173\u6ce8\uff0c\u6211\u4eec\u5e0c\u671b\u4e0e\u73b0\u5b58\u7684\u6570\u636e\u4e2d\u5fc3\u7f51\u7edc\u57fa\u7840\u8bbe\u65bd\u5f88\u597d\u5730\u96c6\u6210\uff0c\u5b83\u4eec\u901a\u5e38\u662f\u57fa\u4e8e BGP \u534f\u8bae\u8fdb\u884c\u8def\u7531\u5206\u53d1\u7684\u3002 \u5728\u4e0a\u4e00\u4e2a\u7248\u672c\u4e2d\uff0cCilium agent \u5df2\u7ecf\u5f00\u59cb\u96c6\u6210\u4e86 BGP \u534f\u8bae, \u53ef\u4ee5\u901a\u8fc7 BGP \u5411 BGP \u8def\u7531\u5668<span style=\"font-weight: bold; color: #00a971;\">\u53d1\u5e03\u8d1f\u8f7d\u5747\u8861\u5668\u7684 service \u7684 VIP<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[26]<\/sup>\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u73b0\u5728\uff0cCilium 1.11 \u7248\u672c\u8fd8\u5f15\u5165\u4e86\u901a\u8fc7 BGP \u5ba3\u544a Kubernetes Pod \u5b50\u7f51\u7684\u80fd\u529b\u3002Cilium \u53ef\u4e0e\u4efb\u4f55\u4e0b\u6e38\u4e92\u8054\u7684 BGP \u57fa\u7840\u8bbe\u65bd\u521b\u5efa\u4e00\u4e2a BGP \u5bf9\u7b49\u4f53\uff0c\u5e76\u901a\u544a\u5206\u914d\u7684 Pod IP \u5730\u5740\u7684\u5b50\u7f51\u3002\u8fd9\u6837\u4e0b\u6e38\u57fa\u7840\u8bbe\u65bd\u5c31\u53ef\u4ee5\u6309\u7167\u5408\u9002\u65b9\u5f0f\u6765\u5206\u53d1\u8fd9\u4e9b\u8def\u7531\uff0c\u4ee5\u4f7f\u6570\u636e\u4e2d\u5fc3\u80fd\u591f\u901a\u8fc7\u5404\u79cd\u79c1\u6709\/\u516c\u5171\u4e0b\u4e00\u8df3\u8def\u7531\u5230 Pod \u5b50\u7f51\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8981\u5f00\u59cb\u4f7f\u7528\u6b64\u529f\u80fd\uff0c\u8fd0\u884c Cilium \u7684 Kubernetes \u8282\u70b9\u9700\u8981\u8bfb\u53d6 BGP \u7684 ConfigMap \u8bbe\u7f6e\uff1a<\/p>\n<pre style=\"margin-top: 10px; margin-bottom: 10px; margin: 12px auto; border-radius: 5px; box-shadow: 0 1px 2px -2px rgba(0,0,0,.16), 0 3px 6px 0 rgba(0,0,0,.12), 0 5px 12px 4px rgba(0,0,0,.09) !important;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><code style=\"overflow-x: auto; padding: 16px; color: #abb2bf; display: -webkit-box; font-family: Operator Mono, Consolas, Monaco, Menlo, monospace; font-size: 12px; -webkit-overflow-scrolling: touch; padding-top: 15px; background: #282c34; border-radius: 5px;\"><span style=\"color: #d19a66; line-height: 26px;\">apiVersion:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">v1<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">kind:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">ConfigMap<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">metadata:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">name:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">bgp-config<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">namespace:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">kube-system<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">data:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">config.yaml:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">|\r\n\u00a0\u00a0\u00a0\u00a0peers:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0-\u00a0peer-address:\u00a0192.168.1.11\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0peer-asn:\u00a064512\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0my-asn:\u00a064512\r\n<\/span><\/code><\/pre>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u540c\u65f6\uff0cCilium \u5e94\u8be5\u4f7f\u7528\u4ee5\u4e0b\u53c2\u6570\u8fdb\u884c\u5b89\u88c5 \uff1a<\/p>\n<pre style=\"margin-top: 10px; margin-bottom: 10px; margin: 12px auto; border-radius: 5px; box-shadow: 0 1px 2px -2px rgba(0,0,0,.16), 0 3px 6px 0 rgba(0,0,0,.12), 0 5px 12px 4px rgba(0,0,0,.09) !important;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><code style=\"overflow-x: auto; padding: 16px; color: #abb2bf; display: -webkit-box; font-family: Operator Mono, Consolas, Monaco, Menlo, monospace; font-size: 12px; -webkit-overflow-scrolling: touch; padding-top: 15px; background: #282c34; border-radius: 5px;\">$\u00a0cilium\u00a0install\u00a0\r\n\u00a0\u00a0\u00a0\u00a0--config=<span style=\"color: #98c379; line-height: 26px;\">\"bgp-announce-pod-cidr=true\"<\/span>\r\n<\/code><\/pre>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u5b89\u88c5\u5b8c\u540e\uff0c\u5b83\u5c06\u4f1a\u5411 BGP \u8def\u7531\u5668\u53d1\u5e03 Pod CIDR \u8303\u56f4\uff0c\u5373 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">192.168.1.11<\/code>\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4e0b\u9762\u662f\u6700\u8fd1\u7684 Cilium <span style=\"font-weight: bold; color: #00a971;\">eCHO episode<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[27]<\/sup> \u5b8c\u6574\u6f14\u793a\u89c6\u9891\u3002<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\">https:\/\/www.youtube.com\/watch?v=nsfbFUO8eu4<\/section>\n<\/li>\n<\/ul>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5982\u679c\u60f3\u4e86\u89e3\u66f4\u591a\uff0c\u5982\uff1a\u5982\u4f55\u4e3a Kubernetes service \u914d\u7f6e LoadBalancer IP \u5ba3\u544a\uff0c\u5982\u4f55\u901a\u8fc7 BGP \u53d1\u5e03\u8282\u70b9\u7684 Pod CIDR \u8303\u56f4\uff0c\u8bf7\u53c2\u89c1 <span style=\"font-weight: bold; color: #00a971;\">docs.cilium.io<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[28]<\/sup>\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u6258\u7ba1 IPv4\/IPv6 \u90bb\u5c45\u53d1\u73b0<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-33d122bf58c2e7dd2439ec642ec14bbc.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-33d122bf58c2e7dd2439ec642ec14bbc.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.751358695652174\" data-type=\"png\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">\u6258\u7ba1\u90bb\u5c45\u53d1\u73b0\u7684\u793a\u610f\u56fe<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5f53 Cilium \u542f\u7528 eBPF \u66ff\u4ee3 kube-proxy \u65f6\uff0cCilium \u4f1a\u6267\u884c\u96c6\u7fa4\u8282\u70b9\u7684\u90bb\u5c45\u53d1\u73b0\uff0c\u4ee5\u6536\u96c6\u7f51\u7edc\u4e2d\u76f4\u63a5\u90bb\u5c45\u6216\u4e0b\u4e00\u8df3\u7684 L2 \u5730\u5740\u3002\u8fd9\u662f\u670d\u52a1\u8d1f\u8f7d\u5e73\u8861\u6240\u5fc5\u9700\u7684\uff0c<span style=\"font-weight: bold; color: #00a971;\">eXpress Data Path<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[29]<\/sup> (XDP) \u5feb\u901f\u8def\u5f84\u652f\u6301\u6bcf\u79d2\u6570\u767e\u4e07\u6570\u636e\u5305\u7684\u53ef\u9760\u9ad8\u6d41\u91cf\u901f\u7387\u3002\u5728\u8fd9\u79cd\u6a21\u5f0f\u4e0b\uff0c\u5728\u6280\u672f\u4e0a\u6309\u9700\u52a8\u6001\u89e3\u6790\u662f\u4e0d\u53ef\u80fd\u7684\uff0c\u56e0\u4e3a\u5b83\u9700\u8981\u7b49\u5f85\u76f8\u90bb\u7684\u540e\u7aef\u88ab\u89e3\u6790\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728 Cilium 1.10 \u53ca\u66f4\u65e9\u7248\u672c\u4e2d\uff0ccilium agent \u672c\u8eab\u5305\u542b\u4e00\u4e2a ARP \u89e3\u6790\u5e93\uff0c\u5176\u63a7\u5236\u5668\u89e6\u53d1\u53d1\u73b0\u548c\u5b9a\u671f\u5237\u65b0\u65b0\u589e\u96c6\u7fa4\u8282\u70b9\u3002\u624b\u52a8\u89e3\u6790\u7684\u90bb\u5c45\u6761\u76ee\u88ab\u63a8\u9001\u5230\u5185\u6838\u5e76\u5237\u65b0\u4e3a PERMANENT \u6761\u76ee\uff0ceBPF \u8d1f\u8f7d\u5747\u8861\u5668\u68c0\u7d22\u8fd9\u4e9b\u6761\u76ee\uff0c\u5c06\u6d41\u91cf\u5b9a\u5411\u5230\u540e\u7aef\u3002cilium agent \u7684 ARP \u89e3\u6790\u5e93\u7f3a\u4e4f\u5bf9 IPv6 \u90bb\u5c45\u89e3\u6790\u652f\u6301\uff0c\u5e76\u4e14\uff0cPERMANENT \u90bb\u5c45\u6761\u76ee\u8fd8\u6709\u8bb8\u591a\u95ee\u9898\uff1a\u4e3e\u4e2a\u4f8b\u5b50\uff0c\u6761\u76ee\u53ef\u80fd\u53d8\u5f97\u9648\u65e7\uff0c\u5185\u6838\u62d2\u7edd\u5b66\u4e60\u5730\u5740\u66f4\u65b0\uff0c\u56e0\u4e3a\u5b83\u4eec\u672c\u8d28\u4e0a\u662f\u9759\u6001\u7684\uff0c\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\u5bfc\u81f4\u6570\u636e\u5305\u5728\u8282\u70b9\u95f4\u88ab\u4e22\u5f03\u3002\u6b64\u5916\uff0c\u5c06\u90bb\u5c45\u89e3\u6790\u7d27\u5bc6\u8026\u5408\u5230 cilium agent \u4e5f\u6709\u4e00\u4e2a\u7f3a\u70b9\uff0c\u5728 agent \u542f\u505c\u5468\u671f\u65f6\uff0c\u4e0d\u4f1a\u53d1\u751f\u5730\u5740\u66f4\u65b0\u7684\u5b66\u4e60\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728 Cilium 1.11 \u4e2d\uff0c\u90bb\u5c45\u53d1\u73b0\u529f\u80fd\u5df2\u88ab\u5b8c\u5168\u91cd\u65b0\u8bbe\u8ba1\uff0cCilium \u5185\u90e8\u7684 ARP \u89e3\u6790\u5e93\u5df2\u4ece agent \u4e2d\u5b8c\u5168\u79fb\u9664\u3002\u73b0\u5728 agent \u4f9d\u8d56\u4e8e Linux \u5185\u6838\u6765\u53d1\u73b0\u4e0b\u4e00\u8df3\u6216\u540c\u4e00 L2 \u57df\u4e2d\u7684\u4e3b\u673a\u3002Cilium \u73b0\u5728\u53ef\u540c\u65f6\u652f\u6301 IPv4 \u548c IPv6 \u90bb\u5c45\u53d1\u73b0\u3002\u5bf9\u4e8e v5.16 \u6216\u66f4\u65b0\u7684\u5185\u6838\uff0c\u6211\u4eec\u5df2\u7ecf\u5c06\u4eca\u5e74 Linux Plumbers \u4f1a\u8bae\u671f\u95f4\u5171\u540c\u7ec4\u7ec7\u7684 <span style=\"font-weight: bold; color: #00a971;\">BPF &amp; Networking Summit<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[30]<\/sup> \u4e0a\uff0c\u63d0\u51fa\u7684\u201c\u7ba1\u7406\u201d\u90bb\u5c45\u6761\u76ee\u5de5\u4f5c\u63d0\u4ea4\u5230\u4e0a\u6e38\uff08<span style=\"font-weight: bold; color: #00a971;\">part1<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[31]<\/sup>, <span style=\"font-weight: bold; color: #00a971;\">part2<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[32]<\/sup>, <span style=\"font-weight: bold; color: #00a971;\">part3<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[33]<\/sup>\uff09\u3002\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0cagent \u5c06\u65b0\u589e\u96c6\u7fa4\u8282\u70b9\u7684 L3 \u5730\u5740\u4e0b\u63a8\uff0c\u5e76\u89e6\u53d1\u5185\u6838\u5b9a\u671f\u81ea\u52a8\u89e3\u6790\u5b83\u4eec\u5bf9\u5e94\u7684 L2 \u5730\u5740\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8fd9\u4e9b\u90bb\u5c45\u6761\u76ee\u4f5c\u4e3a\u201c\u5916\u90e8\u5b66\u4e60\u201d\u548c\u201c\u7ba1\u7406\u201d\u90bb\u5c45\u5c5e\u6027\uff0c\u57fa\u4e8e netlink \u88ab\u63a8\u9001\u5230\u5185\u6838\u4e2d\u3002\u867d\u7136\u65e7\u5c5e\u6027\u786e\u4fdd\u5728\u538b\u529b\u4e0b\u8fd9\u4e9b\u90bb\u5c45\u6761\u76ee\u4e0d\u4f1a\u88ab\u5185\u6838\u7684\u5783\u573e\u6536\u96c6\u5668\u5904\u7406\uff0c\u4f46\u662f &#8220;\u7ba1\u7406&#8221; \u90bb\u5c45\u5c5e\u6027\u4f1a\uff0c\u5728\u53ef\u884c\u7684\u60c5\u51b5\u4e0b,\u5185\u6838\u9700\u8981\u81ea\u52a8\u5c06\u8fd9\u4e9b\u90bb\u5c45\u5c5e\u6027\u4fdd\u6301\u5728 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">REACHABLE<\/code> \u72b6\u6001\u3002\u8fd9\u610f\u601d\u662f\uff0c\u5982\u679c\u8282\u70b9\u7684\u4e0a\u5c42\u5806\u6808\u6ca1\u6709\u4e3b\u52a8\u5411\u540e\u7aef\u8282\u70b9\u53d1\u9001\u6216\u63a5\u6536\u6d41\u91cf\uff0c\u5185\u6838\u53ef\u4ee5\u91cd\u65b0\u5b66\u4e60\uff0c\u5c06\u90bb\u5c45\u5c5e\u6027\u4fdd\u6301\u5728 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">REACHABLE<\/code> \u72b6\u6001\uff0c\u7136\u540e\u901a\u8fc7\u5185\u90e8\u5185\u6838\u5de5\u4f5c\u961f\u5217\u5b9a\u671f\u89e6\u53d1\u663e\u5f0f\u90bb\u5c45\u89e3\u6790\u3002\u5bf9\u4e8e\u6ca1\u6709 &#8220;\u7ba1\u7406&#8221; \u90bb\u5c45\u5c5e\u6027\u529f\u80fd\u7684\u65e7\u5185\u6838\uff0c\u5982\u679c\u9700\u8981\uff0cagent controller \u5c06\u5b9a\u671f\u7763\u4fc3\u5185\u6838\u89e6\u53d1\u65b0\u7684\u89e3\u51b3\u65b9\u6848\u3002\u56e0\u6b64\uff0cCilium \u4e0d\u518d\u6709 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">PERMANENT<\/code> \u90bb\u5c45\u6761\u76ee\uff0c\u5e76\u4e14\u5728\u5347\u7ea7\u65f6\uff0cagent \u5c06\u81ea\u52a8\u5c06\u65e7\u6761\u76ee\u8fc1\u79fb\u5230\u52a8\u6001\u90bb\u5c45\u6761\u76ee\u4e2d\uff0c\u4ee5\u4f7f\u5185\u6838\u80fd\u591f\u5728\u5176\u4e2d\u5b66\u4e60\u5730\u5740\u66f4\u65b0\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u6b64\u5916\uff0c\u5728\u591a\u8def\u5f84\u8def\u7531\u7684\u60c5\u51b5\u4e0b\uff0cagent \u7684\u8d1f\u8f7d\u5747\u8861\u73b0\u5728\u8fd8\u4f1a\u5728\u8def\u7531\u67e5\u627e\u4e2d\u67e5\u770b\u5931\u8d25\u7684\u4e0b\u4e00\u8df3\u3002\u8fd9\u610f\u5473\u7740\uff0c\u4e0d\u662f\u66ff\u4ee3\u6240\u6709\u7684\u8def\u7531\uff0c\u800c\u662f\u901a\u8fc7\u67e5\u770b\u76f8\u90bb\u5b50\u7cfb\u7edf\u4fe1\u606f\u6765\u907f\u514d\u5931\u8d25\u7684\u8def\u5f84\u3002\u603b\u7684\u6765\u8bf4\uff0c\u5bf9\u4e8e Cilium agent \u6765\u8bf4\uff0c\u8fd9\u9879\u5de5\u4f5c\u663e\u7740\u4fc3\u8fdb\u4e86\u90bb\u5c45\u7ba1\u7406\uff0c\u5e76\u4e14\u5728\u7f51\u7edc\u4e2d\u7684\u8282\u70b9\u6216\u4e0b\u4e00\u8df3\u7684\u90bb\u5c45\u5730\u5740\u53d1\u751f\u53d8\u5316\u65f6\uff0c\u6570\u636e\u8def\u5f84\u66f4\u6613\u53d8\u5316\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">XDP \u5bf9\u591a\u8bbe\u5907\u8d1f\u8f7d\u5747\u8861\u5668\u7684\u652f\u6301<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-693188a72323bfb0e5be1599c04cc467.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-693188a72323bfb0e5be1599c04cc467.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.563858695652174\" data-type=\"png\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">XDP\u652f\u6301\u591a\u8bbe\u5907\u8d1f\u8f7d\u5747\u8861\u5668\u7684\u793a\u610f\u56fe<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728\u6b64\u7248\u672c\u524d\uff0c\u57fa\u4e8e XDP \u7684\u8d1f\u8f7d\u5747\u8861\u5668\u52a0\u901f\u53ea\u80fd\u5728\u5355\u4e2a\u7f51\u7edc\u8bbe\u5907\u4e0a\u542f\u7528\uff0c\u4ee5\u4fbf\u8d1f\u8f7d\u5747\u8861\u5668\u4ee5\u53d1\u5939\u65b9\u5f0f\uff08hair-pinning\uff09\u8fd0\u884c\uff0c\u5373\u6570\u636e\u5305\u8f6c\u53d1\u79bb\u5f00\u7684\u8bbe\u5907\u4e0e\u6570\u636e\u5305\u5230\u8fbe\u7684\u8bbe\u5907\u76f8\u540c\u3002\u8fd9\u4e2a\u6700\u521d\u7684\u9650\u5236\u662f\u5728<span style=\"font-weight: bold; color: #00a971;\">\u57fa\u4e8e XDP \u5c42\u7684 kube-proxy \u66ff\u4ee3<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[34]<\/sup>\u52a0\u901f\u4e2d\u52a0\u5165\u7684\uff0c\u539f\u56e0\u662f\u5728 XDP\uff08<code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">XDP_REDIRECT<\/code>\uff09\u4e0b\u5bf9\u591a\u8bbe\u5907\u8f6c\u53d1\u7684\u9a71\u52a8\u652f\u6301\u6709\u9650\uff0c\u800c\u540c\u8bbe\u5907\u8f6c\u53d1\uff08<code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">XDP_TX<\/code>\uff09\u662f Linux \u5185\u6838\u4e2d\u6bcf\u4e2a\u9a71\u52a8\u7684 XDP \u90fd\u652f\u6301\u7684\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8fd9\u610f\u5473\u7740\u591a\u7f51\u7edc\u8bbe\u5907\u7684\u73af\u5883\u4e0b\uff0c\u6211\u4eec\u9700\u8981\u4f7f\u7528 tc eBPF \u673a\u5236\uff0c\u6240\u4ee5\u5fc5\u987b\u4f7f\u7528 Cilium \u7684\u5e38\u89c4 kube-proxy \u66ff\u4ee3\u3002\u8fd9\u79cd\u73af\u5883\u7684\u4e00\u4e2a\u5178\u578b\u4f8b\u5b50\u662f\u6709\u4e24\u4e2a\u7f51\u7edc\u8bbe\u5907\u7684\u4e3b\u673a\uff0c\u5176\u4e2d\u4e00\u4e2a\u662f\u516c\u7f51\uff0c\u63a5\u53d7\u6765\u81ea\u5916\u90e8\u5bf9 Kubernetes service \u7684\u8bf7\u6c42\uff0c\u800c\u53e6\u4e00\u4e2a\u662f\u79c1\u6709\u7f51\u7edc\uff0c\u7528\u4e8e Kubernetes \u8282\u70b9\u4e4b\u95f4\u7684\u96c6\u7fa4\u5185\u901a\u4fe1\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u7531\u4e8e\u5728\u73b0\u4ee3 LTS Linux \u5185\u6838\u4e0a\uff0c\u7edd\u5927\u591a\u6570 40G \u548c 100G \u4ee5\u4e0a\u7684\u4e0a\u6e38\u7f51\u5361\u9a71\u52a8\u90fd\u652f\u6301\u5f00\u7bb1\u5373\u7528\u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">XDP_REDIRECT<\/code>\uff0c\u8fd9\u79cd\u9650\u5236\u7ec8\u4e8e\u53ef\u4ee5\u89e3\u9664\uff0c\u56e0\u6b64\uff0c\u8fd9\u4e2a\u7248\u672c\u5728 Cilium \u7684 kube-proxy \u66ff\u4ee3\uff0c\u53ca Cilium \u7684\u72ec\u7acb\u8d1f\u8f7d\u5747\u8861\u5668\u4e0a\uff0c\u5b9e\u73b0\u4e86 XDP \u5c42\u7684\u591a\u7f51\u7edc\u8bbe\u5907\u7684\u8d1f\u8f7d\u5747\u8861\uff0c\u8fd9\u4f7f\u5f97\u5728\u66f4\u590d\u6742\u7684\u73af\u5883\u4e2d\u4e5f\u80fd\u4fdd\u6301\u6570\u636e\u5305\u5904\u7406\u6027\u80fd\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">XDP \u900f\u660e\u652f\u6301 bond \u8bbe\u5907<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-137fd5ae7e55881f5a842cbe1e5418bd.gif'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-137fd5ae7e55881f5a842cbe1e5418bd.gif\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.6561461794019934\" data-type=\"gif\" data-w=\"1204\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">XDP\u900f\u660e\u652f\u6301 bond \u8bbe\u5907<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728\u5f88\u591a\u4f01\u4e1a\u5185\u90e8\u6216\u4e91\u73af\u5883\u4e2d\uff0c\u8282\u70b9\u901a\u5e38\u4f7f\u7528 bond \u8bbe\u5907\uff0c\u8bbe\u7f6e\u5916\u90e8\u6d41\u91cf\u7684\u53cc\u7aef\u53e3\u7f51\u5361\u3002\u968f\u7740\u6700\u8fd1 Cilium \u7248\u672c\u7684\u4f18\u5316\uff0c\u5982\u5728 XDP \u5c42\u7684<span style=\"font-weight: bold; color: #00a971;\"> kube-proxy \u66ff\u4ee3<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[35]<\/sup> \u6216<span style=\"font-weight: bold; color: #00a971;\">\u72ec\u7acb\u8d1f\u8f7d\u5747\u8861\u5668<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[36]<\/sup>\uff0c\u6211\u4eec\u4ece\u7528\u6237\u90a3\u91cc\u7ecf\u5e38\u6536\u5230\u7684\u4e00\u4e2a\u95ee\u9898\u662f XDP \u52a0\u901f\u662f\u5426\u53ef\u4ee5\u4e0e bond \u7f51\u7edc\u8bbe\u5907\u7ed3\u5408\u4f7f\u7528\u3002\u867d\u7136 Linux \u5185\u6838\u7edd\u5927\u591a\u6570 10\/40\/100Gbit\/s \u7f51\u7edc\u9a71\u52a8\u7a0b\u5e8f\u652f\u6301 XDP\uff0c\u4f46\u5b83\u7f3a\u4e4f\u5728 bond\uff08\u548c 802.3ad\uff09\u6a21\u5f0f\u4e0b\u900f\u660e\u64cd\u4f5c XDP \u7684\u80fd\u529b\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5176\u4e2d\u7684\u4e00\u4e2a\u9009\u62e9\u662f\u5728\u7528\u6237\u7a7a\u95f4\u5b9e\u73b0 802.3ad\uff0c\u5e76\u5728 XDP \u7a0b\u5e8f\u5b9e\u73b0 bond \u8d1f\u8f7d\u5747\u8861\uff0c\u4f46\u8fd9\u5bf9 bond \u8bbe\u5907\u7ba1\u7406\u662f\u4e00\u4e2a\u76f8\u5f53\u9887\u4e3a\u7e41\u7410\u52aa\u529b\uff0c\u4f8b\u5982\uff1a\u5bf9 netlink \u94fe\u8def\u4e8b\u4ef6\u7684\u89c2\u6d4b\uff0c\u53e6\u5916\u8fd8\u9700\u8981\u4e3a\u7f16\u6392\u5668\u7684\u672c\u5730\u548c bond \u5206\u522b\u63d0\u4f9b\u5355\u72ec\u7684\u7a0b\u5e8f\u3002\u76f8\u53cd\uff0c\u672c\u5730\u5185\u6838\u5b9e\u73b0\u89e3\u51b3\u4e86\u8fd9\u4e9b\u95ee\u9898\uff0c\u63d0\u4f9b\u4e86\u66f4\u591a\u7684\u7075\u6d3b\u6027\uff0c\u5e76\u4e14\u80fd\u591f\u5904\u7406 eBPF \u7a0b\u5e8f\uff0c\u800c\u4e0d\u9700\u8981\u6539\u53d8\u6216\u91cd\u65b0\u7f16\u8bd1\u5b83\u4eec\u3002\u5185\u6838\u8d1f\u8d23\u7ba1\u7406 bond \u8bbe\u5907\u7ec4\uff0c\u53ef\u4ee5\u81ea\u52a8\u4f20\u64ad eBPF \u7a0b\u5e8f\u3002\u5bf9\u4e8e v5.15 \u6216\u66f4\u65b0\u7684\u5185\u6838\uff0c\u6211\u4eec\u5df2\u7ecf\u5728\u4e0a\u6e38\uff08<span style=\"font-weight: bold; color: #00a971;\">part1<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[37]<\/sup>, <span style=\"font-weight: bold; color: #00a971;\">part2<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[38]<\/sup>\uff09\u5b9e\u73b0\u4e86 XDP \u5bf9 bond \u8bbe\u5907\u7684\u652f\u6301\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5f53 XDP \u7a0b\u5e8f\u8fde\u63a5\u5230 bond \u8bbe\u5907\u65f6\uff0c<code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">XDP_TX<\/code> \u7684\u8bed\u4e49\u7b49\u540c\u4e8e tc eBPF \u7a0b\u5e8f\u9644\u52a0\u5230 bond \u8bbe\u5907\uff0c\u8fd9\u610f\u5473\u7740\u4ece bond \u8bbe\u5907\u4f20\u8f93\u6570\u636e\u5305\u4f7f\u7528 bond \u914d\u7f6e\u7684\u4f20\u8f93\u65b9\u6cd5\u6765\u9009\u62e9\u4ece\u5c5e\u8bbe\u5907\u3002\u6545\u969c\u8f6c\u79fb\u548c\u94fe\u8def\u805a\u5408\u6a21\u5f0f\u5747\u53ef\u4ee5\u5728 XDP \u64cd\u4f5c\u4e0b\u4f7f\u7528\u3002\u5bf9\u4e8e\u901a\u8fc7 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">XDP_TX<\/code> \u5c06\u6570\u636e\u5305\u4ece bond \u8bbe\u5907\u4e0a\u56de\u4f20\uff0c\u6211\u4eec\u5b9e\u73b0\u4e86\u8f6e\u5faa\u3001\u4e3b\u52a8\u5907\u4efd\u3001802.3ad \u4ee5\u53ca\u54c8\u5e0c\u8bbe\u5907\u9009\u62e9\u3002\u8fd9\u79cd\u60c5\u51b5\u5bf9\u4e8e\u50cf Cilium \u8fd9\u6837\u7684\u53d1\u5939\u5f0f\u8d1f\u8f7d\u5747\u8861\u5668\u6765\u8bf4\u7279\u522b\u6709\u610f\u4e49\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u57fa\u4e8e\u8def\u7531\u7684\u8bbe\u5907\u68c0\u6d4b<\/span><\/h2>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">1.11 \u7248\u672c\u663e\u7740\u7684\u63d0\u5347\u4e86\u8bbe\u5907\u7684\u81ea\u52a8\u68c0\u6d4b\uff0c\u53ef\u7528\u4e8e<span style=\"font-weight: bold; color: #00a971;\"> \u4f7f\u7528 eBPF \u66ff\u4ee3 kube-proxy<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[39]<\/sup>\u3001<span style=\"font-weight: bold; color: #00a971;\">\u5e26\u5bbd\u7ba1\u7406\u5668<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[40]<\/sup>\u548c<span style=\"font-weight: bold; color: #00a971;\">\u4e3b\u673a\u9632\u706b\u5899<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[41]<\/sup>\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728\u65e9\u671f\u7248\u672c\u4e2d\uff0cCilium \u81ea\u52a8\u68c0\u6d4b\u7684\u8bbe\u5907\u9700\u8981\u6709\u9ed8\u8ba4\u8def\u7531\u7684\u8bbe\u5907\uff0c\u548c\u6709 Kubernetes NodeIP \u7684\u8bbe\u5907\u3002\u5c55\u671b\u672a\u6765\uff0c\u73b0\u5728\u8bbe\u5907\u68c0\u6d4b\u662f\u6839\u636e\u4e3b\u673a\u547d\u540d\u7a7a\u95f4\u7684\u6240\u6709\u8def\u7531\u8868\u7684\u6761\u76ee\u6765\u8fdb\u884c\u7684\u3002\u4e5f\u5c31\u662f\u8bf4\uff0c\u6240\u6709\u975e\u6865\u63a5\u7684\u3001\u975e bond \u7684\u548c\u6709\u5168\u5c40\u5355\u64ad\u8def\u7531\u7684\u975e\u865a\u62df\u7684\u8bbe\u5907\uff0c\u73b0\u5728\u90fd\u80fd\u88ab\u68c0\u6d4b\u5230\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u901a\u8fc7\u8fd9\u9879\u6539\u8fdb\uff0cCilium \u73b0\u5728\u5e94\u8be5\u80fd\u591f\u5728\u66f4\u590d\u6742\u7684\u7f51\u7edc\u8bbe\u7f6e\u4e2d\u81ea\u52a8\u68c0\u6d4b\u6b63\u786e\u7684\u8bbe\u5907\uff0c\u800c\u65e0\u9700\u4f7f\u7528 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">devices<\/code> \u9009\u9879\u624b\u52a8\u6307\u5b9a\u8bbe\u5907\u3002\u4f7f\u7528\u540e\u4e00\u4e2a\u9009\u9879\u65f6\uff0c\u65e0\u6cd5\u5bf9\u8bbe\u5907\u540d\u79f0\u8fdb\u884c\u4e00\u81f4\u6027\u7684\u547d\u540d\u89c4\u8303\uff0c\u4f8b\u5982\uff1a\u65e0\u6cd5\u4f7f\u7528\u5171\u540c\u524d\u7f00\u6b63\u5219\u8868\u8fbe\u5f0f\u5bf9\u8bbe\u5907\u547d\u540d\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u670d\u52a1\u540e\u7aef\u6d41\u91cf\u7684\u4f18\u96c5\u7ec8\u6b62<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-8647000f2e6e201ce2fb80b544a8560b.gif'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-8647000f2e6e201ce2fb80b544a8560b.gif\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.46195652173913043\" data-type=\"gif\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">\u4f18\u96c5\u7ec8\u6b62\u7684\u793a\u610f\u56fe<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Kubernetes \u53ef\u4ee5\u51fa\u4e8e\u591a\u79cd\u539f\u56e0\u7ec8\u6b62 Pod\uff0c\u5982\u6eda\u52a8\u66f4\u65b0\u3001\u7f29\u5bb9\u6216\u7528\u6237\u53d1\u8d77\u7684\u5220\u9664\u3002\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u91cd\u8981\u7684\u662f\u8981\u4f18\u96c5\u5730\u7ec8\u6b62\u4e0e Pod \u7684\u6d3b\u8dc3\u8fde\u63a5\uff0c\u8ba9\u5e94\u7528\u7a0b\u5e8f\u6709\u65f6\u95f4\u5b8c\u6210\u8bf7\u6c42\u4ee5\u6700\u5927\u7a0b\u5ea6\u5730\u51cf\u5c11\u4e2d\u65ad\u3002\u5f02\u5e38\u8fde\u63a5\u7ec8\u6b62\u4f1a\u5bfc\u81f4\u6570\u636e\u4e22\u5931\uff0c\u6216\u5ef6\u8fdf\u5e94\u7528\u7a0b\u5e8f\u7684\u6062\u590d\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium agent \u901a\u8fc7 &#8220;EndpointSlice&#8221; API \u76d1\u542c service \u7aef\u70b9\u66f4\u65b0\u3002\u5f53\u4e00\u4e2a service \u7aef\u70b9\u88ab\u7ec8\u6b62\u65f6\uff0cKubernetes \u4e3a\u8be5\u7aef\u70b9\u8bbe\u7f6e <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">terminating<\/code> \u72b6\u6001\u3002\u7136\u540e\uff0cCilium agent \u5220\u9664\u8be5\u7aef\u70b9\u7684\u6570\u636e\u8def\u5f84\u72b6\u6001\uff0c\u8fd9\u6837\u7aef\u70b9\u5c31\u4e0d\u4f1a\u88ab\u9009\u62e9\u7528\u4e8e\u65b0\u7684\u8bf7\u6c42\uff0c\u4f46\u8be5\u7aef\u70b9\u6b63\u5728\u670d\u52a1\u7684\u5f53\u524d\u8fde\u63a5\uff0c\u53ef\u4ee5\u5728\u7528\u6237\u5b9a\u4e49\u7684\u5bbd\u9650\u671f\u5185\u88ab\u7ec8\u6b62\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u540c\u65f6\uff0cKubernetes \u544a\u77e5\u5bb9\u5668\u8fd0\u884c\u65f6\u5411\u670d\u52a1\u7684 Pod \u5bb9\u5668\u53d1\u9001 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">SIGTERM<\/code> \u4fe1\u53f7\uff0c\u5e76\u7b49\u5f85\u7ec8\u6b62\u5bbd\u9650\u671f\u7684\u5230\u6765\u3002\u7136\u540e\uff0c\u5bb9\u5668\u5e94\u7528\u7a0b\u5e8f\u53ef\u4ee5\u542f\u52a8\u6d3b\u8dc3\u8fde\u63a5\u7684\u4f18\u96c5\u7ec8\u6b62\uff0c\u4f8b\u5982\uff0c\u5173\u95ed TCP \u5957\u63a5\u5b57\u3002\u4e00\u65e6\u5bbd\u9650\u671f\u7ed3\u675f\uff0cKubernetes \u6700\u7ec8\u901a\u8fc7 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">SIGKILL<\/code> \u4fe1\u53f7\u5bf9\u4ecd\u5728 Pod \u5bb9\u5668\u4e2d\u8fd0\u884c\u7684\u8fdb\u7a0b\u89e6\u53d1\u5f3a\u5236\u5173\u95ed\u3002\u8fd9\u65f6\uff0cagent \u4e5f\u4f1a\u6536\u5230\u7aef\u70b9\u7684\u5220\u9664\u4e8b\u4ef6\uff0c\u7136\u540e\u5b8c\u5168\u5220\u9664\u7aef\u70b9\u7684\u6570\u636e\u8def\u5f84\u72b6\u6001\u3002\u4f46\u662f\uff0c\u5982\u679c\u5e94\u7528 Pod \u5728\u5bbd\u9650\u671f\u7ed3\u675f\u524d\u9000\u51fa\uff0cKubernetes \u5c06\u7acb\u5373\u53d1\u9001\u5220\u9664\u4e8b\u4ef6\uff0c\u800c\u4e0d\u7ba1\u5bbd\u9650\u671f\u8bbe\u7f6e\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u66f4\u591a\u7ec6\u8282\u8bf7\u5173\u6ce8 <span style=\"font-weight: bold; color: #00a971;\">docs.cilium.io<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[42]<\/sup> \u4e2d\u7684\u6307\u5357\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Egress \u51fa\u53e3\u7f51\u5173\u7684\u4f18\u5316<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-851a32a507bd1eb32655f4f25d617ebb.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-851a32a507bd1eb32655f4f25d617ebb.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.48233695652173914\" data-type=\"png\" data-w=\"1472\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">Egress \u51fa\u53e3\u7f51\u5173\u7684\u4f18\u5316<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u7b80\u5355\u7684\u573a\u666f\u4e2d\uff0cKubernetes \u5e94\u7528\u53ea\u4e0e\u5176\u4ed6 Kubernetes \u5e94\u7528\u8fdb\u884c\u901a\u4fe1\uff0c\u56e0\u6b64\u6d41\u91cf\u53ef\u901a\u8fc7\u7f51\u7edc\u7b56\u7565\u7b49\u673a\u5236\u8fdb\u884c\u63a7\u5236\u3002\u4f46\u73b0\u5b9e\u4e16\u754c\u60c5\u51b5\u5e76\u975e\u603b\u662f\u5982\u6b64\uff0c\u4f8b\u5982\uff1a\u79c1\u6709\u90e8\u7f72\u7684\u4e00\u4e9b\u5e94\u7528\u7a0b\u5e8f\u6ca1\u6709\u88ab\u5bb9\u5668\u5316\uff0cKubernetes \u5e94\u7528\u7a0b\u5e8f\u9700\u8981\u4e0e\u96c6\u7fa4\u5916\u7684\u670d\u52a1\u8fdb\u884c\u901a\u4fe1\u3002\u8fd9\u4e9b\u4f20\u7edf\u670d\u52a1\u901a\u5e38\u914d\u7f6e\u7684\u662f\u9759\u6001 IP\uff0c\u5e76\u53d7\u5230\u9632\u706b\u5899\u89c4\u5219\u7684\u4fdd\u62a4\u3002\u90a3\u4e48\u5728\u6b64\u79cd\u60c5\u51b5\u4e0b\uff0c\u5e94\u8be5\u5982\u4f55\u5bf9\u6d41\u91cf\u63a7\u5236\u548c\u5ba1\u8ba1\u5462\uff1f<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Egress \u51fa\u53e3 IP \u7f51\u5173\u529f\u80fd\u5728 <span style=\"font-weight: bold; color: #00a971;\">Cilium 1.10<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[43]<\/sup> \u4e2d\u88ab\u5f15\u5165\uff0c\u901a\u8fc7 Kubernetes \u8282\u70b9\u5145\u5f53\u7f51\u5173\u7528\u4e8e\u96c6\u7fa4\u51fa\u53e3\u6d41\u91cf\u6765\u89e3\u51b3\u8fd9\u7c7b\u95ee\u9898\u3002\u7528\u6237\u4f7f\u7528\u7b56\u7565\u6765\u6307\u5b9a\u54ea\u4e9b\u6d41\u91cf\u5e94\u8be5\u88ab\u8f6c\u53d1\u5230\u7f51\u5173\u8282\u70b9\uff0c\u4ee5\u53ca\u5982\u4f55\u8f6c\u53d1\u6d41\u91cf\u3002\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u7f51\u5173\u8282\u70b9\u5c06\u4f7f\u7528\u9759\u6001\u51fa\u53e3 IP \u5bf9\u6d41\u91cf\u8fdb\u884c\u4f2a\u88c5\uff0c\u56e0\u6b64\u53ef\u4ee5\u5728\u4f20\u7edf\u9632\u706b\u5899\u5efa\u7acb\u89c4\u5219\u3002<\/p>\n<pre style=\"margin-top: 10px; margin-bottom: 10px; margin: 12px auto; border-radius: 5px; box-shadow: 0 1px 2px -2px rgba(0,0,0,.16), 0 3px 6px 0 rgba(0,0,0,.12), 0 5px 12px 4px rgba(0,0,0,.09) !important;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><code style=\"overflow-x: auto; padding: 16px; color: #abb2bf; display: -webkit-box; font-family: Operator Mono, Consolas, Monaco, Menlo, monospace; font-size: 12px; -webkit-overflow-scrolling: touch; padding-top: 15px; background: #282c34; border-radius: 5px;\"><span style=\"color: #d19a66; line-height: 26px;\">apiVersion:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">cilium.io\/v2alpha1<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">kind:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">CiliumEgressNATPolicy<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">metadata:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">name:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">egress-sample<\/span>\r\n<span style=\"color: #d19a66; line-height: 26px;\">spec:<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">egress:<\/span>\r\n\u00a0\u00a0\u00a0\u00a0<span style=\"color: #61aeee; line-height: 26px;\">-<\/span>\u00a0<span style=\"color: #d19a66; line-height: 26px;\">podSelector:<\/span>\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">matchLabels:<\/span>\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">app:<\/span>\u00a0<span style=\"color: #98c379; line-height: 26px;\">test-app<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">destinationCIDRs:<\/span>\r\n\u00a0\u00a0\u00a0\u00a0<span style=\"color: #61aeee; line-height: 26px;\">-<\/span>\u00a0<span style=\"color: #d19a66; line-height: 26px;\">1.2<\/span><span style=\"color: #d19a66; line-height: 26px;\">.3<\/span><span style=\"color: #d19a66; line-height: 26px;\">.0<\/span><span style=\"color: #98c379; line-height: 26px;\">\/24<\/span>\r\n\u00a0\u00a0<span style=\"color: #d19a66; line-height: 26px;\">egressSourceIP:<\/span>\u00a0<span style=\"color: #d19a66; line-height: 26px;\">20.0<\/span><span style=\"color: #d19a66; line-height: 26px;\">.0<\/span><span style=\"color: #d19a66; line-height: 26px;\">.1<\/span>\r\n<\/code><\/pre>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728\u4e0a\u9762\u7684\u793a\u4f8b\u7b56\u7565\u4e2d\uff0c\u5e26\u6709 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">app: test-app<\/code> \u6807\u7b7e\u7684 Pod \u548c\u76ee\u6807 CIDR \u4e3a <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">1.2.3.0\/24<\/code> \u7684\u6d41\u91cf\uff0c\u9700\u8981\u901a\u8fc7 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">20.0.0.1<\/code> \u7f51\u5173\u8282\u70b9\u7684\u51fa\u53e3 IP\uff08SNAT\uff09\u4e0e\u96c6\u7fa4\u5916\u90e8\u901a\u4fe1\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728 Cilium 1.11 \u5f00\u53d1\u5468\u671f\u4e2d\uff0c\u6211\u4eec\u6295\u5165\u4e86\u5927\u91cf\u7cbe\u529b\u6765\u7a33\u5b9a\u51fa\u53e3\u7f51\u5173\u529f\u80fd\uff0c\u4f7f\u5176\u53ef\u6295\u5165\u751f\u4ea7\u3002\u73b0\u5728\uff0c \u51fa\u53e3\u7f51\u5173\u73b0\u5728\u53ef\u4ee5\u5de5\u4f5c\u5728<span style=\"font-weight: bold; color: #00a971;\">\u76f4\u63a5\u8def\u7531<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[44]<\/sup>\uff0c<span style=\"font-weight: bold; color: #00a971;\">\u533a\u5206\u5185\u90e8\u6d41\u91cf<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[45]<\/sup>\uff08\u5373 Kubernetes \u91cd\u53e0\u5730\u5740\u7684 CIDR \u7684\u51fa\u53e3\u7b56\u7565\uff09\u53ca<span style=\"font-weight: bold; color: #00a971;\">\u5728\u4e0d\u540c\u7b56\u7565\u4e2d\u4f7f\u7528\u76f8\u540c\u51fa\u53e3 IP<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[46]<\/sup>\u4e0b\u3002\u4e00\u4e9b\u95ee\u9898\uff0c\u5982<span style=\"font-weight: bold; color: #00a971;\">\u56de\u590d\u88ab\u9519\u8bef\u63cf\u8ff0\u4e3a\u51fa\u53e3\u6d41\u91cf<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[47]<\/sup>\u548c<span style=\"font-weight: bold; color: #00a971;\">\u5176\u4ed6<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[48]<\/sup>\u7b49\u5df2\u7ecf\u4fee\u590d\uff0c\u540c\u65f6\u6d4b\u8bd5\u4e5f\u5f97\u5230\u4e86\u6539\u8fdb\uff0c\u4ee5\u4fbf\u53ca\u65e9\u53d1\u73b0\u6f5c\u5728\u7684\u95ee\u9898\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Kubernetes Cgroup \u589e\u5f3a<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-7497855f78dd7d3291d806faa35f913c.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-7497855f78dd7d3291d806faa35f913c.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.623641304347826\" data-type=\"png\" data-w=\"1472\" \/><\/div><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u4f7f\u7528 <span style=\"font-weight: bold; color: #00a971;\"> eBPF \u66ff\u4ee3 kube-proxy <\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[49]<\/sup> \u4f5c\u4e3a<span style=\"font-weight: bold; color: #00a971;\">\u72ec\u7acb\u8d1f\u8f7d\u5747\u8861\u5668<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[50]<\/sup>\u7684\u4f18\u52bf\u4e4b\u4e00\u662f\u80fd\u591f\u5c06 eBPF \u7a0b\u5e8f\u9644\u52a0\u5230 socket hooks \u4e0a\uff0c\u4f8b\u5982 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">connect(2)<\/code>\u3001<code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">bind(2)<\/code>\u3001<code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">sendmsg(2)<\/code> \u4ee5\u53ca\u5176\u4ed6\u5404\u79cd\u76f8\u5173\u7684\u7cfb\u7edf\u8c03\u7528\uff0c\u4ee5\u4fbf\u900f\u660e\u5730\u5c06\u672c\u5730\u7684\u5e94\u7528\u7a0b\u5e8f\u8fde\u63a5\u5230\u540e\u7aef\u670d\u52a1\u3002\u4f46\u662f\u8fd9\u4e9b\u7a0b\u5e8f\u53ea\u80fd\u88ab\u9644\u52a0\u5230 cgroup v2\u3002\u867d\u7136 Kubernetes \u6b63\u5728\u52aa\u529b\u8fc1\u79fb\u5230 cgroup v2\uff0c\u4f46\u76ee\u524d\u7edd\u5927\u591a\u6570\u7528\u6237\u7684\u73af\u5883\u90fd\u662f cgroup v1 \u548c v2 \u6df7\u5408\u4f7f\u7528\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Linux \u5728\u5185\u6838\u7684 socket \u5bf9\u8c61\u4e2d\u6807\u8bb0\u4e86 socket \u4e0e cgroup \u7684\u5173\u7cfb\uff0c\u5e76\u4e14\u7531\u4e8e 6 \u5e74\u524d\u7684\u4e00\u4e2a\u8bbe\u5b9a\uff0ccgroup v1 \u548c v2 \u7684 socket \u6807\u7b7e\u662f\u4e92\u65a5\u7684\u3002\u8fd9\u5c31\u610f\u5473\u7740\uff0c\u5982\u679c\u4e00\u4e2a socket \u662f\u4ee5 cgroup v2 \u6210\u5458\u8eab\u4efd\u521b\u5efa\u7684\uff0c\u4f46\u540e\u6765\u901a\u8fc7\u5177\u6709 cgroup v1 \u6210\u5458\u8eab\u4efd\u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">net_prio<\/code> \u6216 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">net_cls<\/code> \u63a7\u5236\u5668\u8fdb\u884c\u4e86\u6807\u8bb0\uff0c\u90a3\u4e48 cgroup v2 \u5c31\u4e0d\u4f1a\u6267\u884c\u9644\u52a0\u5728 Pod \u5b50\u8def\u5f84\u4e0a\u7684\u7a0b\u5e8f\uff0c\u800c\u662f\u56de\u9000\u6267\u884c\u9644\u52a0\u5230 cgroup v2 \u5c42\u6b21\u7ed3\u6784 (hierarchy) \u6839\u90e8\u7684 eBPF \u7a0b\u5e8f\u3002\u8fd9\u6837\u5c31\u4f1a\u5bfc\u81f4\u4e00\u4e2a\u5f88\u4e25\u91cd\u7684\u540e\u679c\uff0c\u5982\u679c\u8fde cgroup v2 \u6839\u90e8\u90fd\u6ca1\u6709\u9644\u52a0\u7a0b\u5e8f\uff0c\u90a3\u4e48\u6574\u4e2a cgroup v2 \u5c42\u6b21\u7ed3\u6784 (hierarchy) \u90fd\u4f1a\u88ab\u7ed5\u8fc7\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u73b0\u5982\u4eca\uff0ccgroup v1 \u548c v2 \u4e0d\u80fd\u5e76\u884c\u8fd0\u884c\u7684\u5047\u8bbe\u4e0d\u518d\u6210\u7acb\uff0c\u5177\u4f53\u53ef\u53c2\u8003\u4eca\u5e74\u65e9\u4e9b\u65f6\u5019\u7684 <span style=\"font-weight: bold; color: #00a971;\">Linux Plumbers \u4f1a\u8bae\u6f14\u8bb2<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[51]<\/sup>\u3002\u53ea\u6709\u5728\u6781\u5c11\u6570\u60c5\u51b5\u4e0b\uff0c\u5f53\u88ab\u6807\u8bb0\u4e3a cgroup v2 \u6210\u5458\u8eab\u4efd\u7684 eBPF \u7a0b\u5e8f\u9644\u52a0\u5230 cgroup v2 \u5c42\u6b21\u7ed3\u6784\u7684\u5b50\u7cfb\u7edf\u65f6\uff0cKubernetes \u96c6\u7fa4\u4e2d\u7684 cgroup v1 \u7f51\u7edc\u63a7\u5236\u5668\u624d\u4f1a\u7ed5\u8fc7\u8be5 eBPF \u7a0b\u5e8f\u3002\u4e3a\u4e86\u5728\u6570\u636e\u5305\u5904\u7406\u8def\u5f84\u4e0a\u7684\u5c3d\u91cf\u524d\u9762\uff08early\uff09\u7684\u4f4d\u7f6e\u89e3\u51b3\u8fd9\u4e2a\u95ee\u9898\uff0cCilium \u56e2\u961f\u6700\u8fd1\u5bf9 Linux \u5185\u6838\u8fdb\u884c\u4e86\u4fee\u590d\uff0c\u5b9e\u73b0\u4e86\u5728\u6240\u6709\u573a\u666f\u4e0b\u5141\u8bb8\u4e24\u79cd cgroup \u7248\u672c (<span style=\"font-weight: bold; color: #00a971;\">part1<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[52]<\/sup>, <span style=\"font-weight: bold; color: #00a971;\">part2<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[53]<\/sup>) \u4e4b\u95f4\u76f8\u4e92\u5b89\u5168\u64cd\u4f5c\u3002\u8fd9\u4e2a\u4fee\u590d\u4e0d\u4ec5\u4f7f Cilium \u7684 cgroup \u64cd\u4f5c\u5b8c\u5168\u5065\u58ee\u53ef\u9760\uff0c\u800c\u4e14\u4e5f\u9020\u798f\u4e86 Kubernetes \u4e2d\u6240\u6709\u5176\u4ed6 eBPF cgroup \u7528\u6237\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u6b64\u5916\uff0cKubernetes \u548c Docker \u7b49\u5bb9\u5668\u8fd0\u884c\u65f6\u6700\u8fd1\u5f00\u59cb\u9646\u7eed\u5ba3\u5e03\u652f\u6301 cgroup v2\u3002\u5728 cgroup v2 \u6a21\u5f0f\u4e0b\uff0cDocker \u9ed8\u8ba4\u4f1a\u5207\u6362\u5230<span style=\"font-weight: bold; color: #00a971;\">\u79c1\u6709 cgroup \u547d\u540d\u7a7a\u95f4<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[54]<\/sup>\uff0c\u5373\u6bcf\u4e2a\u5bb9\u5668\uff08\u5305\u62ec Cilium\uff09\u90fd\u5728\u81ea\u5df1\u7684\u79c1\u6709 cgroup \u547d\u540d\u7a7a\u95f4\u4e2d\u8fd0\u884c\u3002Cilium \u901a\u8fc7\u786e\u4fdd eBPF \u7a0b\u5e8f\u9644\u52a0\u5230\u6b63\u786e\u7684 cgroup \u5c42\u6b21\u7ed3\u6784\u7684 socket hooks \u4e0a\uff0c\u4f7f Cilium \u57fa\u4e8e\u5957\u63a5\u5b57\u7684\u8d1f\u8f7d\u5747\u8861\u5728 cgroup v2 \u73af\u5883\u4e2d\u80fd\u6b63\u5e38\u5de5\u4f5c\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u589e\u5f3a\u8d1f\u8f7d\u5747\u8861\u5668\u7684\u53ef\u6269\u5c55\u6027<\/span><\/h2>\n<blockquote style=\"border-top: none; border-right: none; border-bottom: none; font-size: 0.9em; overflow: auto; background: rgba(66, 184, 131, 0.1); color: #6a737d; margin: 1.5em 0.2rem 1.5rem; padding-top: 0px; padding-left: 1.42188rem; border-left-width: 0.32813rem; border-left-color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<p style=\"padding-top: 8px; padding-bottom: 8px; font-size: 15px; word-spacing: 3px; letter-spacing: 1px; color: black; line-height: 26px;\">\u4e3b\u8981\u5916\u90e8\u8d21\u732e\u8005\uff1aWeilong Cui (Google)<\/p>\n<\/blockquote>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u6700\u8fd1\u7684\u6d4b\u8bd5\u8868\u660e\uff0c\u5bf9\u4e8e\u8fd0\u884c\u7740 Cilium \u4e14 Kubernetes Endpoints \u8d85\u8fc7 6.4 \u4e07\u7684\u5927\u578b Kubernetes \u73af\u5883\uff0cService \u8d1f\u8f7d\u5747\u8861\u5668\u4f1a\u53d7\u5230\u9650\u5236\u3002\u6709\u4e24\u4e2a\u9650\u5236\u56e0\u7d20\uff1a<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\">Cilium \u4f7f\u7528 eBPF \u66ff\u4ee3 kube-proxy \u7684\u72ec\u7acb\u8d1f\u8f7d\u5747\u8861\u5668\u7684\u672c\u5730\u540e\u7aef ID \u5206\u914d\u5668\u4ecd\u88ab\u9650\u5236\u5728 16 \u4f4d ID \u7a7a\u95f4\u5185\u3002<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\">Cilium \u7528\u4e8e IPv4 \u548c IPv6 \u7684 eBPF datapath \u540e\u7aef\u6620\u5c04\u6240\u4f7f\u7528\u7684\u5bc6\u94a5\u7c7b\u578b\u88ab\u9650\u5236\u5728 16 \u4f4d ID \u7a7a\u95f4\u5185\u3002<\/section>\n<\/li>\n<\/ul>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4e3a\u4e86\u4f7f Kubernetes \u96c6\u7fa4\u80fd\u591f\u6269\u5c55\u5230\u8d85\u8fc7 6.4 \u4e07 Endpoints\uff0cCilium \u7684 ID \u5206\u914d\u5668\u4ee5\u53ca\u76f8\u5173\u7684 datapath \u7ed3\u6784\u5df2\u88ab\u8f6c\u6362\u4e3a\u4f7f\u7528 32 \u4f4d ID \u7a7a\u95f4\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Cilium Endpoint Slices<\/span><\/h2>\n<blockquote style=\"border-top: none; border-right: none; border-bottom: none; font-size: 0.9em; overflow: auto; background: rgba(66, 184, 131, 0.1); color: #6a737d; margin: 1.5em 0.2rem 1.5rem; padding-top: 0px; padding-left: 1.42188rem; border-left-width: 0.32813rem; border-left-color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<p style=\"padding-top: 8px; padding-bottom: 8px; font-size: 15px; word-spacing: 3px; letter-spacing: 1px; color: black; line-height: 26px;\">\u4e3b\u8981\u5916\u90e8\u8d21\u732e\u8005\uff1aWeilong Cui (Google), Gobinath Krishnamoorthy (Google)<\/p>\n<\/blockquote>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728 1.11 \u7248\u672c\u4e2d\uff0cCilium \u589e\u52a0\u4e86\u5bf9\u65b0\u64cd\u4f5c\u6a21\u5f0f\u7684\u652f\u6301\uff0c\u8be5\u6a21\u5f0f\u901a\u8fc7\u66f4\u6709\u6548\u7684 Pod \u4fe1\u606f\u5e7f\u64ad\u65b9\u5f0f\u5927\u5927\u63d0\u9ad8\u4e86 Cilium \u7684\u6269\u5c55\u80fd\u529b\u3002<\/p>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-edc8b6056acc2a47b5e53c4f4ecaf1ee.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-edc8b6056acc2a47b5e53c4f4ecaf1ee.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.7105978260869565\" data-type=\"png\" data-w=\"1472\" \/><\/div><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4e4b\u524d\uff0cCilium \u901a\u8fc7 watch <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CiliumEndpoint (CEP)<\/code> \u5bf9\u8c61\u6765\u5e7f\u64ad Pod \u7684 IP \u5730\u5740\u548c\u5b89\u5168\u8eab\u4efd\u4fe1\u606f\uff0c\u8fd9\u79cd\u505a\u6cd5\u5728\u53ef\u6269\u5c55\u6027\u65b9\u9762\u4f1a\u5e26\u6765\u4e00\u5b9a\u7684\u6311\u6218\u3002\u6bcf\u4e2a <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEP<\/code> \u5bf9\u8c61\u7684\u521b\u5efa\/\u66f4\u65b0\/\u5220\u9664\u90fd\u4f1a\u89e6\u53d1 watch \u4e8b\u4ef6\u7684\u7ec4\u64ad\uff0c\u5176\u89c4\u6a21\u4e0e\u96c6\u7fa4\u4e2d Cilium-agent \u7684\u6570\u91cf\u5448\u7ebf\u6027\u5173\u7cfb\uff0c\u800c\u6bcf\u4e2a Cilium-agent \u90fd\u53ef\u4ee5\u89e6\u53d1\u8fd9\u6837\u7684\u6247\u51fa\u52a8\u4f5c\u3002\u5982\u679c\u96c6\u7fa4\u4e2d\u6709 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">N<\/code> \u4e2a\u8282\u70b9\uff0c\u603b watch \u4e8b\u4ef6\u548c\u6d41\u91cf\u53ef\u80fd\u4f1a\u4ee5 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">N^2<\/code> \u7684\u901f\u7387\u4e8c\u6b21\u6269\u5c55\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium 1.11 \u5f15\u5165\u4e86\u4e00\u4e2a\u65b0\u7684 CRD <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CiliumEndpointSlice (CES)<\/code>\uff0c\u6765\u81ea\u540c\u4e00\u547d\u540d\u7a7a\u95f4\u4e0b\u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEPs<\/code> \u5207\u7247\u4f1a\u88ab Operator \u7ec4\u5408\u6210 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CES<\/code> \u5bf9\u8c61\u3002\u5728\u8fd9\u79cd\u6a21\u5f0f\u4e0b\uff0cCilium-agents \u4e0d\u518d watch <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEP<\/code>\uff0c\u800c\u662f watch <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CES<\/code>\uff0c\u5927\u5927\u51cf\u5c11\u4e86\u9700\u8981\u7ecf\u7531 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">kube-apiserver<\/code> \u5e7f\u64ad\u7684 watch \u4e8b\u4ef6\u548c\u6d41\u91cf\uff0c\u8fdb\u800c\u51cf\u8f7b <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">kube-apiserver<\/code> \u7684\u538b\u529b\uff0c\u589e\u5f3a Cilium \u7684\u53ef\u6269\u5c55\u6027\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u7531\u4e8e <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEP<\/code> \u5927\u5927\u51cf\u8f7b\u4e86 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">kube-apiserver<\/code> \u7684\u538b\u529b\uff0cCilium \u73b0\u5728\u5df2\u7ecf\u4e0d\u518d\u4f9d\u8d56\u4e13\u7528\u7684 ETCD \u5b9e\u4f8b\uff08KVStore \u6a21\u5f0f\uff09\u3002\u5bf9\u4e8e Pod \u6570\u91cf\u5267\u70c8\u53d8\u5316\u7684\u96c6\u7fa4\uff0c\u6211\u4eec\u4ecd\u7136\u5efa\u8bae\u4f7f\u7528 KVStore\uff0c\u4ee5\u4fbf\u5c06 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">kube-apiserver<\/code> \u4e2d\u7684\u5904\u7406\u5de5\u4f5c\u5378\u8f7d\u5230 ETCD \u5b9e\u4f8b\u4e2d\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8fd9\u79cd\u6a21\u5f0f\u6743\u8861\u4e86\u201c\u66f4\u5feb\u5730\u4f20\u64ad Endpoint \u4fe1\u606f\u201d\u548c\u201c\u6269\u5c55\u6027\u66f4\u5f3a\u7684\u63a7\u5236\u5e73\u9762\u201d\u8fd9\u4e24\u4e2a\u65b9\u9762\uff0c\u5e76\u529b\u6c42\u96e8\u9732\u5747\u6cbe\u3002\u6ce8\u610f\uff0c\u4e0e <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEP<\/code> \u6a21\u5f0f\u76f8\u6bd4\uff0c\u5728\u89c4\u6a21\u8f83\u5927\u65f6\uff0c\u5982\u679c Pod \u6570\u91cf\u5267\u70c8\u53d8\u5316\uff08\u4f8b\u5982\u5927\u89c4\u6a21\u6269\u7f29\u5bb9\uff09\uff0c\u53ef\u80fd\u4f1a\u4ea7\u751f\u8f83\u9ad8\u7684 Endpoint \u4fe1\u606f\u4f20\u64ad\u5ef6\u8fdf\uff0c\u4ece\u800c\u5f71\u54cd\u5230\u8fdc\u7a0b\u8282\u70b9\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">GKE \u6700\u65e9\u91c7\u7528\u4e86 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CES<\/code>\uff0c\u6211\u4eec\u5728 GKE \u4e0a\u8fdb\u884c\u4e86\u4e00\u7cfb\u5217\u201c\u6700\u574f\u60c5\u51b5\u201d\u89c4\u6a21\u6d4b\u8bd5\uff0c\u53d1\u73b0 Cilium \u5728 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CES<\/code> \u6a21\u5f0f\u4e0b\u7684\u6269\u5c55\u6027\u8981\u6bd4 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CEP<\/code> \u6a21\u5f0f\u5f3a\u5f88\u591a\u3002\u4ece 1000 \u8282\u70b9\u89c4\u6a21\u7684\u8d1f\u8f7d\u6d4b\u8bd5\u6765\u770b\uff0c\u542f\u7528 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">CES<\/code> \u540e\uff0cwatch \u4e8b\u4ef6\u7684\u5cf0\u503c\u4ece CEP \u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">18k\/s<\/code> \u964d\u4f4e\u5230 CES \u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">8k\/s<\/code>\uff0cwatch \u6d41\u91cf\u5cf0\u503c\u4ece CEP \u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">36.6Mbps<\/code> \u964d\u4f4e\u5230 CES \u7684 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">18.1Mbps<\/code>\u3002\u5728\u63a7\u5236\u5668\u8282\u70b9\u8d44\u6e90\u4f7f\u7528\u65b9\u9762\uff0c\u5b83\u5c06 CPU \u7684\u5cf0\u503c\u4f7f\u7528\u91cf\u4ece 28 \u6838\/\u79d2\u51cf\u5c11\u5230 10.5 \u6838\/\u79d2\u3002<\/p>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-b9629645c4b031dc411ae44946f52026.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-b9629645c4b031dc411ae44946f52026.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.18473193473193472\" data-type=\"png\" data-w=\"3432\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">GKE \u4e2d 1000 \u4e2a\u8282\u70b9\u89c4\u6a21\u7684\u8d1f\u8f7d\u6d4b\u8bd5\u4e2d\u7684 CEP watch \u4e8b\u4ef6\u548c\u6d41\u91cf<\/figcaption><\/figure>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-3ff45a9e18056fc87fa54717b1d3b4fe.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-3ff45a9e18056fc87fa54717b1d3b4fe.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.1787579802669762\" data-type=\"png\" data-w=\"3446\" \/><\/div><figcaption style=\"margin-top: 5px; text-align: center; font-size: 14px; margin: 12px auto; color: #999999;\">GKE \u4e2d 1000 \u4e2a\u8282\u70b9\u89c4\u6a21\u7684\u8d1f\u8f7d\u6d4b\u8bd5\u4e2d\u7684 CEP \u548c CES watch \u4e8b\u4ef6\u548c\u6d41\u91cf<\/figcaption><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8be6\u60c5\u8bf7\u53c2\u8003 <span style=\"font-weight: bold; color: #00a971;\">Cilium \u5b98\u65b9\u6587\u6863<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[55]<\/sup>\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">Kube-Proxy-Replacement \u652f\u6301 Istio<\/span><\/h2>\n<figure style=\"margin-top: 10px; margin-bottom: 10px; display: flex; flex-direction: column; justify-content: center; align-items: center;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><div class='fancybox-wrapper lazyload-container-unload' data-fancybox='post-images' href='https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-e49391fe17210bac80798850cb251530.png'><img class=\"lazyload lazyload-style-1\" src=\"data:image\/svg+xml;base64,PCEtLUFyZ29uTG9hZGluZy0tPgo8c3ZnIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgc3Ryb2tlPSIjZmZmZmZmMDAiPjxnPjwvZz4KPC9zdmc+\"  decoding=\"async\" class=\"rich_pages wxw-img\" style=\"display: block; border-radius: 5px; margin: 12px auto;\" data-original=\"https:\/\/www.xh86.me\/wp-content\/uploads\/2021\/12\/wxsync-2021-12-e49391fe17210bac80798850cb251530.png\" src=\"data:image\/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsQAAA7EAZUrDhsAAAANSURBVBhXYzh8+PB\/AAffA0nNPuCLAAAAAElFTkSuQmCC\" data-ratio=\"0.845108695652174\" data-type=\"png\" data-w=\"1472\" \/><\/div><\/figure>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8bb8\u591a\u7528\u6237\u5728 Kubernetes \u4e2d\u4f7f\u7528 eBPF \u81ea\u5e26\u7684\u8d1f\u8f7d\u5747\u8861\u5668\u6765<span style=\"font-weight: bold; color: #00a971;\">\u66ff\u4ee3 kube-proxy<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[56]<\/sup>\uff0c\u4eab\u53d7\u57fa\u4e8e eBPF \u7684 datapath \u5e26\u6765\u7684<span style=\"font-weight: bold; color: #00a971;\">\u9ad8\u6548\u5904\u7406\u65b9\u5f0f<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[57]<\/sup>\uff0c\u907f\u514d\u4e86 kube-proxy \u968f\u7740\u96c6\u7fa4\u89c4\u6a21\u7ebf\u6027\u589e\u957f\u7684 iptables \u89c4\u5219\u94fe\u6761\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">eBPF \u5bf9 Kubernetes Service \u8d1f\u8f7d\u5747\u8861\u7684\u5904\u7406\u5728\u67b6\u6784\u4e0a\u5206\u4e3a<span style=\"font-weight: bold; color: #00a971;\">\u4e24\u4e2a\u90e8\u5206<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[58]<\/sup>\uff1a<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\">\u5904\u7406\u8fdb\u5165\u96c6\u7fa4\u7684\u5916\u90e8\u670d\u52a1\u6d41\u91cf\uff08\u5357\u5317\u65b9\u5411\uff09<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\">\u5904\u7406\u6765\u81ea\u96c6\u7fa4\u5185\u90e8\u7684\u670d\u52a1\u6d41\u91cf\uff08\u4e1c\u897f\u65b9\u5411\uff09<\/section>\n<\/li>\n<\/ul>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u5728 eBPF \u7684\u52a0\u6301\u4e0b\uff0cCilium \u5728\u5357\u5317\u65b9\u5411\u5df2\u7ecf\u5b9e\u73b0\u4e86\u5c3d\u53ef\u80fd\u9760\u8fd1\u9a71\u52a8\u5c42\uff08\u4f8b\u5982\u901a\u8fc7 XDP\uff09\u5b8c\u6210\u5bf9\u6bcf\u4e2a\u6570\u636e\u5305\u7684\u5904\u7406\uff1b\u4e1c\u897f\u6d41\u91cf\u7684\u5904\u7406\u5219\u5c3d\u53ef\u80fd\u9760\u8fd1 eBPF \u5e94\u7528\u5c42\uff0c\u5904\u7406\u65b9\u5f0f\u662f\u5c06\u5e94\u7528\u7a0b\u5e8f\u7684\u8bf7\u6c42\uff08\u4f8b\u5982 TCP <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">connect(2)<\/code>\uff09\u4ece Service \u865a\u62df IP \u76f4\u63a5\u201c\u8fde\u63a5\u201d\u5230\u540e\u7aef IP \u4e4b\u4e00\uff0c\u4ee5\u907f\u514d\u6bcf\u4e2a\u6570\u636e\u5305\u7684 NAT \u8f6c\u6362\u6210\u672c\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">Cilium \u7684\u8fd9\u79cd\u5904\u7406\u65b9\u5f0f\u9002\u7528\u4e8e\u5927\u591a\u6570\u573a\u666f\uff0c\u4f46\u8fd8\u662f\u6709\u4e00\u4e9b\u4f8b\u5916\uff0c\u6bd4\u5982\u5e38\u89c1\u7684\u670d\u52a1\u7f51\u683c\u89e3\u51b3\u65b9\u6848\uff08Istio \u7b49\uff09\u3002Istio \u4f9d\u8d56 iptables \u5728 Pod \u7684\u7f51\u7edc\u547d\u540d\u7a7a\u95f4\u4e2d\u63d2\u5165\u989d\u5916\u7684\u91cd\u5b9a\u5411\u89c4\u5219\uff0c\u4ee5\u4fbf\u5e94\u7528\u6d41\u91cf\u5728\u79bb\u5f00 Pod \u8fdb\u5165\u4e3b\u673a\u547d\u540d\u7a7a\u95f4\u4e4b\u524d\u9996\u5148\u5230\u8fbe\u4ee3\u7406 Sidecar\uff08\u4f8b\u5982 Envoy\uff09\uff0c\u7136\u540e\u901a\u8fc7 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">SO_ORIGINAL_DST<\/code> \u4ece\u5176\u5185\u90e8 socket \u76f4\u63a5<span style=\"font-weight: bold; color: #00a971;\">\u67e5\u8be2<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[59]<\/sup> Netfilter \u8fde\u63a5\u8ddf\u8e2a\u5668\uff0c\u4ee5\u6536\u96c6\u539f\u59cb\u670d\u52a1\u76ee\u7684\u5730\u5740\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u6240\u4ee5\u5728 Istio \u7b49\u670d\u52a1\u7f51\u683c\u573a\u666f\u4e0b\uff0cCilium \u6539\u8fdb\u4e86\u5bf9 Pod \u4e4b\u95f4\uff08\u4e1c\u897f\u65b9\u5411\uff09\u6d41\u91cf\u7684\u5904\u7406\u65b9\u5f0f\uff0c\u6539\u6210\u57fa\u4e8e eBPF \u7684 DNAT \u5b8c\u6210\u5bf9\u6bcf\u4e2a\u6570\u636e\u5305\u7684\u5904\u7406\uff0c\u800c\u4e3b\u673a\u547d\u540d\u7a7a\u95f4\u5185\u7684\u5e94\u7528\u4ecd\u7136\u53ef\u4ee5\u4f7f\u7528\u57fa\u4e8e socket \u7684\u8d1f\u8f7d\u5747\u8861\u5668\uff0c\u4ee5\u907f\u514d\u6bcf\u4e2a\u6570\u636e\u5305\u7684 NAT \u8f6c\u6362\u6210\u672c\u3002<\/p>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u8981\u60f3\u5f00\u542f\u8fd9\u4e2a\u7279\u6027\uff0c\u53ea\u9700\u5728\u65b0\u7248 Cilium agent \u7684 Helm Chart \u4e2d\u8bbe\u7f6e <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">bpf-lb-sock-hostns-only: true<\/code> \u5373\u53ef\u3002\u8be6\u7ec6\u6b65\u9aa4\u8bf7\u53c2\u8003 <span style=\"font-weight: bold; color: #00a971;\">Cilium \u5b98\u65b9\u6587\u6863<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[60]<\/sup>\u3002<\/p>\n<h2 style=\"font-size: 22px; margin-top: 24px; margin-bottom: 12px; font-weight: bold; border-bottom: 4px solid #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\"><span style=\"display: flex; color: #00a971; font-size: 20px;\">\u7279\u6027\u589e\u5f3a\u4e0e\u5f03\u7528<\/span><\/h2>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4ee5\u4e0b\u7279\u6027\u5f97\u5230\u4e86\u8fdb\u4e00\u6b65\u589e\u5f3a\uff1a<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u4e3b\u673a\u9632\u706b\u5899<\/strong> (Host Firewall) \u4ece\u6d4b\u8bd5\u7248 (beta) \u8f6c\u4e3a\u7a33\u5b9a\u7248 (stable)\u3002\u4e3b\u673a\u9632\u706b\u5899\u901a\u8fc7\u5141\u8bb8 <span style=\"font-weight: bold; color: #00a971;\">CiliumClusterwideNetworkPolicies<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[61]<\/sup> \u9009\u62e9\u96c6\u7fa4\u8282\u70b9\u6765\u4fdd\u62a4\u4e3b\u673a\u7f51\u7edc\u547d\u540d\u7a7a\u95f4\u3002\u81ea\u4ece\u5f15\u5165\u4e3b\u673a\u9632\u706b\u5899\u529f\u80fd\u4ee5\u6765\uff0c\u6211\u4eec\u5df2\u7ecf\u5927\u5927\u589e\u52a0\u4e86\u6d4b\u8bd5\u8986\u76d6\u7387\uff0c\u5e76\u4fee\u590d\u4e86\u90e8\u5206\u9519\u8bef\u3002\u6211\u4eec\u8fd8\u6536\u5230\u4e86\u90e8\u5206\u793e\u533a\u7528\u6237\u7684\u53cd\u9988\uff0c\u4ed6\u4eec\u5bf9\u8fd9\u4e2a\u529f\u80fd\u5f88\u6ee1\u610f\uff0c\u5e76\u51c6\u5907\u7528\u4e8e\u751f\u4ea7\u73af\u5883\u3002<\/section>\n<\/li>\n<\/ul>\n<p style=\"padding-top: 8px; padding-bottom: 8px; line-height: 26px; word-spacing: 3px; letter-spacing: 1px; color: #424b5d;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\u4ee5\u4e0b\u7279\u6027\u5df2\u7ecf\u88ab\u5f03\u7528\uff1a<\/p>\n<ul class=\"list-paddingleft-2\" style=\"padding-left: 24px; color: #00a971;\" data-tool=\"mdnice\u7f16\u8f91\u5668\">\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">Consul<\/strong> \u4e4b\u524d\u53ef\u4ee5\u4f5c\u4e3a Cilium \u7684 KVStore \u540e\u7aef\uff0c\u73b0\u5df2\u88ab\u5f03\u7528\uff0c\u63a8\u8350\u4f7f\u7528\u66f4\u7ecf\u5f97\u8d77\u8003\u9a8c\u7684 Etcd \u548c Kubernetes \u4f5c\u4e3a KVStore \u540e\u7aef\u3002\u4e4b\u524d Cilium \u7684\u5f00\u53d1\u8005\u4e3b\u8981\u4f7f\u7528 Consul \u8fdb\u884c\u672c\u5730\u7aef\u5230\u7aef\u6d4b\u8bd5\uff0c\u4f46\u5728\u6700\u8fd1\u7684\u5f00\u53d1\u5468\u671f\u4e2d\uff0c\u5df2\u7ecf\u53ef\u4ee5\u76f4\u63a5\u4f7f\u7528 Kubernetes \u4f5c\u4e3a\u540e\u7aef\u6765\u6d4b\u8bd5\u4e86\uff0cConsul \u53ef\u4ee5\u9000\u4f11\u4e86\u3002<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">IPVLAN<\/strong> \u4e4b\u524d\u7528\u6765\u4f5c\u4e3a veth \u7684\u66ff\u4ee3\u65b9\u6848\uff0c\u7528\u4e8e\u63d0\u4f9b\u8de8\u8282\u70b9 Pod \u7f51\u7edc\u901a\u4fe1\u3002\u5728 Cilium \u793e\u533a\u7684\u63a8\u52a8\u4e0b\uff0c\u5927\u5927\u6539\u8fdb\u4e86 Linux \u5185\u6838\u7684\u6027\u80fd\uff0c\u76ee\u524d veth \u5df2\u7ecf\u548c IPVLAN \u6027\u80fd\u76f8\u5f53\u3002\u5177\u4f53\u53ef\u53c2\u8003\u8fd9\u7bc7\u6587\u7ae0\uff1a<span style=\"font-weight: bold; color: #00a971;\">eBPF \u4e3b\u673a\u8def\u7531<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[62]<\/sup>\u3002<\/section>\n<\/li>\n<li>\n<section style=\"margin-top: 4px; margin-bottom: 4px; line-height: 24px; color: #424b5d;\"><strong style=\"color: #00a971;\">\u7b56\u7565\u8ffd\u8e2a (Policy Tracing)<\/strong> \u5728\u65e9\u671f Cilium \u7248\u672c\u4e2d\u88ab\u5f88\u591a Cilium \u7528\u6237\u4f7f\u7528\uff0c\u53ef\u4ee5\u901a\u8fc7 Pod \u4e2d\u7684\u547d\u4ee4\u884c\u5de5\u5177 <code style=\"font-size: 14px; padding: 2px 5px; margin-right: 2px; margin-left: 2px; font-family: 'Operator Mono', Consolas, Monaco, Menlo, monospace; word-break: break-all; background: #f9f2f4; border-radius: 4px; color: #00a971;\">cilium policy trace<\/code> \u6765\u6267\u884c\u3002\u7136\u800c\u968f\u7740\u65f6\u95f4\u7684\u63a8\u79fb\uff0c\u5b83\u6ca1\u6709\u8ddf\u4e0a Cilium \u7b56\u7565\u5f15\u64ce\u7684\u529f\u80fd\u8fdb\u5c55\u3002Cilium \u73b0\u5728\u63d0\u4f9b\u4e86\u66f4\u597d\u7684\u5de5\u5177\u6765\u8ffd\u8e2a Cilium \u7684\u7b56\u7565\uff0c\u4f8b\u5982<span style=\"font-weight: bold; color: #00a971;\">\u7f51\u7edc\u7b56\u7565\u7f16\u8f91\u5668<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[63]<\/sup>\u548c <span style=\"font-weight: bold; color: #00a971;\">Policy Verdicts<\/span><sup style=\"line-height: 0; font-weight: bold; color: #00a971;\">[64]<\/sup>\u3002<\/section>\n<\/li>\n<\/ul>\n<section data-tool=\"mdnice\u7f16\u8f91\u5668\"><\/section>\n<\/section>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Cilium \u9879\u76ee\u5df2\u9010\u6e10\u6210\u4e3a\u4e07\u4f17\u77a9\u76ee\u4e4b\u661f\uff0c\u6211\u4eec\u5f88\u81ea\u8c6a\u80fd\u591f\u6210\u4e3a\u8be5\u9879\u76ee\u7684\u6838\u5fc3\u4eba\u5458\u3002\u51e0\u5929\u524d\uff0c\u6211\u4eec\u53d1\u5e03\u4e86\u5177\u6709\u8bf8\u591a\u65b0\u529f\u80fd [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12],"tags":[],"class_list":["post-5114","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/posts\/5114","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.xh86.me\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5114"}],"version-history":[{"count":2,"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/posts\/5114\/revisions"}],"predecessor-version":[{"id":5255,"href":"https:\/\/www.xh86.me\/index.php?rest_route=\/wp\/v2\/posts\/5114\/revisions\/5255"}],"wp:attachment":[{"href":"https:\/\/www.xh86.me\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5114"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.xh86.me\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5114"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.xh86.me\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5114"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}