Swen, I think you are right, except maybe textual; in your case the id of the VM is 62 and the id of the vm the volume belongs to is 26. I am assuming here that there is no bug that transposes the digits of the id. regards,
On Thu, Mar 23, 2023 at 5:42 PM <m...@swen.io> wrote: > Hey all, > > > > I am playing around with usage records and I am a little bit stuck in > understanding some mappings. As far as I see it is not possible to map a > volume to a virtual machine by using the usage records only. Is this > correct, or do I miss something? Any idea? > > > > Here is the usage records output for 1 vm: > > > > "account": "admin", > > "accountid": "8ef6bd85-86a3-11ed-b0af-5a15ae8c1838", > > "domainid": "ee2aff59-86a2-11ed-b0af-5a15ae8c1838", > > "domain": "ROOT", > > "zoneid": "73d1a241-5719-4771-b3fd-a9943de2bb87", > > "description": "Running VM usage for mysql3 (i-2-62-VM) > (2000b926-003c-467e-9493-63f5faa59a69) using service offering Instance > LocalSSD - Default 10GB SSD (8201645c-3428-4aef-a0c4-8bd066d30d8f) and > template Ubuntu 22.04 LTS 64bit (ed8a6760-b23e-494c-84a1-7f55e5035a7c)", > > "usage": "1 Hrs", > > "usagetype": 1, > > "rawusage": 1, > > "virtualmachineid": > "2000b926-003c-467e-9493-63f5faa59a69", > > "name": "mysql3", > > "offeringid": "8201645c-3428-4aef-a0c4-8bd066d30d8f", > > "templateid": "ed8a6760-b23e-494c-84a1-7f55e5035a7c", > > "ostypeid": "ef326446-86a2-11ed-b0af-5a15ae8c1838", > > "osdisplayname": "Other Ubuntu (64-bit)", > > "oscategoryid": "ee62e83d-86a2-11ed-b0af-5a15ae8c1838", > > "oscategoryname": "Ubuntu", > > "usageid": "2000b926-003c-467e-9493-63f5faa59a69", > > "type": "XenServer", > > "cpunumber": 1, > > "cpuspeed": 2000, > > "memory": 1024, > > "startdate": "2023-03-22'T'11:00:00+01:00", > > "enddate": "2023-03-22'T'11:59:59+01:00", > > "tags": [ > > > > ] > > > > And here is the usage records output of 1 volume: > > > > "account": "admin", > > "accountid": "8ef6bd85-86a3-11ed-b0af-5a15ae8c1838", > > "domainid": "ee2aff59-86a2-11ed-b0af-5a15ae8c1838", > > "domain": "ROOT", > > "zoneid": "73d1a241-5719-4771-b3fd-a9943de2bb87", > > "description": "Volume usage for ROOT-26 (null) with > disk offering Custom LocalSSD (5684e5ac-bf27-4a94-93e9-12d07f0c60f4) and > size (10.00 GB) 10737418240", > > "usage": "1 Hrs", > > "usagetype": 6, > > "rawusage": 1, > > "offeringid": "5684e5ac-bf27-4a94-93e9-12d07f0c60f4", > > "size": 10737418240, > > "startdate": "2023-03-22'T'11:00:00+01:00", > > "enddate": "2023-03-22'T'11:59:59+01:00", > > "tags": [ > > > > ] > > -- Daan