# error: the server doesn't have a resource type "x"

**Code:** `doesn't have a resource type` · **Category:** Kubernetes · **Seen on:** Kubernetes

kubectl doesn’t know the resource name you typed — a typo, a CRD that isn’t installed, or a stale discovery cache.

## Meaning

Resource names come from API discovery. Custom resources appear only after their CRD is installed, and kubectl caches discovery in ~/.kube/cache, so freshly installed CRDs may need a cache refresh.

## Common causes

- Typo or wrong short name
- CRD/operator not installed on this cluster
- Stale discovery cache
- Wrong cluster context

## Quick fix

1. List types: kubectl api-resources | grep -i name
2. Install the CRD/operator
3. Clear the cache: rm -rf ~/.kube/cache

## Detailed fix by platform

### Kubernetes

1. 

```bash
kubectl api-resources | grep -i cert
rm -rf ~/.kube/cache/discovery
```


## How to diagnose

1. **Types** — kubectl api-resources
2. **Context** — Right cluster?

---
Source: [WhatIsMyError](https://whatismyerror.com/errors/kubernetes/server-doesnt-have-resource-type)
