diff --git a/content/zh/docs/reference/config/analysis/ist0131/index.md b/content/zh/docs/reference/config/analysis/ist0131/index.md index 69d2befb95..b222b34a1c 100644 --- a/content/zh/docs/reference/config/analysis/ist0131/index.md +++ b/content/zh/docs/reference/config/analysis/ist0131/index.md @@ -5,11 +5,11 @@ owner: istio/wg-user-experience-maintainers test: no --- -当 Virtual Service 包含一个永远不会使用的匹配规则时,会出现此消息,因为之前的规则中指定了相同的匹配规则。 +当 VirtualService 包含一条因为旧规则指定了相同的匹配而永远不会使用的匹配规则时,会出现此消息。 -## 示例{#example} +## 示例 {#example} -当您的集群中包含下列 Virtual Service 时: +当您的集群中包含下列 VirtualService 时: {{< text yaml >}} apiVersion: networking.istio.io/v1alpha3 @@ -37,16 +37,17 @@ spec: host: api1.facebook.com {{< /text >}} -您将会收到以下信息: +您将会收到以下消息: {{< text plain >}} Info [IST0131] (VirtualService tls-routing.default) VirtualService rule #1 match #0 is not used (duplicates a match in rule #0). {{< /text >}} -在这个示例中,Virtual Service 对两个不同的目的地指定了相同的匹配规则。Istio 会使用第一个匹配规则,并且不会转发任何流量到第二个目的地。 +在这个示例中,VirtualService 对两个不同的目的地指定了相同的匹配规则。 +Istio 会使用第一个匹配规则,并且不会转发任何流量到第二个目的地。 -## 解决方案{#how-to-resolve} +## 如何修复 {#how-to-resolve} 如果您需要流量能够流向多个目的地,请使用 `mirror`。 -重新排列您的路由,将最具体的路由放在前面。请在最后配置 'catch all' 路由。 +重新排列您的路由,将最具体的路由放在第一个,将 'catch all' 路由放到最后。 diff --git a/content/zh/docs/reference/config/analysis/ist0132/index.md b/content/zh/docs/reference/config/analysis/ist0132/index.md index ef02f5632a..70ceee204a 100644 --- a/content/zh/docs/reference/config/analysis/ist0132/index.md +++ b/content/zh/docs/reference/config/analysis/ist0132/index.md @@ -5,11 +5,11 @@ owner: istio/wg-user-experience-maintainers test: no --- -当一个 Virtual Service 声明了 `host`,但是无法找到相应的网关时,会出现此消息。 +当一个 VirtualService 声明了 `host` 但无法找到相应的网关时,会出现此消息。 -## 示例{#example} +## 示例 {#example} -当您的集群中包含以下 Virtual Service 时: +当您的集群中包含以下 VirtualService 时: {{< text yaml >}} apiVersion: networking.istio.io/v1alpha3 @@ -51,14 +51,15 @@ spec: protocol: HTTP {{< /text >}} -您将会收到以下信息: +您将会收到以下消息: {{< text plain >}} Warning [IST0132] (VirtualService testing-service.default testing.yaml:8) one or more host [wrong.com] defined in VirtualService default/testing-service not found in Gateway istio-system/testing-gateway. {{< /text >}} -在这个示例中, Virtual Service `testing-service` 拥有域名 `wrong.com` ,但是该域名没有声明在网关 `testing-gateway` 中。 +在这个示例中, VirtualService `testing-service` 拥有域名 `wrong.com`, +但是该域名没有声明在网关 `testing-gateway` 中。 -## 解决方案{#how-to-resolve} +## 如何修复 {#how-to-resolve} -确保 Virtual Service 中所有 `hosts` 都已绑定到了相应的网关 `hosts` 中。 +确保 VirtualService 中所有 `hosts` 都已绑定到了相应的网关 `hosts` 中。 diff --git a/content/zh/docs/reference/config/analysis/ist0134/index.md b/content/zh/docs/reference/config/analysis/ist0134/index.md index c719002b5e..6bf090a53f 100644 --- a/content/zh/docs/reference/config/analysis/ist0134/index.md +++ b/content/zh/docs/reference/config/analysis/ist0134/index.md @@ -56,7 +56,7 @@ spec: resolution: DNS {{< /text >}} -## 解决方案 {#how-to-resolve} +## 如何修复 {#how-to-resolve} 请确保在 `protocol` 未设置或设置为 TCP 时,在 ServiceEntry 中设置 `addresses`。 如果未设置 `addresses`,则将匹配 ServiceEntry 所定义的端口上的所有流量,与主机无关。 diff --git a/content/zh/docs/reference/config/analysis/ist0135/index.md b/content/zh/docs/reference/config/analysis/ist0135/index.md index edf8585707..911b297732 100644 --- a/content/zh/docs/reference/config/analysis/ist0135/index.md +++ b/content/zh/docs/reference/config/analysis/ist0135/index.md @@ -5,12 +5,12 @@ owner: istio/wg-user-experience-maintainers test: n/a --- -在 Istio 或 Kubernetes 资源中使用已弃用的 Istio 注解时,会出现该消息。 +在 Istio 或 Kubernetes 资源中使用已弃用的 Istio 注解时,会出现此消息。 -## 解决方案{#how-to-resolve} +## 如何修复 {#how-to-resolve} -当 Istio 控制平面升级时可能会出现该消息。在升级之前,请移除或使用替代方案替换相关注解。 +当 Istio 控制平面升级时可能会出现此消息。在升级之前,请移除或使用替代方案替换相关注解。 关于 Istio 的注解列表,请查阅 [Istio 注解文档](/zh/docs/reference/config/annotations/)。 -Istio 的版本说明中可能存在将被删除注解的建议和替代方案。 +Istio 的版本说明中可能存在已弃用注解的建议和替代方案。 diff --git a/content/zh/docs/reference/config/analysis/ist0136/index.md b/content/zh/docs/reference/config/analysis/ist0136/index.md index d155444629..5161bdca36 100644 --- a/content/zh/docs/reference/config/analysis/ist0136/index.md +++ b/content/zh/docs/reference/config/analysis/ist0136/index.md @@ -7,9 +7,10 @@ test: n/a 当 Istio 或 Kubernetes 资源含有一个实验版本或者缺少性能测试的新注解时,会出现此消息。 -有关 Istio 功能的相对成熟度以及支持等级请查阅 Istio 的[功能状态文档](/zh/about/feature-stages/)。 +有关 Istio 功能的相对成熟度以及支持等级请查阅 Istio +的[功能状态文档](/zh/about/feature-stages/)。 -## 解决方案 {#how-to-resolve} +## 如何修复 {#how-to-resolve} 使用 Alpha 级别的注解并不是问题。这可能是体验 Istio 实验性功能的最好方法。 diff --git a/content/zh/docs/reference/config/analysis/ist0137/index.md b/content/zh/docs/reference/config/analysis/ist0137/index.md index 800b819ce5..547b7c287c 100644 --- a/content/zh/docs/reference/config/analysis/ist0137/index.md +++ b/content/zh/docs/reference/config/analysis/ist0137/index.md @@ -5,11 +5,12 @@ owner: istio/wg-user-experience-maintainers test: n/a --- -当两个 Service 选择了同一个工作负载的同一个目标端口(`targetPort`),但是却指定了不同的服务端口,会出现此消息。 +当两个 Service 选择了同一个工作负载的同一个目标端口(`targetPort`) +但却指定了不同的服务端口 `port`,会出现此消息。 -## 示例{#example} +## 示例 {#example} -在集群包含以下资源时: +以提供以下 Service 的 Istio 网格为例: {{< text yaml >}} apiVersion: v1 @@ -37,11 +38,13 @@ spec: app: nginx {{< /text >}} -在这个示例中,Service `nginx-a` 和 `nginx-b` 选择了工作负载 `nginx` 的同一个目标端口 `80`,但是它们对应的服务端口(`port`)却不一致。 +在这个示例中,Service `nginx-a` 和 `nginx-b` 选择了工作负载 `nginx` +的同一个目标端口 `80`,但是它们对应的服务端口(`port`)却不一致。 -## 如何修复{#how-to-resolve} +## 如何修复 {#how-to-resolve} 修复此问题有两个选择: - 两个 Service 使用相同的端口(`port`)。需要重新配置客户端以连接到修改之后的服务端口。 -- 两个 Service 使用不同的目标端口(`targetPort`)。需要修改工作负载的 Pod 监听到修改之后的目标端口以提供服务。 +- 两个 Service 使用不同的目标端口(`targetPort`)。 + 需要修改工作负载的 Pod 监听到修改之后的目标端口以提供服务。 diff --git a/content/zh/docs/reference/config/analysis/ist0143/index.md b/content/zh/docs/reference/config/analysis/ist0143/index.md index c49606226b..fbf5930a2f 100644 --- a/content/zh/docs/reference/config/analysis/ist0143/index.md +++ b/content/zh/docs/reference/config/analysis/ist0143/index.md @@ -41,7 +41,7 @@ spec: - Node.js:`http.createServer().listen(8080, "localhost");` - Python:`socket.socket().bind(("localhost", 8083))` -## 解决方案 {#how-to-resolve} +## 如何修复 {#how-to-resolve} 如果您不打算将应用程序暴露给其他 Pod,请从 `Service` 中移除该端口。 diff --git a/content/zh/docs/reference/config/analysis/ist0144/index.md b/content/zh/docs/reference/config/analysis/ist0144/index.md index 4b82641644..7390fa9899 100644 --- a/content/zh/docs/reference/config/analysis/ist0144/index.md +++ b/content/zh/docs/reference/config/analysis/ist0144/index.md @@ -5,15 +5,18 @@ owner: istio/wg-user-experience-maintainers test: n/a --- -当工作负载以 User ID (UID) `1337` 运行时,会出现此消息。应用程序的 Pod 不应该以 User ID (UID) `1337` 运行,因为 istio-proxy 容器默认以 UID `1337` 运行。当使用相同的 UID 运行您的容器应用时,将导致它的 `iptables` 配置冲突。 +当工作负载以 User ID (UID) `1337` 运行时,会出现此消息。应用程序的 Pod 不应该以 +User ID (UID) `1337` 运行,因为 istio-proxy 容器默认以 UID `1337` 运行。 +当使用相同的 UID 运行您的容器应用时,将导致它的 `iptables` 配置冲突。 {{< warning >}} -User ID (UID) `1337` 为 Sidecar Proxy 保留。 +User ID (UID) `1337` 保留用于 Sidecar Proxy。 {{< /warning >}} -## 例如{#an-example} +## 示例 {#an-example} -探讨 `Deployment` 和 `securityContext.runAsUser` 使用 UID `1337` 在 Pod 级别或容器级别运行: +探讨设置为 `securityContext.runAsUser` 的 `Deployment` 如何使用 UID `1337` +在 Pod 级别或容器级别运行: {{< text yaml >}} apiVersion: apps/v1 @@ -50,9 +53,10 @@ spec: - containerPort: 5000 {{< /text >}} -## 解决办法{#how-to-resolve} +## 如何修复 {#how-to-resolve} -由于 User ID (UID) `1337` 是为 Sidecar 代理保留的,所以您可以为您的工作负载使用除了 `1337` 以外的 User ID (UID),例如 `1338` 。 +由于 User ID (UID) `1337` 是为 Sidecar 代理保留的,所以您可以为您的工作负载使用除了 +`1337` 以外的 User ID (UID),例如 `1338`。 {{< text yaml >}} apiVersion: apps/v1 diff --git a/content/zh/docs/reference/config/analysis/ist0150/index.md b/content/zh/docs/reference/config/analysis/ist0150/index.md index 6284ca163d..43e1895df1 100644 --- a/content/zh/docs/reference/config/analysis/ist0150/index.md +++ b/content/zh/docs/reference/config/analysis/ist0150/index.md @@ -5,17 +5,12 @@ owner: istio/wg-user-experience-maintainers test: no --- -对于 ExternalName 类型的服务,当端口不遵循 Istio 服务端口命名协议、端口未命名或端口命名为 TCP 时,会出现此消息。 +对于 ExternalName 类型的服务,当端口不遵循 Istio 服务端口命名协议、端口未命名或端口命名为 +TCP 时,会出现此消息。 -## 例如{#example} +## 示例 {#example} -您将收到以下信息: - -{{< text plain >}} -注意,当 [IST0150] (Service nginx.default) ExternalName 服务的端口名称无效。将收到代理对以 TCP 命名和服务于 TCP 协议的端口中的不匹配流量的正确转发进行阻止。 -{{< /text >}} - -当您的集群有以下服务: +当您的集群有以下服务时: {{< text yaml >}} apiVersion: v1 @@ -32,9 +27,18 @@ spec: type: ExternalName {{< /text >}} -在本例中,端口名称 `tcp` 遵循以下语法: `name: ` 。但是,对于 ExternalName 服务,由于没有定义服务 IP,因此需要使用 SNI 字段进行路由。 +您将收到以下信息: -## 解决方式{#how-to-resolve} +{{< text plain >}} +注意,当 [IST0150] (Service nginx.default) ExternalName 服务的端口名称无效。 +将收到代理对以 TCP 命名和服务于 TCP 协议的端口中的不匹配流量的正确转发进行阻止。 +{{< /text >}} -- 如果您有一个服务类型为 ExternalName 并且服务协议为 TCP ,那么将端口重命名为 `[-]` 或者 `` ,其中协议指的是 `https` 或者 `tls` 。想学得更多相关知识, -请查看[显式协议选择](/zh/docs/ops/configuration/traffic-management/protocol-selection/#explicit-protocol-selection)文档。 +在本例中,端口名称 `tcp` 遵循以下语法: `name: `。但是,对于 +ExternalName 服务,由于没有定义服务 IP,因此需要使用 SNI 字段进行路由。 + +## 如何修复 {#how-to-resolve} + +- 如果您有一个服务类型为 ExternalName 并且服务协议为 TCP,那么将端口重命名为 + `[-]` 或者 `` ,其中协议指的是 `https` 或者 `tls`。 + 更多细节请查阅[显式协议选择](/zh/docs/ops/configuration/traffic-management/protocol-selection/#explicit-protocol-selection)文档。