Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

STS: Mongodb goes into CrashLoopBackOff #197

Open
surajssd opened this issue Jan 31, 2025 · 2 comments
Open

STS: Mongodb goes into CrashLoopBackOff #197

surajssd opened this issue Jan 31, 2025 · 2 comments

Comments

@surajssd
Copy link

Describe the bug

I installed the app using aks-store-all-in-one.yaml config but the mongodb pod goes into CrashLoopBackOff because its liveness probe fails. Liveness check is failing with the following error:

pets 0s Warning Unhealthy pod/mongodb-0 Liveness probe failed: OCI runtime exec failed: exec failed: unable to start container process: exec: "mongosh": executable file not found in $PATH: unknown

To Reproduce
Steps to reproduce the behavior:

  1. Follow steps from: https://github.com/Azure-Samples/aks-store-demo/tree/main?tab=readme-ov-file#run-on-any-kubernetes i.e.:
kubectl create ns pets

kubectl apply -f https://raw.githubusercontent.com/Azure-Samples/aks-store-demo/main/aks-store-all-in-one.yaml -n pets
  1. Run the following to see that the mongodb-0 pod keeps restarting:
kubectl get events -w -n pets

Expected behavior

Pod should pass the liveness probe.

Source of the error

exec:
command:
- mongosh
- --eval
- db.runCommand('ping').ok

@pauldotyu
Copy link
Contributor

@surajssd what type of kubernetes cluster were you running this on?

@surajssd
Copy link
Author

@pauldotyu I was using Minikube.

But this seems like an issue regardless of the k8s kind. This looks like a container image issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants