How do I create a volume in kubernetes so that it doesn't get detroyed when pods die?

0 votes

I am having a docker image which when created should check if the volume is empty, in case it should be initialized with some data. This saved data must remain available for other pods with the same or different image.

enter image description here

Can anyone resolve this query?

Thanks.

Aug 16, 2018 in Kubernetes by shubham
• 6,890 points
163 views

1 answer to this question.

0 votes

Here is a solution to your problem:

You can mount the pod into the node and hence save the data in the node so when new pod will create in the same node it will have an access to the same volume.

Pods on the same node can create deadlock for the same resource. So what can we do is share storage meaning and create one storage and every pod will claim storage in the same storage.

Just watch this webinar to clear your doubts :https://www.youtube.com/watch?v=n06kKYS6LZE

I hope it would help you resolve your query.

answered Aug 20, 2018 by anonymous

Related Questions In Kubernetes

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

How do I create a service account for my dashboard and get all the credentails

Run the following commands: This command will create ...READ MORE

answered Oct 8, 2018 in Kubernetes by Kalgi
• 42,540 points
308 views
0 votes
1 answer
+5 votes
7 answers

Docker swarm vs kubernetes

Swarm is easy handling while kn8 is ...READ MORE

answered Aug 27, 2018 in Docker by Mahesh Ajmeria
1,058 views
0 votes
2 answers