github.com/jlmeeker/kismatic@v1.10.1-0.20180612190640-57f9005a1f1a/docs/upgrade/v1.3.0/static-pods.md (about)

     1  # Kubernetes Components as Static Pods
     2  
     3  Starting with Kismatic `v1.3.0`, the Kubernetes control plane components are deployed
     4  as static pods instead of systemd services. These include the API server, the controller manager
     5  and the scheduler. The kube-proxy and calico-node components also run as a pod on each node. 
     6  These static pods are deployed into the `kube-system` namespace.
     7  
     8  The Kubelet is the only Kubernetes component that continues to be deployed as a systemd service, along with docker and etcd.
     9  
    10  The following is a listing of pods that are running in the `kube-system` namespace. As you can see,
    11  the API server, controller manager, scheduler and kube-proxy are all running as pods on the cluster.
    12  Each static pod has the node's hostname appended to it's name (e.g. `kube-proxy-node001` is 
    13  running on `node001`).
    14  
    15  ```
    16  # kubectl get pods -n kube-system
    17  NAME                                    READY     STATUS    RESTARTS   AGE
    18  calico-node-rxp2b                       2/2       Running   0          2m
    19  default-http-backend-4kpt3              1/1       Running   0          1m
    20  ingress-q65t5                           1/1       Running   0          1m
    21  kube-apiserver-node001                  1/1       Running   0          3m
    22  kube-controller-manager-node001         1/1       Running   0          3m
    23  kube-dns-b0d29                          3/3       Running   0          2m
    24  kube-proxy-node001                      1/1       Running   0          2m
    25  kube-scheduler-node001                  1/1       Running   0          3m
    26  kubernetes-dashboard-1389325151-90dzp   1/1       Running   0          1m
    27  ```
    28  
    29  The fact that most of the Kubernetes components are now being hosted by Kubernetes itself has
    30  implications when it comes to troubleshooting and getting logs. If the API Server is running,
    31  you may use `kubectl logs` to get logs for a component. 
    32  
    33  For example, if you are interested in the controller manager's logs, 
    34  you may use the following command (Replace `node001` with the node's hostname):
    35  
    36  ```
    37  kubectl logs -n kube-system kube-controller-manager-node001
    38  ```
    39  
    40  In the case that the API Server is down or unavailable, you must use `docker logs` to get logs from the
    41  components.
    42  
    43  For example, if you are interested in diagnosing why the API server is down, you may use the following command:
    44  
    45  ```
    46  # This gets the container ID of the API server container.
    47  CONTAINER_ID=$(docker ps -a | grep kube-apiserver-amd64 | cut -f 1 -d " ")
    48  docker logs $CONTAINER_ID
    49  ```
    50  ## Upgrading to Static Pods
    51  When upgrading to `v.1.3.0`, the systemd services that will be replaced by static pods 
    52  are stopped, and the packages removed. Once done, the necessary container images 
    53  are downloaded and static pod manifests are created in `/etc/kubernetes/manifests`.
    54  The kubelet is configured to watch this directory for static pod manifests.