<p>I have created a cluster using KubeSpray. When I SSH to the master node to add EventRateLimit to the admission controller list in the static pod manifest yaml of Kubernetes API Server, the API Server pod does not properly restart.</p>
<p>I don't know where to find error logs for a static pod. How can I debug the issue?</p>

David Medinets
<p>To add <code>EventRateLimit</code> admission controller you need to modify the api server static pod yaml from <code>/etc/kubernetes/manifests</code>.</p>
<pre><code>...
spec:
  containers:
  - command:
    - kube-apiserver
    - --advertise-address=10.0.0.115
    - --allow-privileged=true
    - --authorization-mode=Node,RBAC
    - --client-ca-file=/etc/kubernetes/pki/ca.crt
    - --enable-admission-plugins=NodeRestriction,EventRateLimit
...
</code></pre>
<p>Find the Kubernetes API server pod name</p>
<pre><code>kubectl get pods -n kube-system
</code></pre>
<p>You can get logs of a static pod as you typically get logs of a regular pod</p>
<pre><code>kubectl logs apiserverpodname -n kube-system
</code></pre>
<p>Alternatively directly check logs of the kubernetes API Server container by ssh into master node.</p>
<p>Find the docker container id for Kubernetes API Server</p>
<pre><code>docker ps
</code></pre>
<p>Check logs of the docker container</p>
<pre><code>docker logs container
</code></pre>
