node-feature-discovery icon indicating copy to clipboard operation
node-feature-discovery copied to clipboard

Specify resource limits (and requests) in NFD deployment files

Open marquiz opened this issue 1 year ago • 2 comments

What would you like to be added:

Refs #1614

We should specify resource requests (cpu and memory requests and limits) in the NFD deployment files. I.e. both kustomize and Helm chart.

Why is this needed:

Best practices.

marquiz avatar Mar 14 '24 13:03 marquiz

We have https://github.com/kubernetes-sigs/node-feature-discovery/blob/master/deployment/helm/node-feature-discovery/values.yaml#L96

Commented and with a low request/limit. moving forward should be the opposite, it should be uncommented and users can comment out if they feel to.

Numbers should be

     limits:
       cpu: 300m
       memory: 1G
     requests:
       cpu: 100m
       memory: 128Mi

ArangoGutierrez avatar Mar 14 '24 14:03 ArangoGutierrez

/assign

TessaIO avatar Mar 14 '24 20:03 TessaIO

We have https://github.com/kubernetes-sigs/node-feature-discovery/blob/master/deployment/helm/node-feature-discovery/values.yaml#L96

Commented and with a low request/limit. moving forward should be the opposite, it should be uncommented and users can comment out if they feel to.

Numbers should be

     limits:
       cpu: 300m
       memory: 1G
     requests:
       cpu: 100m
       memory: 128Mi

Given that memory cannot be returned back to the pool once assigned, setting limits.memory and requests.memory to the same value will work better. In this case, 1Gi.

For CPU, it worth taking into consideration that setting a limit might cause throttling. If that's undesirable, then leaving limits.cpu unset is the way to go. Otherwise, it's fine.

cmontemuino avatar Mar 22 '24 16:03 cmontemuino