Hello, I have past few started to learned and test Kubernetes and more specifically AKS and have few questions related to Kubernetes which I have not fully understood. I try to describe questions as good as possible but noticed it is pretty difficult
-
If I use Persisten volume in Kubernetes and attach it to cluster can every pod/node use it easily to share, save and send data or do I need to configure deployment somehow? eg if I would have like 250GB volume, can it be shared cross all pods/nodes or are it then called PVC?
-
related to 1st question. If I attach volume to my cluster and then eg. 10 pod use it and 5 doesn’t, are those 10 pods using “Persisten volume claim”? So can some pods use persisten volume and some persisten volume claim? I’m a bit confused about persisten volume and persisten volume claim.
-
If I want to scale my application from 1 node to 2 do i need (if answer is yes, where can it be done?) configure my deployment or what so both nodes would automatically have same pods/application inside nodes so it would be replicated 1:1. I’m asking this because I tired to scale node, but my scaled node was empty when 1st node had application and pods inside it running fine. LoadBalancer still took 2nd node to it’s backend pool so traffic would been loaded right.
I appreciate all answers
killerm
August 21
Hello, I have past few started to learned and test Kubernetes and more specifically AKS and have few questions related to Kubernetes which I have not fully understood. I try to describe questions as good as possible but noticed it is pretty difficult
If I use Persisten volume in Kubernetes and attach it to cluster can every pod/node use it easily to share, save and send data or do I need to configure deployment somehow? eg if I would have like 250GB volume, can it be shared cross all pods/nodes or are it then called PVC?
Persistent Volumes come in 2 basic flavors - read/write once and
read/write many. These roughly map to “block devices” and “file
servers” (e.g. NFS). Read/write once can only be used by a single
pod. Read/write many can be used by many pods.
A PV is a cluster-resource. A PVC is a request to use that cluster
resource. In general, users interact with PVCs.
related to 1st question. If I attach volume to my cluster and then eg. 10 pod use it and 5 doesn’t, are those 10 pods using “Persisten volume claim”? So can some pods use persisten volume and some persisten volume claim? I’m a bit confused about persisten volume and persisten volume claim.
A PV-claim gives you the right and ability to use a PV. The cluster
is “loaning” you the PV as long as you hold a valid claim to it.
If I want to scale my application from 1 node to 2 do i need (if answer is yes, where can it be done?) configure my deployment or what so both nodes would automatically have same pods/application inside nodes so it would be replicated 1:1. I’m asking this because I tired to scale node, but my scaled node was empty when 1st node had application and pods inside it running fine. LoadBalancer still took 2nd node to it’s backend pool so traffic would been loaded right.
You scale deployments or other workloads, not nodes. If you have 1
pod and 2 nodes, your second node will be empty (mostly). If you want
to replicate, you need to increase the replica count of a Deployment
or similar workload resource.
1 Like
Thank you for the answer, that cleared a lot!