Giter Club home page Giter Club logo

Comments (9)

56quarters avatar 56quarters commented on May 30, 2024

When setting GOMAXPROCS we prefer to do it in the Jsonnet or Helm chart based on testing. It's unlikely we'd ever want components doing it automatically.

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

yes, it goes over a variable, same as the limit/requests are set.

but, we have to inform the container about the resources that linux will provide.

to avoid the container to be killed, it will go slow but will not be killed.
and cpu the same, it will run slow but it will not be throttled.

slow x crash.

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

it will work like this, close to limit, but never cross it:

image

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

the documentation:
https://github.com/uber-go/automaxprocs

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

not sure why it is marked closed.

it is related to Mimir
https://github.com/grafana/mimir/tree/main/operations/helm/charts/mimir-distributed

from mimir.

56quarters avatar 56quarters commented on May 30, 2024

I don't understand your point. GOMAXPROCS and GOMEMLIMIT can already be set via the Helm chart or Jsonnet today to whatever values you like. Automatically setting them from the application binary using automaxprocs is not something we're interested in doing. The behavior you're describing is already possible today with no changes.

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

today, we are getting ingester crash due OutofMemory.

in order to use GOMAXPROCS and GOMEMLIMIT, we shall include into the code

_ "go.uber.org/automaxprocs"

and compile it.

during the startup it will show :

image

must be on import:

image

from mimir.

56quarters avatar 56quarters commented on May 30, 2024

in order to use GOMAXPROCS and GOMEMLIMIT, we shall include into the code

Using these variables doesn't require the automaxprocs library, they're supported by the go runtime.

I'd suggest you read this documentation:

https://pkg.go.dev/runtime#GOMAXPROCS

https://dave.cheney.net/2015/11/29/a-whirlwind-tour-of-gos-runtime-environment-variables

from mimir.

valdemarpavesi avatar valdemarpavesi commented on May 30, 2024

good point, Thanks Nick

I will test it

  env: 
    - name: GOMAXPROCS
      value: 8
    - name: GOMEMLIMIT
      value: "42GiB"

and

ingester:
 persistentVolume:
   size: 40Gi
 replicas: 3
 resources:
   limits:
     memory: 42Gi
     cpu: 8
   requests:
     cpu: 4
     memory: 12Gi
     

from mimir.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.