exam questions

Exam CKA All Questions

View all questions & answers for the CKA exam

Exam CKA topic 1 question 23 discussion

Actual exam question from CNCF's CKA
Question #: 23
Topic #: 1
[All CKA Questions]

SIMULATION
-






Task
-

Create a persistent volume with name app-data, of capacity 2Gi and access mode ReadWriteOnce. The type of volume is hostPath and its location is /srv/app-data.

Show Suggested Answer Hide Answer
Suggested Answer: apiVersion: v1 kind: PersistentVolume metadata: name: app-data spec: capacity: storage: 2Gi accessModes: - ReadOnlyMany hostPath: path: "/srv/app-data"

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
Stargazer11
Highly Voted 11 months, 2 weeks ago
https://kubernetes.io/docs/tasks/configure-pod-container/configure-persistent-volume-storage/#create-a-persistentvolume Keep in mind that example yaml is in Pod configuration section not in storage section. apiVersion: v1 kind: PersistentVolume metadata: name: app-data spec: capacity: storage: 2Gi accessModes: - ReadWriteOnce hostPath: path: "/srv/app-data"
upvoted 6 times
...
ggrodskiy
Most Recent 4 months, 1 week ago
apiVersion: v1 kind: PersistentVolume metadata: name: app-data spec: capacity: storage: 2Gi volumeMode: Filesystem accessModes: - ReadWriteOnce hostPath: path: /srv/app-data
upvoted 1 times
...
abu7midan
1 year, 1 month ago
apiVersion: v1 kind: PersistentVolume metadata: name: app-data spec: capacity: storage: 2Gi accessModes: - ReadWriteOnce hostPath: path: "/srv/app-data"
upvoted 4 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago