I am running Red Hat OCP on a cluster with 5 worker nodes. A lot of my pods will timeout and crash because they fail liveness and readiness probes. I see everywhere people talking about changing the parameters (e.g. timeoutSeconds, periodSeconds, initialDelaySeconds) but I am not able to modify these values in either the OCP console or the terminal. How do I modify these values?
Turns out you can't edit the liveness and readiness parameters of the pod (at least while it's running), which is most likely a defense mechanism against crashing services. What you have to do is edit the deployment or replica set that deployed the pod.
oc edit deploy <my_deployment>
One of two things will occur:
1. The pod will restart automatically
2. You manually delete the pod and it will reinitialize with the new configuration
Reference here: https://kubernetes.io/docs/concepts/cluster-administration/manage-deployment/
You should modify your Pod's template into the DeploymentConfig (see application_health, here's description of parameters).
In addition, you can do it in the WebConsole (Deployment > Actions > Edit Heath Checks) or use 'oc set probe' (use 'oc set probe --help' for more details), e.g.:
oc set probe dc/test --readiness --get-url=http://:8080/health