Details
Description
OpenVZ allows for containers to be provided with "burst" memory and CPU allocations. When this style configuration is implemented on a container, /proc/cpuinfo and /proc/meminfo return this allocation, which really isn't accurate. Right now we have to include a good chunk of logic in our recipes to determine the proper values.
Instead, if the system is discovered as an OpenVZ guest (See http://tickets.opscode.com/browse/OHAI-249), we should parse /proc/user_beancounters and determine the "guaranteed" memory & CPU allocations.
I'm not entirely sure if this code should be placed here:
https://github.com/opscode/ohai/blob/master/lib/ohai/plugins/linux/cpu.rb
https://github.com/opscode/ohai/blob/master/lib/ohai/plugins/linux/memory.rb
Or if we should place the code here:
https://github.com/opscode/ohai/blob/master/lib/ohai/plugins/linux/virtualization.rb
And have it override any values discovered by cpu.rb & memory.rb.
Any insight/suggestions would be appreciated! Thanks!
Activity
- All
- Comments
- History
- Activity
- Transitions Summary