@@ -194,18 +194,6 @@ in order to proxy service traffic. If unspecified (0-0) then ports will be rando
194
194
用来设置代理服务所使用的端口。如果未指定(即 ‘0-0’),则代理服务会随机选择端口号。</p >
195
195
</td >
196
196
</tr >
197
- <tr ><td ><code >udpIdleTimeout</code > <B ><!-- [Required]--> [必需]</B ><br />
198
- <a href =" https://pkg.go.dev/k8s.io/apimachinery/pkg/apis/meta/v1#Duration " ><code >meta/v1.Duration</code ></a >
199
- </td >
200
- <td >
201
- <!--
202
- udpIdleTimeout is how long an idle UDP connection will be kept open (e.g. '250ms', '2s').
203
- Must be greater than 0. Only applicable for proxyMode=userspace.
204
- -->
205
- <p ><code >udpIdleTimeout</code > 字段用来设置 UDP 链接保持活跃的时长(例如,'250ms'、'2s')。
206
- 此值必须大于 0。此字段仅适用于 mode 值为 'userspace' 的场合。</p >
207
- </td >
208
- </tr >
209
197
<tr ><td ><code >conntrack</code > <B ><!-- [Required]--> [必需]</B ><br />
210
198
<a href =" #kubeproxy-config-k8s-io-v1alpha1-KubeProxyConntrackConfiguration " ><code >KubeProxyConntrackConfiguration</code ></a >
211
199
</td >
@@ -458,6 +446,15 @@ the pure iptables proxy mode. Values must be within the range [0, 31].
458
446
在使用纯 iptables 代理模式时对所有流量执行 SNAT 操作。</p >
459
447
</td >
460
448
</tr >
449
+ <tr ><td ><code >localhostNodePorts</code > <B ><!-- [Required]--> [必需]</B ><br />
450
+ <code >bool</code >
451
+ </td >
452
+ <td >
453
+ <!-- LocalhostNodePorts tells kube-proxy to allow service NodePorts to be accessed via
454
+ localhost (iptables mode only)-->
455
+ <p >localhostNodePorts 告知 kube-proxy 允许通过 localhost 访问服务 NodePorts(仅 iptables 模式)</p >
456
+ </td >
457
+ </tr >
461
458
<tr ><td ><code >syncPeriod</code > <B ><!-- [Required]--> [必需]</B ><br />
462
459
<a href =" https://pkg.go.dev/k8s.io/apimachinery/pkg/apis/meta/v1#Duration " ><code >meta/v1.Duration</code ></a >
463
460
</td >
@@ -711,40 +708,22 @@ LocalMode 代表的是对节点上本地流量进行检测的模式。
711
708
<!--
712
709
ProxyMode represents modes used by the Kubernetes proxy server.
713
710
714
- Currently, three modes of proxy are available in Linux platform: 'userspace' (older, going to be EOL), 'iptables'
715
- (newer, faster), 'ipvs'(newest, better in performance and scalability).
716
-
717
- Two modes of proxy are available in Windows platform: 'userspace'(older, stable) and 'kernelspace' (newer, faster).
711
+ Currently, two modes of proxy are available on Linux platforms: 'iptables' and 'ipvs'.
712
+ One mode of proxy is available on Windows platforms: 'kernelspace'.
718
713
-->
719
- ProxyMode 表示的是 Kubernetes 代理服务器所使用的模式。
714
+ < p > ProxyMode 表示的是 Kubernetes 代理服务器所使用的模式。</ p >
720
715
721
- 目前 Linux 平台上有三种可用的代理模式:'userspace'(相对较老,即将被淘汰)、
722
- 'iptables'(相对较新,速度较快)、'ipvs'(最新,在性能和可扩缩性上表现好)。
723
-
724
- 在 Windows 平台上有两种可用的代理模式:'userspace'(相对较老,但稳定)和
725
- 'kernelspace'(相对较新,速度更快)。
726
-
727
- <!--
728
- In Linux platform, if proxy mode is blank, use the best-available proxy (currently iptables, but may change in the
729
- future). If the iptables proxy is selected, regardless of how, but the system's kernel or iptables versions are
730
- insufficient, this always falls back to the userspace proxy. IPVS mode will be enabled when proxy mode is set to 'ipvs',
731
- and the fall back path is firstly iptables and then userspace.
732
- -->
733
- 在 Linux 平台上,如果代理的 mode 为空,则使用可用的最佳代理(目前是 iptables,
734
- 将来可能会发生变化)。如果选择的是 iptables 代理(无论原因如何),但系统的内核
735
- 或者 iptables 的版本不够高,kube-proxy 也会回退为 userspace 代理服务器所使用的模式。
736
- 当代理的 mode 设置为 'ipvs' 时会启用 IPVS 模式,对应的回退路径是先尝试 iptables,
737
- 最后回退到 userspace。
716
+ <p >目前 Linux 平台上有两种可用的代理模式:'iptables' 和 'ipvs'。
717
+ 在 Windows 平台上可用的一种代理模式是:'kernelspace'。</p >
738
718
739
719
<!--
740
- In Windows platform, if proxy mode is blank, use the best-available proxy (currently userspace, but may change in the
741
- future). If winkernel proxy is selected, regardless of how, but the Windows kernel can't support this mode of proxy,
742
- this always falls back to the userspace proxy.
720
+ If the proxy mode is unspecified, the best-available proxy mode will be used (currently this
721
+ is <code>iptables</code> on Linux and <code>kernelspace</code> on Windows). If the selected proxy mode cannot be
722
+ used (due to lack of kernel support, missing userspace components, etc) then kube-proxy
723
+ will exit with an error.
743
724
-->
744
- 在 Windows 平台上,如果代理 mode 为空,则使用可用的最佳代理(目前是 userspace,
745
- 不过将来可能会发生变化)。如果所选择的是 winkernel 代理(无论原因如何),
746
- 但 Windows 内核不支持此代理模式,则 kube-proxy 会回退到 userspace 代理。
747
-
725
+ <p >如果代理模式未被指定,将使用最佳可用的代理模式(目前在 Linux 上是 <code >iptables</code >,在 Windows 上是 <code >kernelspace</code >)。
726
+ 如果不能使用选定的代理模式(由于缺少内核支持、缺少用户空间组件等),则 kube-proxy 将出错并退出。</p >
748
727
749
728
## ` ClientConnectionConfiguration ` {#ClientConnectionConfiguration}
750
729
@@ -755,10 +734,12 @@ this always falls back to the userspace proxy.
755
734
756
735
- [ KubeProxyConfiguration] ( #kubeproxy-config-k8s-io-v1alpha1-KubeProxyConfiguration )
757
736
758
- - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta3 -KubeSchedulerConfiguration )
737
+ - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1 -KubeSchedulerConfiguration )
759
738
760
739
- [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta2-KubeSchedulerConfiguration )
761
740
741
+ - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta3-KubeSchedulerConfiguration )
742
+
762
743
- [ GenericControllerManagerConfiguration] ( #controllermanager-config-k8s-io-v1alpha1-GenericControllerManagerConfiguration )
763
744
764
745
<!--
@@ -833,10 +814,12 @@ default value of 'application/json'. This field will control all connections to
833
814
-->
834
815
** 出现在:**
835
816
836
- - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta3 -KubeSchedulerConfiguration )
817
+ - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1 -KubeSchedulerConfiguration )
837
818
838
819
- [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta2-KubeSchedulerConfiguration )
839
820
821
+ - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta3-KubeSchedulerConfiguration )
822
+
840
823
- [ GenericControllerManagerConfiguration] ( #controllermanager-config-k8s-io-v1alpha1-GenericControllerManagerConfiguration )
841
824
842
825
<!--
@@ -886,6 +869,8 @@ enableProfiling is true.
886
869
887
870
- [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1beta3-KubeSchedulerConfiguration )
888
871
872
+ - [ KubeSchedulerConfiguration] ( #kubescheduler-config-k8s-io-v1-KubeSchedulerConfiguration )
873
+
889
874
- [ GenericControllerManagerConfiguration] ( #controllermanager-config-k8s-io-v1alpha1-GenericControllerManagerConfiguration )
890
875
891
876
<!--
0 commit comments