Sandeep, I believe having development and production seperated by namespaces is not a good practice. The development load will affect production load. What do you think about it?
Is there any way to restrict some core shall not be used by Kubernetes on host machines. For example Server-1 having core 0-31 where I wanted to keep 1,2,3,4 CPU as isolated and core 1,2,3,4 shall not be used by K8s. any configuration for this goal ?
Nice video but one thing is not so clear: How to check the resources the pods are actually using? Lets say I have a cluster running and have assigned some resources and limits. How can I check if those values are good for my application? kubectl top and describe give very little information that is hard to relate. Is there a good resource about this?
is request and limit confined to containers or pods? because if i specify request and limit values to pod where pod have multiple containers then in that case will all the containers get adequate amount of resource?
As you can see in docs kubernetes.io/docs/reference/generated/kubernetes-api/v1.14/#container-v1-core resources are specified for containers. Pod Resources consists of resources of all pod's containers
You say the values for each container are additive. Does this mean that if I have three pods, best practice should mean that the limt of 1 needs to be split between the three pods. i.e. I currently have limit 0.5 for main pod and 0.25 for the other two. Then the same for the requests. I have 0.6 for the the main pod and 0.2 for the other two.
I still can't understand what is defaultRequest. About what kind of request are we talking about? We can limit resources per let's say http request for container? And that's the default value specified, if I don't specify for a container? (Sorry this is first video I see from this channel)
The "default" are default limits of CPU and memory, while "defaultRequest" are default requests for the CPU and memory. You can think of "requests" as: Assign this much CPU and memory to the given container. So if you set CPU requests to e.g. 500m, there will always be half of the core reserved for you container on the node where it runs
- There are only two kinds of Resources that can be Requested/Limited in K8s (as per the video atleast): Memory & CPU - 'defaultRequest' is specified with the 'limits' of K8s. When you are specifying limits, using 'defaultRequest' you can specify what is the default CPU and Memory 'request' by each Container, IF the container does not define one explicitly. - Let's say you generate a YAML file for a container and don't mention the CPU and Memory request explicitly, and schedule it on a node which has the 'defaultRequest' set; then the container gets resources described by the 'defaultRequest'. Hope this makes sense :)
Well presented, and exactly what I was looking for Thank you!
3:07 almost spilled coffee on myself (with headphones on)
:D :D
hahaha...correct
Well, as least he got our attention 😅
so did I
Me also - then I read this comment and almost spilled my coffee from laughter!!!
Here, is memory component similar to RAM only right?
if I'm using GKE, where do I go to evaluate how much a resource should request or be limited by?
simple and to the point :)
Sandeep, I believe having development and production seperated by namespaces is not a good practice. The development load will affect production load. What do you think about it?
This is just what I was studying last night! Awesome!
Thanks Sandeep, perfect presentation!
Great presentation!
Glad you liked it!
Is there any way to restrict some core shall not be used by Kubernetes on host machines. For example Server-1 having core 0-31 where I wanted to keep 1,2,3,4 CPU as isolated and core 1,2,3,4 shall not be used by K8s. any configuration for this goal ?
so touching for an excellent video
Glad you enjoyed it
Nice video but one thing is not so clear: How to check the resources the pods are actually using?
Lets say I have a cluster running and have assigned some resources and limits. How can I check if those values are good for my application?
kubectl top and describe give very little information that is hard to relate. Is there a good resource about this?
use prometheus with service mesh like linkerd/istio
thanks, short and clear
You're welcome!
Hello! This's a very clear video about resources. Thank you very much. Keep going.
Very well explained!
is request and limit confined to containers or pods? because if i specify request and limit values to pod where pod have multiple containers then in that case will all the containers get adequate amount of resource?
As you can see in docs kubernetes.io/docs/reference/generated/kubernetes-api/v1.14/#container-v1-core resources are specified for containers. Pod Resources consists of resources of all pod's containers
Very well presented information! Why couldn't the Kubernetes documentation just say "milli-cores" explicitly, I had to dig around to find that.
You say the values for each container are additive. Does this mean that if I have three pods, best practice should mean that the limt of 1 needs to be split between the three pods. i.e. I currently have limit 0.5 for main pod and 0.25 for the other two. Then the same for the requests. I have 0.6 for the the main pod and 0.2 for the other two.
Can you tell us what is hard limit in quota
too bad you can't throttle memory with swap 🤔
What about GPU resources? These are often more scarce than CPU memory of CPU cylces.
thank you for such a great video. you're amazing
Glad you enjoyed it!
throttling and the area between over-requested but below a hard limit is still unclear on what kubernetes really does
Thanks! In my case I had to use Mi as unity instead of Mib.
Keep up the good work 👍
What about swap RAM ?
what about GPU though?
I still can't understand what is defaultRequest. About what kind of request are we talking about? We can limit resources per let's say http request for container? And that's the default value specified, if I don't specify for a container? (Sorry this is first video I see from this channel)
The "default" are default limits of CPU and memory, while "defaultRequest" are default requests for the CPU and memory. You can think of "requests" as: Assign this much CPU and memory to the given container. So if you set CPU requests to e.g. 500m, there will always be half of the core reserved for you container on the node where it runs
- There are only two kinds of Resources that can be Requested/Limited in K8s (as per the video atleast): Memory & CPU
- 'defaultRequest' is specified with the 'limits' of K8s. When you are specifying limits, using 'defaultRequest' you can specify what is the default CPU and Memory 'request' by each Container, IF the container does not define one explicitly.
- Let's say you generate a YAML file for a container and don't mention the CPU and Memory request explicitly, and schedule it on a node which has the 'defaultRequest' set; then the container gets resources described by the 'defaultRequest'.
Hope this makes sense :)
are we imposing resource constraints on pod/container?
Thanks!!
have we all seen shifted tabulation at 5:15 ?)
My application needs SwAp Memory
but kuberntes doesnt support swap memory right
great video. not sure though why the human appearance is necessary