ㅁ A pod definition file nginx.yaml is given. Create pod using the file.
kubectl apply -f nginx.yaml
ㅁ What is the status of the created POD?
kubectl get pods
ㅁ Why is the POD in a pending state?
kubectl -n kube-system get pods
kubectl describe pod nginx
ㅁ Manually schedule the pod on node01
apiVersion: v1
kind: Pod
metadata:
name: nginx
spec:
nodeName: node01
containers:
- image: nginx
name: nginx
kubectl apply -f nginx.yaml
ㅁ Now schedule the same pod on the master node
apiVersion: v1
kind: Pod
metadata:
name: nginx
spec:
nodeName: master
containers:
- image: nginx
name: nginx
kubectl apply -f nginx.yaml
'CKA &. CKAD > Scheduling' 카테고리의 다른 글
Resource Limits (0) | 2021.03.26 |
---|---|
Practice Test - Node Selectors/Affinity (0) | 2021.03.26 |
Practice Test - Taints and Tolerations (0) | 2021.03.26 |
Practice Test - Labels and Selectors (0) | 2021.03.25 |
Labels and Selectors (0) | 2021.03.25 |