Pod keeps crashing or unhealthy

0 votes
I've created a kube cluster and I'm trying to deploy a simple application on it but my pod keeps crashing or keep getting unhealthy. Is there a way to track the logs and find the reason behind its crashing?
Oct 26, 2018 in Kubernetes by Hannah
• 14,080 points
44 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

First, take a look at the logs of the current container:

$ kubectl logs ${POD_NAME} ${CONTAINER_NAME}

If your container has previously crashed, you can access the previous container’s crash log with:

$ kubectl logs --previous ${POD_NAME} ${CONTAINER_NAME}

Alternately, you can run commands inside that container with exec:

$ kubectl exec ${POD_NAME} -c ${CONTAINER_NAME} -- ${CMD} ${ARG1} ${ARG2} ... ${ARGN}
answered Oct 26, 2018 by Kalgi
• 36,870 points

Related Questions In Kubernetes

0 votes
2 answers
0 votes
1 answer

Pod not sharing directory - Kubernetes volume Hostpath

he issue was on the volume definition, ...READ MORE

answered Aug 28, 2018 in Kubernetes by Kalgi
• 36,870 points
167 views
0 votes
2 answers

Pod status terminating-Kubernentes

Delete the finalizers block from resource (pod,deployment,ds ...READ MORE

answered Aug 29, 2018 in Kubernetes by Hannah
• 14,080 points
45 views
0 votes
1 answer

Pods IP address from inside a container in the pod

Make sure that your pod yaml file ...READ MORE

answered Aug 29, 2018 in Kubernetes by Kalgi
• 36,870 points
41 views
0 votes
1 answer
0 votes
3 answers

Error while joining cluster with node

Hi Kalgi after following above steps it ...READ MORE

answered Jan 17 in Others by anonymous
809 views
+3 votes
1 answer
0 votes
1 answer

Kubernetes error syncing pod

The issue caused by the docker container ...READ MORE

answered Aug 27, 2018 in Kubernetes by Kalgi
• 36,870 points
516 views
0 votes
1 answer

Define pod yaml dynamically-jenkins pipeline Kubernetes

Try using jinja template engine and python ...READ MORE

answered Aug 28, 2018 in Kubernetes by Kalgi
• 36,870 points
117 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.