Container Can Be Logged Into

If the DN pod can be logged into normally (or after turning off liveness probes), then after logging in, go to the /data/mysql/log/ directory to primarily inspect the alert.log file.

Container Cannot Be Logged Into

Use the following command to view the startup logs of the dn engine:

kubectl logs {pod name} engine

If you find error messages in the logs indicating that MySQL initialization has failed, then you need to visit the directory of the dn pod on the host machine to check the alert.log file by the following method:

  1. Add the -o wide parameter to locate the machine where the dn pod is located:
kubectl get pod {pod name} -o wide

You will get the output like this:

NAME                         READY   STATUS    RESTARTS   AGE   IP             NODE                          NOMINATED NODE   READINESS GATES
tunan-oss-drsg-dn-0-cand-1   3/3     Running   0          20d   172.16.0.129   cn-zhangjiakou.172.16.0.129   <none>           <none>

Where NODE is the machine the pod is scheduled on.

  1. Execute the following command to get the actual directory of the dn pod on the host machine:
kubectl get pod {pod name} -o json | grep "/data/xstore/default"

Expect to get the following output:

"path": "/data/xstore/default/tunan-oss-drsg-dn-0-cand-1"
  1. Go to the above directory on that machine to view the logs.

results matching ""

    No results matching ""