pod and cluster storage_pools resources is missing pool id

Bug #1949681 reported by Caleb Ellis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
Undecided
Christian Grabowski

Bug Description

Sorry, it turns out we need one last piece of data for the pools in both pod.resources.storage_pools and vmcluster.total_resources.storage_pools - the pool id. We get this in pod.storage_pools and it's used for sorting as well as determining what the default pool should be used when composing a VM.

e.g. in pod.storage_pools:
{
  storage_pools: [
    {
      id: 'b85e27c9-9d53-4821-ad64-153c53767ce9',
      name: 'default',
      type: 'dir',
      path: '/var/lib/libvirt/images',
      total: 984373800960,
      used: 40000000000,
      available: 944373800960
    }
  ]
}

and in pod.resources.storage_pools:
{
  storage_pools: {
    'default': {
      name: 'default',
      path: '/var/lib/libvirt/images',
      backend: 'dir',
      allocated_tracked: 40000000000,
      allocated_other: 0,
      total: 984373800960
    }
  }
}

Related branches

Changed in maas:
assignee: nobody → Christian Grabowski (cgrabowski)
status: New → Triaged
status: Triaged → In Progress
Revision history for this message
Christian Grabowski (cgrabowski) wrote :

While this works for pods, and can be added to pod.resources.storage_pools, only some storage pools on the cluster can have an id, as dir, zfs and btrfs backed storage pools are actually an aggregate of multiple storage pools within the cluster (1 per pod/VMHost), so these would have multiple pool ids. The default pool when composing should be from the pod selected, so if it is for the purpose of sorting, a list of ids can be provide, but would that be usable for the UI?

Revision history for this message
Caleb Ellis (caleb-ellis) wrote :

Hmm good point, a list of ids wouldn't really be usable by the UI. In that case I think just having the pool id there for pods would be fine, and for clusters we'll just handle it differently i.e. ignore sorting by id

Changed in maas:
milestone: none → 3.1.0
status: In Progress → Fix Committed
Alberto Donato (ack)
Changed in maas:
milestone: 3.1.0 → 3.1.0-rc1
Alberto Donato (ack)
Changed in maas:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.