본문 바로가기

분류 전체보기133

[따배쿠CKA-3]Static-Pod 생성하기 1. kubectl 구동방식 * 전제조건: master Node 1개, node1, node2 1) "kubectl nginx pod" 라는 명령어를 사용자가 입력하면 2) master Node 의 API 로 전달, API 가 전달을 받으면, 3) master Node 의 ETCD 안에 있는 클러스터를 꺼내서 scheduler에게 보내서 요청을한다. 4) Scheduler 은 "kubectl nginx pod" 명령어에 Node1, Node2 중에 어디가 더 적합한지 확인을 함 5) Scheulder은 노드와 클러스터의 상태를 확인하고 가장 적합한 Node를 찾아 API 에게 알려준다. 예를들면 적합한 Node 가 1번 Node 이면 6) API가 1번 Node 의 kubelet 에게 요청을 한다. "k.. 2022. 8. 3.
[따배쿠CKA-2] Pod 생성하기 1. Pod 생성하기 Q. 클러스터: k8s Create a new namespace and create a pod in the namespace. - namespace name: ecommerce - pod Name: eshop-main - image: nginx:1.17 - env: DB=mysql 1) namespace 만들기 k create namespace ecommerce k get ns 2) pod 생성하기 생성하기 k run eshop-main --image=nginx:1.17 -n ecommerce --env=DB=mysql --dry-run=client -o yaml > eshop-main.yaml : 생성한 yaml 파일 다시 한번 더 확인하고 실행 vi eshop-main.yaml .. 2022. 8. 3.
[따배쿠CKA -1] cka - ETCD Backup Restore * 반드시 sudo -su // sudo 관리자로서 작업해야 함. 1. ETCD Backup & Restore (docs keyword: etcd ) Q. 작업 시스템: k8s – master First, create a snapshot of the existing etcd instance running at https://127.0.0.1:2379 , saving the snapshot to /data/etcd-snapshot.db. Next, restore an existing, previous snapshot located at /data/etcd-snapshot-previous.db. The following TLS certificates/key are supplied for connecting .. 2022. 8. 3.
[k8s] CoreDNS in kubeernetes 1. Identify the DNS solution implemented in this cluster. k get pods -A A) coreDNS 2. How many pods of the DNS server are deployed? k get pods -A A) 2 3. What is the name of the service created for accessing CoreDNS? kubectl get service -n kube-system A) kube-dns 4. What is the IP of the CoreDNS server that should be configured on PODs to resolve services? kubectl get service -n kube-system A) 1.. 2022. 8. 3.
[k8s] Service Networking 1. What network range are the nodes in the cluster part of? k get nodes -o wide A) 10.0.81.0/24 2. What is the range of IP addresses configured for PODs on this cluster? ip a A) 10.50.0.0/16 3. What is the IP Range configured for the services within the cluster? : 다시 확인 A) 10.96.0.0/12 4. How many kube-proxy pods are deployed in this cluster? k get pods -n kube-system A) 2 5. What type of proxy .. 2022. 8. 3.
[cka]Network- Networking weave 1.How many Nodes are part of this cluster? Including master and worker nodes k get nodes A) 2 2. What is the Networking Solution used by this cluster? cat cat /etc/cni/net.d/10-weave.conflist A) weave 3.How many weave agents/peers are deployed in this cluster? k get pods -A A) 2 4. On which nodes are the weave peers present? A) one on every noe=de 5. Identify the name of the bridge network/inter.. 2022. 8. 3.