@@ -31,13 +31,12 @@ replication.
31
31
的数据复制。
32
32
33
33
<!--
34
- **this is not a production configuration**.
35
- In particular, MySQL settings remain on insecure defaults to keep the focus
34
+ **This is not a production configuration**. MySQL settings remain on insecure defaults to keep the focus
36
35
on general patterns for running stateful applications in Kubernetes.
37
36
-->
38
37
{{< note >}}
39
- ** 这不是生产环境下配置 ** 。
40
- 尤其注意, MySQL 设置都使用的是不安全的默认值,这是因为我们想把重点放在 Kubernetes
38
+ ** 这一配置不适合生产环境。 **
39
+ MySQL 设置都使用的是不安全的默认值,这是因为我们想把重点放在 Kubernetes
41
40
中运行有状态应用程序的一般模式上。
42
41
{{< /note >}}
43
42
@@ -110,7 +109,7 @@ kubectl apply -f https://k8s.io/examples/application/mysql/mysql-configmap.yaml
110
109
This ConfigMap provides `my.cnf` overrides that let you independently control
111
110
configuration on the primary MySQL server and its replicas.
112
111
In this case, you want the primary server to be able to serve replication logs to replicas
113
- and you want repicas to reject any writes that don't come via replication.
112
+ and you want replicas to reject any writes that don't come via replication.
114
113
-->
115
114
这个 ConfigMap 提供 ` my.cnf ` 覆盖设置,使你可以独立控制 MySQL 主服务器和副本服务器的配置。
116
115
在这里,你希望主服务器能够将复制日志提供给副本服务器,
@@ -217,7 +216,7 @@ Press **Ctrl+C** to cancel the watch.
217
216
{{< note >}}
218
217
<!--
219
218
If you don't see any progress, make sure you have a dynamic PersistentVolume
220
- provisioner enabled as mentioned in the [prerequisites](#before-you-begin).
219
+ provisioner enabled, as mentioned in the [prerequisites](#before-you-begin).
221
220
-->
222
221
如果你看不到任何进度,确保已启用[ 前提条件] ( #准备开始 )
223
222
中提到的动态 PersistentVolume 制备程序。
@@ -359,7 +358,7 @@ MySQL 本身不提供执行此操作的机制,因此本示例使用了一种
359
358
After the init containers complete successfully, the regular containers run.
360
359
The MySQL Pods consist of a `mysql` container that runs the actual `mysqld`
361
360
server, and an `xtrabackup` container that acts as a
362
- [sidecar](https://kubernetes.io/ blog/2015/06/the-distributed-system-toolkit-patterns).
361
+ [sidecar](/ blog/2015/06/the-distributed-system-toolkit-patterns).
363
362
-->
364
363
### 开始复制
365
364
@@ -701,13 +700,14 @@ kubectl uncordon <节点名称>
701
700
<!--
702
701
## Scaling the number of replicas
703
702
704
- When you use MySQL replication, you can scale your read query capacity by adding replicas.
705
- With StatefulSet, you can do this with a single command:
703
+ When you use MySQL replication, you can scale your read query capacity by
704
+ adding replicas.
705
+ For a StatefulSet, you can achieve this with a single command:
706
706
-->
707
707
## 扩展副本节点数量
708
708
709
709
使用 MySQL 复制时,你可以通过添加副本节点来扩展读取查询的能力。
710
- 使用 StatefulSet,你可以使用单个命令执行此操作 :
710
+ 对于 StatefulSet,你可以使用单个命令实现此目的 :
711
711
712
712
``` shell
713
713
kubectl scale statefulset mysql --replicas=5
0 commit comments