IN Zapi, I did this originally, so I could have access to which aggregates disks are associated with.
name: Disk
query: storage-disk-get-iter
object: disk
counters:
storage-disk-info:
- disk-inventory-info:
- ^firmware-revision => firmware_revision
- disk-raid-info:
- disk-aggregate-info:
- ^aggregate-name => aggregate
- disk-shared-info:
- aggregate-list:
- shared-aggregate-info:
- ^aggregate-name => aggregate
plugins:
- ChangeLog:
track:
- disk
- index
- node
- model
- firmware_revision
- serial_number
- outage
- failed
- aggregate
export_options:
instance_keys:
- container_type
- failed
- model
- aggregate
instance_labels:
- firmware_revision
It also affords us when any of the items listed in ChangeLog 'changes' so that we can make sure we don't have any disks with incorrect firmware (or we denote we have a newer disk firmware we got when it was replaced, etc)
I was attempting to do this with REST and EVERYTHING works with exception of 'aggregate'. I can't seem to get it to populate like under ZAPI, even though the information is there as it was in ZAPI.
Thoughts?