Severity: P1 | Team: Infrastructure + Backend
gistpin_db_upPrometheus metric = 0- Backend returning 500 errors on all write endpoints
- Alert:
DatabaseDown
# Check pod status
kubectl get pods -n gistpin -l app=postgres
# Check logs
kubectl logs -n gistpin -l app=postgres --tail=50
# Test connectivity from backend pod
kubectl exec -n gistpin deploy/gistpin-backend -- \
pg_isready -h postgres-service -p 5432- Restart StatefulSet (if pod is crashlooping):
kubectl rollout restart statefulset/postgres -n gistpin kubectl rollout status statefulset/postgres --timeout=120s
- Check PVC (if storage issue):
kubectl get pvc -n gistpin kubectl describe pvc postgres-data -n gistpin
- Restore from backup (last resort):
./infrastructure/scripts/restore-backup.sh latest gistpin_prod
Immediate page to on-call DBA if not resolved within 5 minutes.
Required for all P1 incidents. Use template in incident-response.md.