티스토리 뷰

Prequisite

  • OS (+ network)
  • Docker
  • 스왑 오프 
swapoff -a

 

Kubernetes 레포지토리 구성

$ sudo apt-get update
$ sudo apt-get install -y apt-transport-https ca-certificates curl
$ sudo curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -

$ cat <<EOF | sudo tee /etc/apt/sources.list.d/kubernetes.list
deb https://apt.kubernetes.io/ kubernetes-xenial main
EOF

$ sudo apt-get update

 

Kubelet, Kubeadm, Kubectl 설치

sudo apt-get update
sudo apt-get install -y kubelet kubeadm kubectl
sudo apt-mark hold kubelet kubeadm kubectl

systemctl daemon-reload
systemctl enable kubelet
systemctl start kubelet
systemctl status kubelet

 

 

Kubeadm join

kubeadm join <master-ip>:<master-port> --token <token> --discovery-token-ca-cert-hash sha256:<hash>

 

Get http://localhost:10248/healthz: dial tcp 127.0.0.1:10248: connect: connection refused 에러해결

https://jmholly.tistory.com/entry/Get-httplocalhost10248healthz-dial-tcp-12700110248-connect-connection-refused-%EC%97%90%EB%9F%AC%ED%95%B4%EA%B2%B0

 

Get http://localhost:10248/healthz: dial tcp 127.0.0.1:10248: connect: connection refused 에러해결

sudo mkdir /etc/docker cat < 을 하고 sudo systemctl enable docker sudo systemctl daemon-reload sudo systemctl restart docker sudo systemctl status kubelet 마지막으로 kubeadm init 다시 kubeadm reset..

jmholly.tistory.com

 

 

The connection to the server localhost:8080 was refused 오류 발생시

master node 가 있는 서버의 admin.conf 을 $HOME/.kube/config 로 가져온다

mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config

다음 명령어 실행

공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2025/01   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
글 보관함