Here i am putting 3 questions with answers (with snaps) I attempted as expected, but still evaluated as wrong ones. Could someone please take a look here, if im missing anything please feel free to correct.
For this question, please set the context to cluster1
by running:
kubectl config use-context cluster1
Q. 1 There is an existing persistent volume called orange-pv-cka13-trb
. A persistent volume claim called orange-pvc-cka13-trb
is created to claim storage from orange-pv-cka13-trb
.
However, this PVC is stuck in a Pending
state. As of now, there is no data in the volume.
Troubleshoot and fix this issue, making sure that orange-pvc-cka13-trb
PVC is in Bound
state.
Answer: My pvc was bound which was expected.
Q. 2. For this question, please set the context to cluster1
by running:
kubectl config use-context cluster1
There is a sample script located at /root/service-cka25-arch.sh
on the student-node
.
Update this script to add a command to filter/display the targetPort
only for service service-cka25-arch
using jsonpath
. The service has been created under the default
namespace on cluster1
.
answer:
Q.3. For this question, please set the context to cluster3
by running:
kubectl config use-context cluster3
Run a pod called looper-cka16-arch
using the busybox
image that runs the while loop while true; do echo hello; sleep 10;done
. This pod should be created in the default
namespace.
Answer: For this question, I verified my pod got started and was running fine.
But during submission, i see my pod is gone.
can someone take a look here please?
In general: the exams do give you a solution on the “Exit Exam” page. I’m assuming you’ve already looked at this. If not: worth doing.
- I’m assuming that you changed the PVC and the PV. If so, it is indeed possibly a grader glitch. From the information you’ve supplied, I’m not sure why the grader did not allow your answer.
- Not sure why your answer was not allowed; the solutions tab indicates the same solution as yours.
- Here the simplest solution may be correct: I don’t think your pod disappeared. I think it’s likely in a different context, and the grader can’t find it.
thank you Rob for your response.
Yes, I saw the solutions as well. Solutions commands were providing the --context option while running kubectl. This was it, this is the only difference i could see in my commands, i was setting the context earlier itself using command mentioned as below, thats why i was not running it with every command while solving one question. Because context is same for one single question.
kubectl config use-context cluster_name
I am not sure if resources are being verified or test cases are run on each command by KK grader.
If the question has asked you to make a script to output some jsonpath on a specific cluster, then you must use --context
The grader will not run until you press end exam
and if you haven’t used --context
and you have since doing that question used a different context, then the context will be wrong and your script will not produce the expected result.
Understood. But that happens when an output has to be stored in a script. But what about others questions.
Where the output is stored in a file rather than the command itself - I think we covered that in the other thread.