Uploaded image for project: 'Migration Toolkit for Virtualization'
  1. Migration Toolkit for Virtualization
  2. MTV-207

Optimize VM size during the migration

XMLWordPrintable

    • False
    • False

      One pattern often observed in virtualization platforms it that users requests more resources than necessary, just to be safe, and also because resizing the VM after its creation requires another ticket to the virtualization team. This is partly balanced by resources over commit allowed by CPU and memory sharing, but it makes the scheduling more complex.

      In Kubevirt, the resources are allocated as requests and limits, so they are reserved. When migrating from other virtualization platform, this can lead to over consumption and lower density than expected. In the end, running the same workloads may require more hardware.

      It would be great to understand the real consumption of the VMs in the source platform to adjust the size of the VMs in Kubevirt to the reality. This requires collecting metrics and aggregating them on a meaningful time window, to then propose 4 levels of optimization: none, conservative, moderate, aggressive. The user would then be able to select the optimization mode when creating a migration plan.

      Some notes provided by Jason Frey on how ManageIQ collects VMware metrics:

      The way it works on vmware is there are things called intervals: https://vdc-download.vmware.com/vmwb-repository/dcr-public/b50dcbbf-051d-4204-a3e7-e1b618c1e384/538cf2ec-b34f-4bae-a332-3820ef9e7773/vim.HistoricalInterval.html
      and the metric types are called counters: https://vdc-download.vmware.com/vmwb-repository/dcr-public/b50dcbbf-051d-4204-a3e7-e1b618c1e384/538cf2ec-b34f-4bae-a332-3820ef9e7773/vim.PerformanceManager.html#queryCounter.

      You ask what metrics are available and in what intervals for those metrics: https://vdc-download.vmware.com/vmwb-repository/dcr-public/b50dcbbf-051d-4204-a3e7-e1b618c1e384/538cf2ec-b34f-4bae-a332-3820ef9e7773/vim.PerformanceManager.html#queryAvailableMetric
      and then you can query a time range on that metric: https://vdc-download.vmware.com/vmwb-repository/dcr-public/b50dcbbf-051d-4204-a3e7-e1b618c1e384/538cf2ec-b34f-4bae-a332-3820ef9e7773/vim.PerformanceManager.html#queryStats

      The important part to understand that admins can disable or enable different intervals collection on the vsphere side [^ref], so you have to go through this discovery process and can't really hardcode...or if you do hardcode you have to be prepared that the metrics you expect may not be there.

            Unassigned Unassigned
            fdupont@redhat.com Fabien Dupont
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: