Error from server (NotFound): ... not found
The “Error from server (NotFound): not found” error means the API server cannot find your resource. The cluster is reachable but the resource is absent.
What It Means
The request reached the API server and was authenticated, but the server returned a 404 HTTP status. The resource you tried to get, describe, edit, or delete does not exist in the specified namespace or cluster.
Why It Happens
- The resource name is misspelled in the kubectl command.
- You’re querying the wrong namespace.
- The resource hasn’t been created yet (deployment not applied).
- The resource was deleted by another process or person.
- The resource exists but in a different namespace or cluster.
- A typo in the resource type (e.g.
deploymentsvsdeployment). - The resource type is case-sensitive.
How to Fix It
Step 1: Verify the resource exists
List all resources of that type:
kubectl get pods
kubectl get deployments
kubectl get servicesIf the list is empty or doesn’t include your resource, it doesn’t exist.
Step 2: Check the namespace
Resources exist in namespaces. If no namespace is specified, kubectl uses the current context’s default namespace (usually default):
kubectl get pods --all-namespaces
kubectl get pods -n <namespace>
kubectl config view --minify | grep namespaceStep 3: Check the exact spelling
Resource names are case-sensitive and must match exactly:
# ❌ Wrong case
kubectl get pod my-app
# ✅ Correct case
kubectl get pod my-appUse tab completion to avoid typos:
source <(kubectl completion bash)Step 4: Check if the resource was created
If you applied a manifest but the resource doesn’t appear:
kubectl apply -f deployment.yaml
kubectl get deployments
kubectl describe deployment <name>Check for errors in the apply output — the resource may have failed to create.
Step 5: Search across all namespaces
If you’re unsure where the resource lives:
kubectl get <resource> --all-namespaces | grep <partial-name>Built by the developers of DodaTech
Doda Browser, DodaZIP & Durga Antivirus Pro