Questions
Questions
1. In a cluster with two nodes, one with pods and the other without, which
node will a new pod be scheduled to?
4. Is a Pod stable once created, even if the user takes no further action?
5. Can a Service of type ClusterIP ensure load balancing for TCP traffic?
9. When you execute kubectl exec -it <pod> -- bash, are you logging into
the pod?
Do you have quick and accurate answers to these questions, while focusing
on the key points?
Answers
1. In a cluster with two nodes, one with pods and the other without,
which node will a new pod be scheduled to?
9. When you execute kubectl exec -it <pod> -- bash, are you logging
into the pod?
No, kubectl exec requires specifying a container (defaulting to the only
container in a single-container Pod). Pods are collections of isolated Linux
namespaces. Containers share Network, IPC, and UTS namespaces,
while PID and Mount namespaces remain separate. kubectl exec -it <pod> --
bash starts a new bash process in the target container's isolated
environment but doesn't "log in" to the Pod.