반응형

설치 / 초기화 / flannel 까지 세팅을 했는데, kubectl get nodes에서 계속해서 NotReady라고 나온다.

$ kubectl get nodes
NAME     STATUS     ROLES    AGE   VERSION
u16-01   NotReady   master   62m   v1.13.3


시간이 지났는데도 Ready로 바뀌지 않는 경우, 뭐 때문에 NotReady라고 나오는 지 알고 싶다면, 아래와 같은 키워드를 이용하여, Condition 부분을 살펴보면 됨.

$ kubectl describe node 노드이름


(예시)

...
Conditions:
  Type             Status  LastHeartbeatTime                 LastTransitionTime                Reason                       Message
  ----             ------  -----------------                 ------------------                ------                       -------
  MemoryPressure   False   Wed, 20 Feb 2019 07:50:16 +0000   Wed, 20 Feb 2019 06:47:37 +0000   KubeletHasSufficientMemory   kubelet has sufficient memory available
  DiskPressure     False   Wed, 20 Feb 2019 07:50:16 +0000   Wed, 20 Feb 2019 06:47:37 +0000   KubeletHasNoDiskPressure     kubelet has no disk pressure
  PIDPressure      False   Wed, 20 Feb 2019 07:50:16 +0000   Wed, 20 Feb 2019 06:47:37 +0000   KubeletHasSufficientPID      kubelet has sufficient PID available
  Ready            False   Wed, 20 Feb 2019 07:50:16 +0000   Wed, 20 Feb 2019 06:47:37 +0000   KubeletNotReady              runtime network not ready: NetworkReady=false reason:NetworkPluginNotReady message:docker: network plugin is not ready: cni config uninitialized
...


network plugin이 없다는 에러인데, 이런 경우 /etc/cni/net.d/10-flannel.conflist 파일을 찾아서, 복사 후 /etc/cni/net.d/10-flannel.conf로 만들어주면, 재시작 등 별도의 작업 없이 바로 해결 가능.



반응형
,