<p>I can't create new pods in my default namespace in GKE. I checked the error on deployments and replicasets using <code>kubectl -n default get replicaset xxxx</code> --&gt; The error is:</p>
<pre class="lang-sh prettyprint-override"><code>  Warning  FailedCreate  6m54s replicaset-controller  Error creating: pods &quot;dummy-deployment-54b6f555b7-ms5sb&quot; is forbidden: exceeded quota: gke-resource-quotas, requested: pods=1, used: pods=5k, limited: pods=5k
</code></pre>
<p>So I ran this command <em><code>kubectl get resourcequota gke-resource-quotas -o yaml -n default</code></em> to look at what's going on with <em>gke-resource-quotas</em></p>
<p>I get this result:</p>
<pre class="lang-yaml prettyprint-override"><code>apiVersion: v1
kind: ResourceQuota
metadata:
  creationTimestamp: &quot;2020-02-04T13:06:27Z&quot;
  name: gke-resource-quotas
  namespace: default
  resourceVersion: &quot;109072XXXX&quot;
  selfLink: /api/v1/namespaces/default/resourcequotas/gke-resource-quotas
  uid: 2727d85b-474f-11ea-a2f2-XXXXXXXXXX
spec:
  hard:
    count/ingresses.extensions: 5k
    count/jobs.batch: 10k
    pods: 5k
    services: &quot;1500&quot;
status:
  hard:
    count/ingresses.extensions: 5k
    count/jobs.batch: 10k
    pods: 5k
    services: &quot;1500&quot;
  used:
    count/ingresses.extensions: &quot;7&quot;
    count/jobs.batch: &quot;4540&quot;
    pods: 5k
    services: &quot;20&quot;
</code></pre>
<p>But I checked using <em><code>kubectl -n default get pods | wc -l</code></em> I do not have 5k pods running.</p>
<p>This is preventing me from creating new pods in my <em>default</em> namespace in GKE.</p>
<p>This seems like an error on part of GKE/K8s. Does anyone know how I can resolve this? Thanks!</p>

<p>It totally looks like a GKE issue with their pre-built quotas. You might have at one point hit the <em>5k</em> limit perhaps not being updated for terminated pods and it thinks it has reached the limit.</p>
<p><a href="https://stackoverflow.com/a/61656760/2989261">Someone else found a workaround</a> so I would just try that for now:</p>
<pre class="lang-sh prettyprint-override"><code>kubectl delete resourcequota gke-resource-quotas -n default
</code></pre>
<p>If you are running at that scale and this is an important recurring issue I would strongly recommend hitting <a href="https://cloud.google.com/support" rel="nofollow noreferrer">GKE/GCP support</a>. Or seek alternatives like running outside of GKE.</p>
<p>✌️</p>
