Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

K8S Service getting restart time to time

Hi!

We do have a Service Running on K8S services. Which was developed using Python(Flask), There we use SQL, Redis, and DataStore also. Recently when checking we got to know that service is getting restarted one or few times daily. But the Memory and CPU limits aren't overused. Also on the Code level side, we didn't find any issue regarding this restart issue. 

Are there any solutions that we can try to fix this restart issue on this service. ?

Note: This service gets called on its "/health" endpoint time-to-time, but for that req, the service also sends a response. Screenshot 2022-10-18 at 14.49.41.png

0 2 198
2 REPLIES 2

There might be some issue with your service itself which also not printing debug log. You can try describing pod and check for exit code with error message from its last restart. check https://kubernetes.io/docs/tasks/debug/debug-application/determine-reason-pod-failure/ 

Top Labels in this Space
Top Solution Authors