To add EventRateLimit
admission controller you need to modify the api server static pod yaml from /etc/kubernetes/manifests
.
...
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
...
Find the Kubernetes API server pod name
kubectl get pods -n kube-system
You can get logs of a static pod as you typically get logs of a regular pod
kubectl logs apiserverpodname -n kube-system
Alternatively directly check logs of the kubernetes API Server container by ssh into master node.
Find the docker container id for Kubernetes API Server
docker ps
Check logs of the docker container
docker logs container