movesan commented on a change in pull request #16084:
URL: https://github.com/apache/flink/pull/16084#discussion_r646432403



##########
File path: docs/content.zh/docs/deployment/ha/zookeeper_ha.md
##########
@@ -24,113 +24,104 @@ specific language governing permissions and limitations
 under the License.
 -->
 
-# ZooKeeper HA Services
+# ZooKeeper 高可用服务
 
-Flink's ZooKeeper HA services use [ZooKeeper](http://zookeeper.apache.org) for 
high availability services.
+Flink 的 ZooKeeper 高可用服务使用 [ZooKeeper](http://zookeeper.apache.org) 提供高可用服务。
 
-Flink leverages **[ZooKeeper](http://zookeeper.apache.org)** for *distributed 
coordination* between all running JobManager instances. 
-ZooKeeper is a separate service from Flink, which provides highly reliable 
distributed coordination via leader election and light-weight consistent state 
storage. 
-Check out [ZooKeeper's Getting Started 
Guide](http://zookeeper.apache.org/doc/current/zookeeperStarted.html) for more 
information about ZooKeeper. 
-Flink includes scripts to [bootstrap a simple ZooKeeper](#bootstrap-zookeeper) 
installation.
+Flink 利用 **[ZooKeeper](http://zookeeper.apache.org)** 在所有运行的 JobManager 实例之间进行 
*分布式协调*。ZooKeeper 是一个独立于 Flink 的服务,它通过 leader 选举和轻量级的一致性状态存储来提供高可靠的分布式协调。查看 
[ZooKeeper入门指南](http://zookeeper.apache.org/doc/current/zookeeperStarted.html),了解更多关于
 ZooKeeper 的信息。Flink 包含 [启动一个简单的ZooKeeper](#bootstrap-zookeeper) 的安装脚本。
 
-## Configuration
+## 配置
 
-In order to start an HA-cluster you have to configure the following 
configuration keys:
+为了启用高可用集群(HA-cluster),您必须设置以下配置项:
 
-- [high-availability]({{< ref "docs/deployment/config" 
>}}#high-availability-1) (required): 
-The `high-availability` option has to be set to `zookeeper`.
+- [high-availability]({{< ref "docs/deployment/config" 
>}}#high-availability-1) (必要的):
+  `high-availability` 配置项必须设置为 `zookeeper`。
 
   <pre>high-availability: zookeeper</pre>
 
-- [high-availability.storageDir]({{< ref "docs/deployment/config" 
>}}#high-availability-storagedir) (required): 
-JobManager metadata is persisted in the file system 
`high-availability.storageDir` and only a pointer to this state is stored in 
ZooKeeper.
+- [high-availability.storageDir]({{< ref "docs/deployment/config" 
>}}#high-availability-storagedir) (必要的):
+  JobManager 元数据持久化到文件系统 `high-availability.storageDir` 配置的路径中,并且在 ZooKeeper 
中只能有一个目录指向此位置。
 
   <pre>high-availability.storageDir: hdfs:///flink/recovery</pre>
 
-  The `storageDir` stores all metadata needed to recover a JobManager failure.
+  `storageDir` 存储要从 JobManager 失败恢复时所需的所有元数据。
 
-- [high-availability.zookeeper.quorum]({%link deployment/config.md 
%}#high-availability-zookeeper-quorum) (required): 
-A *ZooKeeper quorum* is a replicated group of ZooKeeper servers, which provide 
the distributed coordination service.
+- [high-availability.zookeeper.quorum]({{< ref "docs/deployment/config" 
>}}#high-availability-zookeeper-quorum) (必要的):
+  *ZooKeeper quorum* 是一个提供分布式协调服务的复制组。
 
   <pre>high-availability.zookeeper.quorum: 
address1:2181[,...],addressX:2181</pre>
 
-  Each `addressX:port` refers to a ZooKeeper server, which is reachable by 
Flink at the given address and port.
+  每个 `addressX:port` 指的是一个 ZooKeeper 服务器,它可以被 Flink 在给定的地址和端口上访问。
 
-- [high-availability.zookeeper.path.root]({{< ref "docs/deployment/config" 
>}}#high-availability-zookeeper-path-root) (recommended): 
-The *root ZooKeeper node*, under which all cluster nodes are placed.
+- [high-availability.zookeeper.path.root]({{< ref "docs/deployment/config" 
>}}#high-availability-zookeeper-path-root) (推荐的):
+  *ZooKeeper 根节点*,集群的所有节点都放在该节点下。
 
   <pre>high-availability.zookeeper.path.root: /flink</pre>
 
-- [high-availability.cluster-id]({{< ref "docs/deployment/config" 
>}}#high-availability-cluster-id) (recommended): 
-The *cluster-id ZooKeeper node*, under which all required coordination data 
for a cluster is placed.
+- [high-availability.cluster-id]({{< ref "docs/deployment/config" 
>}}#high-availability-cluster-id) (推荐的):
+  *ZooKeeper cluster-id 节点*,在该节点下放置集群所需的协调数据。
 
   <pre>high-availability.cluster-id: /default_ns # important: customize per 
cluster</pre>
 
-  **Important**: 
-  You should not set this value manually when running on YARN, native 
Kubernetes or on another cluster manager. 
-  In those cases a cluster-id is being automatically generated. 
-  If you are running multiple Flink HA clusters on bare metal, you have to 
manually configure separate cluster-ids for each cluster.
+  **重要**:
+  在 YARN、原生 Kubernetes 
或其他集群管理器上运行时,不应该手动设置此值。在这些情况下,将自动生成一个集群id。如果在未使用集群管理器的机器上运行多个 Flink 
高可用(HA)集群,则必须为每个集群手动配置单独的集群 ID(cluster-ids)。
 
-### Example configuration
+### 配置示例
 
-Configure high availability mode and ZooKeeper quorum in 
`conf/flink-conf.yaml`:
+在 `conf/flink-conf.yaml` 中配置高可用模式和 ZooKeeper 复制组(quorum):
 
 ```bash
 high-availability: zookeeper
 high-availability.zookeeper.quorum: localhost:2181
 high-availability.zookeeper.path.root: /flink
-high-availability.cluster-id: /cluster_one # important: customize per cluster
+high-availability.cluster-id: /cluster_one # 重要: 每个集群自定义
 high-availability.storageDir: hdfs:///flink/recovery
 ```
 
 {{< top >}}
 
-## Configuring for ZooKeeper Security
+## ZooKeeper 安全配置
 
-If ZooKeeper is running in secure mode with Kerberos, you can override the 
following configurations in `flink-conf.yaml` as necessary:
+如果 ZooKeeper 使用 Kerberos 以安全模式运行,必要时可以在 `flink-conf.yaml` 中覆盖以下配置:
 
 ```bash
-# default is "zookeeper". If the ZooKeeper quorum is configured
-# with a different service name then it can be supplied here.
+# 默认配置为 "zookeeper". 如果 ZooKeeper quorum 配置了不同的服务名称,
+# 那么可以替换到这里。
 
-zookeeper.sasl.service-name: zookeeper 
+zookeeper.sasl.service-name: zookeeper
 
-# default is "Client". The value needs to match one of the values
-# configured in "security.kerberos.login.contexts".   
+# 默认配置为 "Client". 该值必须为 "security.kerberos.login.contexts" 项中配置的某一个值。
 zookeeper.sasl.login-context-name: Client  
 ```
 
-For more information on Flink configuration for Kerberos security, please 
refer to the [security section of the Flink configuration page]({{< ref 
"docs/deployment/config" >}}#security).
-You can also find further details on [how Flink sets up Kerberos-based 
security internally]({{< ref "docs/deployment/security/security-kerberos" >}}).
+有关用于 Kerberos 安全性的 Flink 配置的更多信息,请参阅 [Flink 配置页面的安全性部分]({{< ref 
"docs/deployment/config" >}}#security)。您还可以找到关于 [Flink 如何在内部设置基于 kerberos 
的安全性]({{< ref "docs/deployment/security/security-kerberos" >}}) 的详细信息。
 
 {{< top >}}
 
-## ZooKeeper Versions
+## ZooKeeper 版本
 
-Flink ships with separate ZooKeeper clients for 3.4 and 3.5, with 3.4 being in 
the `lib` directory of the distribution
-and thus used by default, whereas 3.5 is placed in the `opt` directory.
+Flink 附带了 3.4 和 3.5 的单独的 ZooKeeper 客户端,其中 3.4 位于发行版的 `lib` 目录中,为默认使用版本,而 3.5 
位于 opt 目录中。
 
-The 3.5 client allows you to secure the ZooKeeper connection via SSL, but 
_may_ not work with 3.4- ZooKeeper installations.
+3.5 客户端允许您通过 SSL 保护 ZooKeeper 连接,但 _可能_ 不适用于 3.4 版本的 ZooKeeper 安装。
 
-You can control which version is used by Flink by placing either jar in the 
`lib` directory.
+您可以通过在 `lib` 目录中放置任意一个 jar 来控制 Flink 使用哪个版本。
 
 {{< top >}}
 
-## Bootstrap ZooKeeper
+<a name="bootstrap-zookeeper" />
 
-If you don't have a running ZooKeeper installation, you can use the helper 
scripts, which ship with Flink.
+## 启动 ZooKeeper
 
-There is a ZooKeeper configuration template in `conf/zoo.cfg`. 
-You can configure the hosts to run ZooKeeper on with the `server.X` entries, 
where X is a unique ID of each server:
+如果你没有安装 ZooKeeper,可以使用 Flink 附带的帮助脚本。
+
+在 `conf/zoo.cfg` 文件中有 ZooKeeper 的配置模板。您可以在 `server.X` 配置项中配置主机来运行 ZooKeeper。其中 
X 是每个服务器的唯一 ID:
 
 ```bash
 server.X=addressX:peerPort:leaderPort
 [...]
 server.Y=addressY:peerPort:leaderPort
 ```
 
-The script `bin/start-zookeeper-quorum.sh` will start a ZooKeeper server on 
each of the configured hosts. 
-The started processes start ZooKeeper servers via a Flink wrapper, which reads 
the configuration from `conf/zoo.cfg` and makes sure to set some required 
configuration values for convenience. 
-In production setups, it is recommended to manage your own ZooKeeper 
installation.
+脚本 `bin/start-zookeeper-quorum.sh` 将在每个配置的主机上启动一个 ZooKeeper 服务器。该进程是通过 Flink 
包装器来启动的 ZooKeeper 服务器,该包装器从 `conf/zoo.cfg` 
读取配置,并确保设置一些必要的配置值以方便使用。在生产设置中,建议您管理自己的 ZooKeeper 安装。

Review comment:
       好建议




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to