-
Helga Velroyen authored
This rather lenghy patch comprises a couple of refactorings to achieve the following goals: - 'gnt-node info' should only report space information about spindles, when exclusive storage is enabled on the node (so far it always did when lvm-based storage was enabled). - 'gnt-node info' should report the disks' space information for the default disk template's storage. So far it did it always for LVM, which is irrelevant for a cluster running for example file-based instances. - Performance tweaking of storage reporting and gnt-node info. - Consider the future work on storage pools for any changes. This is is achieved by the following refactorings: - Move the decision whether or not to ask for spindle from cmdlib-level to rpc level. - Move the decision for which disk template's storage information to ask for to cmdlib level (instead of requesting information for all storage units and later discarding most of them). - Adjustments to storage utility functions. - Affected unit tests are adjusted as well. Signed-off-by: Helga Velroyen <helgav@google.com> Reviewed-by: Klaus Aehlig <aehlig@google.com>
6c00b2c7