puppetlabs / facter

Collect and display system facts
https://puppet.com/open-source/#osp
Apache License 2.0
620 stars 497 forks source link

`processors.models` returns list of model names based on core count rather than physical count #2680

Closed jcpunk closed 8 months ago

jcpunk commented 8 months ago

Use Case

The processors.models fact can grow very large on systems with high core count, but low physical count. Since the model name is determined by the physical count, trimming this down to match the physical chips would reduce the sice of the fact list and avoid some confusion.

Describe the Solution You Would Like

Find the model name based on the physical chip used rather than just blindly for each core.

Describe Alternatives You've Considered

Filtering the fact out to reduce network burden.

Additional Context

I'm not sure if a set would be sufficient as you can infer if all the model names are identical than you have model count equal to physical count, but you wouldn't be able to directly count the number of different chips which would be handy.

joshcooper commented 8 months ago

@jcpunk We agree the current situation isn't great. Changing facter to return the model for each physical processor makes more sense, but would have to be done in Facter 5 or feature flagged. We don't have plans on addressing this anytime soon, but if you'd like to submit a PR to feature flag the behavior, then please do. I've added the help wanted label accordingly.

jcpunk commented 8 months ago

I fear I don't have sufficient ruby in my background for this to be fruitful... You'd basically have to hold my hand through far too much of the code...

cthorn42 commented 8 months ago

Thank you for reporting this issue. While we agree this is likely an improvement, we do not anticipate addressing this any time soon due to other issues demanding precedence. As such, this ticket will be closed as “Won’t Do”. We may revisit this at a later time, and if so, will re-open this ticket.

If you are interested in submitting a patch to implement this issue, please open a pull request and re-open this ticket.

jcpunk commented 8 months ago

Is there a facter v5 wishlist I could add this onto?