Which of the following commands would get the logs for that container?

Have a pod ‘hello’ and a container in that pod ‘green’.

Which of the following commands would get the logs for that container?
A . alias k=’kubectl’
k logs -p hello -c green
B. alias k=’kubectl’
k logs hello -c green
C. alias k=’kubectl’
k get logs -p hello -c green
D. alias k=’kubectl’
k logs -p hello green

Answer: B

Explanation:

https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#logs

Graphical user interface, text, application, email

Description automatically generated

Latest KCNA Dumps Valid Version with 126 Q&As

Latest And Valid Q&A | Instant Download | Once Fail, Full Refund

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments