• 카테고리

    질문 & 답변
  • 세부 분야

    데브옵스 · 인프라

  • 해결 여부

    미해결

kubeadm init 에러 두번째

21.08.21 01:10 작성 조회수 4.41k

0

kubeadm ini 했을때 에러가 첫번째는
/etc/kubernetes/manifests/ 아래에 있는 yaml 파일을 삭제하니 아래 에러는 처리됬습니다.
--------------------
[ERROR FileAvailable--etc-kubernetes-manifests-kube-apiserver.yaml]: /etc/kubernetes/manifests/kube-apiserver.yaml already exists [ERROR FileAvailable--etc-kubernetes-manifests-kube-controller-manager.yaml]: /etc/kubernetes/manifests/kube-controller-manager.yaml already exists [ERROR FileAvailable--etc-kubernetes-manifests-kube-scheduler.yaml]: /etc/kubernetes/manifests/kube-scheduler.yaml already exists [ERROR FileAvailable--etc-kubernetes-manifests-etcd.yaml]: /etc/kubernetes/manifests/etcd.yaml already exists

=====================================

그러고 나니 아래 에러가 발생하네요.

[wait-control-plane] Waiting for the kubelet to boot up the control plane as static Pods from directory "/etc/kubernetes/manifests". This can take up to 4m0s

[kubelet-check] Initial timeout of 40s passed.

[kubelet-check] It seems like the kubelet isn't running or healthy.

[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect: connection refused.

[kubelet-check] It seems like the kubelet isn't running or healthy.

[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect: connection refused.

[kubelet-check] It seems like the kubelet isn't running or healthy.

[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect: connection refused.

[kubelet-check] It seems like the kubelet isn't running or healthy.

[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect: connection refused.

[kubelet-check] It seems like the kubelet isn't running or healthy.

[kubelet-check] The HTTP call equal to 'curl -sSL http://localhost:10248/healthz' failed with error: Get "http://localhost:10248/healthz": dial tcp 127.0.0.1:10248: connect: connection refused.

답변 2

·

답변을 작성해보세요.

1

쌍큼래쑹님의 프로필

쌍큼래쑹

2021.08.27

mkdir /etc/docker

cat <<EOF | sudo tee /etc/docker/daemon.json

{

  "exec-opts": ["native.cgroupdriver=systemd"],

  "log-driver": "json-file",

  "log-opts": {

    "max-size": "100m"

  },

  "storage-driver": "overlay2"

}

EOF

위에 적용해보시고

kubeadm reset  후 kubeadm init

그래도 안된다면 kubeadm reset 후 리부팅

kubeadm init  하면 정상동작합니다.

안되면 리부팅한 후 다시하면 거의 되는거 같습니다.

0

gasbugs님의 프로필

gasbugs

2021.08.24

안녕하세요 강사 최일선입니다.

답변이 늦어죄송합니다. 다음 문의는 빠르게 답변 드리도록 하곘습니다. ㅠ

일단 주신 내용으로 정보를 확인하기 어렵습니다. 데몬인 kubelet이 정상 구동되지 않은 것으로 보이는데

다음 명령어를 사용해 서비스의 로그를 확인해서 내용을 첨부해주시면 감사하겠습니다!

journalctl -xeu kubelet

감사합니다.