Project

General

Profile

Actions

Bug #26656

closed

Display memory in consistent way

Added by Moti Asayag over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
-
Difficulty:
medium
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

Based on the feedback from the mailing list:

Can you explain why one VM showed 1024Mi where others showed 1Gi for the memory?
It looked like it came straight from the API since the console also showed 1Gi where Foreman normally uses GB.

We need to make sure to always use GB while displaying virtual machine memory.
---
There is inconsistency in the reported memory - we should normalize it to a single units:


2.3.3 :016 > c.servers.map { |s| s.memory }
=> ["1Gi", "1024Mi", "1024Mi", "1024M"]

So we got Gi, Mi and M - but that doesn't contradict:
https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/#meaning-of-memory

However, can fractions be specified ? Assuming user would like less than 1G vm ?
We faced similar issue with MIQ kubevirt provider here:
https://github.com/ManageIQ/manageiq-providers-kubevirt/blob/master/app/models/manageiq/providers/kubevirt/memory_calculator.rb#L31

Actions

Also available in: Atom PDF