Joshua
1
I am getting this error while deploying in GKE :
Error from server: Get "https://10.x.x.x:10200/containerLogs/server-center/server-center-dev-86f67jkilo-rwrnm/server-center-dev": No agent available
Workload shows pod status as :
Doesn't have minimum availability
Please help, as i am a beginner in GCP.
Simple and Straightforward Answer:
The error:
Error from server: Get "...containerLogs...": No agent available
and
Doesn't have minimum availability
means:
- Your pod failed to start properly, so it’s not available.
- The GKE logging/monitoring agent can’t connect because the pod never became healthy.
How to Fix It:
- Check pod status and logs:
Run:
kubectl get pods
kubectl describe pod <pod-name>
kubectl logs <pod-name>
This will show what’s failing (e.g., crash, image pull, readiness probe, etc.).
2. Common causes to check:
Wrong container image or tag
Missing environment variables
App crashing on startup
Health checks (liveness/readiness) are failing
- Check deployment YAML:
Ensure:
- The image is correct and exists
- All required env vars are set
- Resource limits are not too low
- Probes are not too aggressive (e.g., increase initial delay)
Example to fix readiness probe (common cause):
If you see this in your deployment:
readinessProbe:
httpGet:
path: /health
port: 8080
initialDelaySeconds: 5
periodSeconds: 10
Try increasing initialDelaySeconds
to give your app more time to start:
initialDelaySeconds: 30