Issue 7287 zookeeper testing probes (#7290)
* Replace old zkOk.sh livenessProbe by zookeeper-ready Fixes one part of the issue #7287 * Update probe script content with the zookeeper-ready Fixes the part with shows/explains the probe script at issue #7287 * Fix the path to delete liveness probe Issue #7287 * Replace zkOk.sh readinessProbe by zookeeper-ready Fixes "Testing for Readiness" section in issue #7287
This commit is contained in:
parent
e2118a7d5b
commit
92079f8358
|
|
@ -798,7 +798,9 @@ The Pod `template` for the `zk` StatefulSet specifies a liveness probe.
|
|||
livenessProbe:
|
||||
exec:
|
||||
command:
|
||||
- "zkOk.sh"
|
||||
- sh
|
||||
- -c
|
||||
- "zookeeper-ready 2181"
|
||||
initialDelaySeconds: 15
|
||||
timeoutSeconds: 5
|
||||
```
|
||||
|
|
@ -809,8 +811,7 @@ word to test the server's health.
|
|||
|
||||
|
||||
```bash
|
||||
ZK_CLIENT_PORT=${ZK_CLIENT_PORT:-2181}
|
||||
OK=$(echo ruok | nc 127.0.0.1 $ZK_CLIENT_PORT)
|
||||
OK=$(echo ruok | nc 127.0.0.1 $1)
|
||||
if [ "$OK" == "imok" ]; then
|
||||
exit 0
|
||||
else
|
||||
|
|
@ -831,7 +832,7 @@ In another window, delete the `zkOk.sh` script from the file system of Pod `zk-0
|
|||
|
||||
|
||||
```shell
|
||||
kubectl exec zk-0 -- rm /opt/zookeeper/bin/zkOk.sh
|
||||
kubectl exec zk-0 -- rm /usr/bin/zookeeper-ready
|
||||
```
|
||||
|
||||
|
||||
|
|
@ -875,7 +876,9 @@ probe from the `zookeeper.yaml` manifest is identical to the liveness probe.
|
|||
readinessProbe:
|
||||
exec:
|
||||
command:
|
||||
- "zkOk.sh"
|
||||
- sh
|
||||
- -c
|
||||
- "zookeeper-ready 2181"
|
||||
initialDelaySeconds: 15
|
||||
timeoutSeconds: 5
|
||||
```
|
||||
|
|
|
|||
Loading…
Reference in New Issue