안녕하세요, 쯀리입니다.
오늘은 Service Networking에 대해 배워보겠습니다.
Quiz.
1. What network range are the nodes in the cluster part of?
controlplane ~ ➜ ip addr show eth0
147: eth0@if148: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc noqueue state UP group default
link/ether 02:42:c0:06:cb:08 brd ff:ff:ff:ff:ff:ff link-netnsid 0
inet 192.6.203.8/24 brd 192.6.203.255 scope global eth0
valid_lft forever preferred_lft forever
eth0 인터페이스는 노드가 클러스터 내부 또는 외부 네트워크와 통신할 때 사용하는 주요 네트워크 인터페이스입니다.
2. What is the range of IP addresses configured for PODs on this cluster?
controlplane ~ ➜ k logs weave-net-j2km7 -n kube-system | grep ipalloc-range
Defaulted container "weave" out of: weave, weave-npc, weave-init (init)
INFO: 2024/08/10 04:09:50.987185 Command line options: map[conn-limit:200 datapath:datapath db-prefix:/weavedb/weave-net docker-api: expect-npc:true http-addr:127.0.0.1:6784 ipalloc-init:consensus=0 ipalloc-range:10.244.0.0/16 metrics-addr:0.0.0.0:6782 name:46:86:a7:8c:a9:c5 nickname:controlplane no-dns:true no-masq-local:true port:6783]
## 또는
controlplane /etc/kubernetes/manifests ➜ cat kube-controller-manager.yaml | grep cidr
- --allocate-node-cidrs=true
- --cluster-cidr=10.244.0.0/16
10.244.0.0/16
kube-controller-manager.yaml 파일을 확인해야 하는 이유는 이 파일에 클러스터 네트워크 관련 설정이 포함되어 있을 수 있기 때문입니다. 특히, 클러스터 내 파드 네트워크 범위(CIDR)와 같은 중요한 네트워크 설정이 이 파일에 정의되어 있을 수 있습니다.
3. What is the IP Range configured for the services within the cluster?
controlplane /etc/kubernetes/manifests ➜ cat kube-controller-manager.yaml | grep ip-range
- --service-cluster-ip-range=10.96.0.0/12
10.96.0.0/12
4. How many kube-proxy pods are deployed in this cluster?
controlplane /etc/kubernetes/manifests ➜ k get po -A | grep proxy
kube-system kube-proxy-l6zg7 1/1 Running 0 95m
kube-system kube-proxy-xv6cn 1/1 Running 0 95m
5. What type of proxy is the kube-proxy configured to use?
controlplane ~ ➜ k logs kube-proxy-l6zg7 -n kube-system | grep proxy
I0810 04:09:47.668749 1 server_linux.go:69] "Using iptables proxy"
I0810 04:09:47.718994 1 server.go:659] "kube-proxy running in dual-stack mode" primary ipFamily="IPv4"
6. How does this Kubernetes cluster ensure that a kube-proxy pod runs on all nodes in the cluster?
Inspect the kube-proxy pods and try to identify how they are deployed.
controlplane ~ ➜ k describe po kube-proxy-l6zg7 -n kube-system
...
Controlled By: DaemonSet/kube-proxy
...
참조
※ Udemy Labs - Certified Kubernetes Administrator with Practice Tests
'IT 잡지식 > DevOps' 카테고리의 다른 글
[CKA] KodeKloud - Ingress Networking - 1 (0) | 2024.08.15 |
---|---|
[CKA] KodeKloud - CoreDNS in Kubernetes (0) | 2024.08.15 |
[CKA] KodeKloud - Networking Weave (0) | 2024.08.10 |
[CKA] KodeKloud - Deploy Network Solution (0) | 2024.08.08 |
[CKA] KodeKloud - CNI (0) | 2024.08.08 |