debug-cluster
Skill0 starsChanged 10 days agoApache-2.0View on GitHub
This skill should be used when the user mentions "debug", "troubleshoot", "why is", "what's wrong", or describes CFKE cluster issues like node failures, pod crashes, or networking problems.
In this repository9 other files it gives its agents.
- best-practicesSkill
- cfcr-overviewSkill
- cfke-overviewSkill
- cluster-infoSkill
- cluster-setupSkill
- contactSkill
- query-clusterSkill
- setupSkill
- terraformSkill
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 4 are distinctive, and 5 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 12
Check for kubectl with command -v kubectl.
- Very specific: line 17
If the user specifies a --profile, pass it to all cloudfleet CLI commands.
- Very specific: line 30
If the user named a cluster (by name or ID), use it.
- Very specific: line 45
Use kubectl --kubeconfig $KUBECONFIG for ALL subsequent kubectl commands.
- Very specific: line 100
Pod failures: Check logs with kubectl logs (requires kubectl), describe pod for events
- Distinctive: line 101
Node issues: Check node conditions, Cilium status
- Distinctive: line 102
Networking: Check Cilium pods, CoreDNS, Services/Endpoints
- Distinctive: line 103
Scheduling: Check resource requests vs available capacity, taints/tolerations
- Distinctive: line 123
If a fetch returns 404 the page was renamed.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Debug CFKE Cluster
Guided debugging workflow for Cloudfleet Kubernetes Engine clusters.
Check for kubectl with command -v kubectl. Use kubectl when it is installed, and the read-only Cloudfleet MCP server when it is not.
Important Notes
kubectlis a separate tool from the Cloudfleet CLI — there is nocloudfleet kubectlcommand.- If the user specifies a
--profile, pass it to allcloudfleetCLI commands. - Pass
-o jsontocloudfleetcommands. The defaultautoalready emits JSON when piped, but a per-profile default orCLOUDFLEET_OUTPUT_FORMATcan override it totable. - Narrow large results with
-q(JMESPath), e.g.cloudfleet clusters list -q "[].{id:id,name:name,status:status}". - The kubeconfig context name format is
{cluster-id}/{profile-name}. Do NOT guess — runkubectl config get-contextsif unsure.
Prerequisites
- Cloudfleet CLI installed and authenticated
Execution Steps
1. Identify the cluster
If the user named a cluster (by name or ID), use it. Otherwise, run cloudfleet clusters list (with --profile if specified) to show available clusters and ask the user which one to debug. Save the cluster ID as CLUSTER_ID.
2. Configure kubectl access (if kubectl is installed)
Get an isolated kubeconfig:
KUBECONFIG="${TMPDIR:-/tmp}"; KUBECONFIG="${KUBECONFIG%/}/cloudfleet-$(id -u)/$CLUSTER_ID.kubeconfig"
mkdir -p "${KUBECONFIG%/*}" && chmod 700 "${KUBECONFIG%/*}"
[ -f "$KUBECONFIG" ] || (umask 077 && cloudfleet clusters kubeconfig "$CLUSTER_ID" --kubeconfig "$KUBECONFIG" >&2)
echo "$KUBECONFIG"The directory is per-user and private, so other local users cannot read or replace the file. Add --profile to the cloudfleet command if the user named one. Shell variables do not survive between commands, so pass the printed path to later commands.
Use kubectl --kubeconfig $KUBECONFIG for ALL subsequent kubectl commands. Never use bare kubectl — the user's active context may point to a different cluster.
3. Gather cluster info
If kubectl is installed:
kubectl --kubeconfig $KUBECONFIG get nodes -o wide
kubectl --kubeconfig $KUBECONFIG get pods --all-namespaces --field-selector=status.phase!=Running
kubectl --kubeconfig $KUBECONFIG get events --all-namespaces --sort-by='.lastTimestamp' | tail -30If kubectl is not installed, use the Cloudfleet MCP clusters_query tool (read-only) to check:
/api/v1/nodes— node status/api/v1/pods?fieldSelector=status.phase!=Running— failing pods/api/v1/events?limit=30— recent events
4. Systematic diagnosis
The checks below are independent. If you can run subagents, run them in parallel and have each report facts only (resource states, error messages, event timestamps), not fixes.
With kubectl:
Nodes: Ready/NotReady, conditions (MemoryPressure, DiskPressure, PIDPressure), taints, capacity.
kubectl --kubeconfig $KUBECONFIG describe nodes | grep -A5 "Conditions:"
kubectl --kubeconfig $KUBECONFIG top nodesPods: not Running or Succeeded, more than 5 restarts, stuck in Pending (check events for scheduling failures), in CrashLoopBackOff (read the logs of the last crash with --previous).
System pods: CoreDNS, Cilium and Konnectivity in kube-system, any not running or restarting.
kubectl --kubeconfig $KUBECONFIG get pods -n kube-system -o wideResource pressure: nodes above 85% CPU or memory, and the top consumers.
kubectl --kubeconfig $KUBECONFIG top pods --all-namespaces --sort-by=memory | head -20Events: warnings in the last 30 minutes, failed scheduling, evictions.
With MCP only: Query /api/v1/namespaces/kube-system/pods and /api/v1/nodes for status details. Note that kubectl top equivalents are not available via MCP.
Group the findings as CRITICAL, WARNING and INFO before moving on.
5. Targeted investigation
Based on findings, drill into specific areas:
- Pod failures: Check logs with
kubectl logs(requires kubectl), describe pod for events - Node issues: Check node conditions, Cilium status
- Networking: Check Cilium pods, CoreDNS, Services/Endpoints
- Scheduling: Check resource requests vs available capacity, taints/tolerations
No agent available: this error means two different things. If the node isNotReadyand unreachable, it is down (seeself-managed-node-issues). If nodes are healthy, it is a transient blip in the control plane tunnel, common right after an operator pod restarts. Retry once before investigating.- Storage: A PVC stuck
Pendingusually means no CSI driver. CFKE installs none for any provider, on purpose: the driver for whichever cloud the nodes run on is yours to install and own. Check for a StorageClass and a running CSI controller before looking further.
6. Consult the troubleshooting docs
Once the symptom is identified, open the matching page under https://cloudfleet.ai/docs/troubleshooting/<slug>/ and follow it. Fetch the page and read it. Never answer from the slug alone — these pages change often, and a plausible-sounding answer reconstructed from the URL will be wrong.
| Symptom | Slug |
Pods stay Pending, no nodes appear | pods-stuck-in-pending |
kubectl cannot connect, cluster reported unavailable | cannot-reach-cluster |
| API throttling, leader election flapping, GitOps reconcile storms | control-plane-pressure |
exec format error, arm64/amd64 image mismatch | handle-single-platform-images |
| Request too large, data store size limits | kubernetes-api-server-quotas |
| LB IP changed, PROXY protocol errors, in-cluster LB access | load-balancer-issues |
| Pod-to-pod failures, NetworkPolicy blocking the API server, Tailscale | network-connectivity-issues |
PVC stuck Pending, PVs stuck attaching or mounting, disk pressure evictions | persistent-volume-issues |
| Self-managed node will not join, frozen, or has host DNS problems | self-managed-node-issues |
If a fetch returns 404 the page was renamed. Fetch the index at https://cloudfleet.ai/docs/troubleshooting/ and pick from there rather than guessing a new slug.
7. Summary
Present findings with:
- Root cause (or most likely candidates)
- Recommended remediation steps
- Any Cloudfleet-specific guidance (e.g., fleet adjustments, version upgrades)
If the issue appears to be on the platform side (e.g., control plane unreachable, API errors), remind the user to check https://status.cloudfleet.ai/ for ongoing incidents and, if needed, offer to open a support ticket with the findings above (technical category). If the investigation was slowed by a misleading error, missing docs, or undocumented behavior, offer to send that as feedback as well. The contact skill covers both.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

