Re: CloudStack Uasge lists expunged Volumes. Is that correct?
the resource IDs would not necessarily be in the description of the event. so can you select from event where type like 'VOLUME.*' and see if anything is out there? "VOLUME.CREATE" is expected to be matched by "VOLUME.DELETE", "VOLUME.ATTACH" by "VOLUME.DETACH", etc. On Fri, May 18, 2018 at 1:03 PM, Melanie Desaive < m.desa...@heinlein-support.de> wrote: > Hi Daan, > > Am 18.05.2018 um 10:28 schrieb Daan Hoogland: > > > It seems that only 5 of those volumes should have been > > reported between the 16th and the 16th, correct? Can you query for events > > for those volumes in the event table? By the order of events we might be > > able to draw some conclusions. > > You asked for a query like the following? > > mysql> select description from event where description like '%%' or > description like '%2420%' or description like '%2567%' or description > like '%2719%' or description like '%2920%' or description like '%2528%' > or description like '%2809%' or description like '%2243%' or description > like '%2505%' or description like '%2396%' or description like '%3696%' > or description like '%2239%' or description like '%3174%' or description > like '%3675%' or description like '%2172%' or description like '%2225%' > or description like '%2223%' or description like '%3255%'; > Empty set (0.10 sec) > > This did not return any records. :( > > Or do you ask for a different kind of information? > > Greetings, > > Melanie > -- > -- > > Heinlein Support GmbH > Linux: Akademie - Support - Hosting > > http://www.heinlein-support.de > Tel: 030 / 40 50 51 - 0 > Fax: 030 / 40 50 51 - 19 > > Zwangsangaben lt. §35a GmbHG: > HRB 93818 B / Amtsgericht Berlin-Charlottenburg, > Geschäftsführer: Peer Heinlein -- Sitz: Berlin > > -- Daan
Re: CloudStack Uasge lists expunged Volumes. Is that correct?
Hi Daan, Am 18.05.2018 um 10:28 schrieb Daan Hoogland: > It seems that only 5 of those volumes should have been > reported between the 16th and the 16th, correct? Can you query for events > for those volumes in the event table? By the order of events we might be > able to draw some conclusions. You asked for a query like the following? mysql> select description from event where description like '%%' or description like '%2420%' or description like '%2567%' or description like '%2719%' or description like '%2920%' or description like '%2528%' or description like '%2809%' or description like '%2243%' or description like '%2505%' or description like '%2396%' or description like '%3696%' or description like '%2239%' or description like '%3174%' or description like '%3675%' or description like '%2172%' or description like '%2225%' or description like '%2223%' or description like '%3255%'; Empty set (0.10 sec) This did not return any records. :( Or do you ask for a different kind of information? Greetings, Melanie -- -- Heinlein Support GmbH Linux: Akademie - Support - Hosting http://www.heinlein-support.de Tel: 030 / 40 50 51 - 0 Fax: 030 / 40 50 51 - 19 Zwangsangaben lt. §35a GmbHG: HRB 93818 B / Amtsgericht Berlin-Charlottenburg, Geschäftsführer: Peer Heinlein -- Sitz: Berlin signature.asc Description: OpenPGP digital signature
Re: CloudStack Uasge lists expunged Volumes. Is that correct?
Melanie, The usage server hasn't really changed for 4.11 but it has some old behaviour that might be counter intuitive. The fact that an expunged volume is shown doesn't seem strange to me though. Before it was expunged it has existed. There has been usage for the volume so there should be a usage record. The question is whether usage after it's destroy time is reported. A customer of mine has seen that VMs where reported running while being destroyed. That is indeed a real annoyance and you might have something like that as well. It seems that only 5 of those volumes should have been reported between the 16th and the 16th, correct? Can you query for events for those volumes in the event table? By the order of events we might be able to draw some conclusions. On Thu, May 17, 2018 at 1:59 PM, Melanie Desaive < m.desa...@heinlein-support.de> wrote: > Hi all, > > I am just starting to have a first look on CloudStack Usage Service in > 4.11. > > Maybe I am getting something wrong, but to me it seems, that Usage > reports lists destroyed and expunged Volumes. Is that the intended > behaviour? > > For an example project it lists the following records: > > (rz-admin) :D > list usagerecords startdate=2018-05-16 > enddate=2018-05-16 projectid=a5496954-0f3c-4511-b54c-db9aa14ee9ac type=6 > filter=description, > count = 18 > usagerecord: > ++ > | description | > ++ > | Volume Id: usage time (Template: 471) | > | Volume Id: 2420 usage time (Template: 521) | > | Volume Id: 2567 usage time (DiskOffering: 147) | > | Volume Id: 2719 usage time (DiskOffering: 96) | > | Volume Id: 2920 usage time (DiskOffering: 95) | > | Volume Id: 2528 usage time (Template: 521) | > | Volume Id: 2809 usage time (Template: 394) | > | Volume Id: 2243 usage time (Template: 467) | > | Volume Id: 2505 usage time (Template: 394) | > | Volume Id: 2396 usage time (Template: 517) | > | Volume Id: 3696 usage time (Template: 521) | > | Volume Id: 2239 usage time (Template: 400) | > | Volume Id: 3174 usage time (DiskOffering: 95) | > | Volume Id: 3675 usage time (Template: 521) | > | Volume Id: 2172 usage time (Template: 394) | > | Volume Id: 2225 usage time (Template: 390) | > | Volume Id: 2223 usage time (Template: 471) | > | Volume Id: 3255 usage time (Template: 521) | > ++ > > Quering the IDs in the database I get records for a lot of destroyed and > expunged volumes. > > mysql> select distinct id,removed,state from volumes where id= or > id=2420 or id=2567 or id=2719 or id=2920 or id=2528 or id=2809 or > id=2243 or id=2505 or id=2396 or id=3696 or id=2239 or id=3174 or > id=3675 or id=2172 or id=2225 or id=2223 or id=3255 order by id; > +--+-+--+ > | id | removed | state| > +--+-+--+ > | 2172 | 2017-08-28 12:37:57 | Destroy | > | | 2017-01-30 13:06:40 | Destroy | > | 2223 | 2017-01-30 12:08:54 | Destroy | > | 2225 | 2017-01-30 13:06:21 | Destroy | > | 2239 | 2017-02-09 13:25:26 | Destroy | > | 2243 | 2017-08-28 12:28:36 | Destroy | > | 2396 | 2017-05-15 10:13:24 | Destroy | > | 2420 | 2017-08-28 11:48:57 | Destroy | > | 2505 | NULL| Ready| > | 2528 | 2017-07-15 08:54:32 | Destroy | > | 2567 | 2017-08-28 12:27:57 | Destroy | > | 2719 | 2017-07-15 09:03:36 | Expunged | > | 2809 | 2017-07-25 12:51:50 | Destroy | > | 2920 | 2017-10-24 12:12:05 | Expunged | > | 3174 | NULL| Ready| > | 3255 | NULL| Ready| > | 3675 | NULL| Ready| > | 3696 | NULL| Ready| > +--+-+--+ > 18 rows in set (0.00 sec) > > I would usage expect to list only the volumes actually provisioned. So > listing "Destroyed" volumes might be to be expected. But listing > "Expunged" volumes seems wrong to me. > > Greetings, > > Melanie > -- > -- > > Heinlein Support GmbH > Linux: Akademie - Support - Hosting > > http://www.heinlein-support.de > Tel: 030 / 40 50 51 - 0 > Fax: 030 / 40 50 51 - 19 > > Zwangsangaben lt. §35a GmbHG: > HRB 93818 B / Amtsgericht Berlin-Charlottenburg, > Geschäftsführer: Peer Heinlein -- Sitz: Berlin > > -- Daan
CloudStack Uasge lists expunged Volumes. Is that correct?
Hi all, I am just starting to have a first look on CloudStack Usage Service in 4.11. Maybe I am getting something wrong, but to me it seems, that Usage reports lists destroyed and expunged Volumes. Is that the intended behaviour? For an example project it lists the following records: (rz-admin) :D > list usagerecords startdate=2018-05-16 enddate=2018-05-16 projectid=a5496954-0f3c-4511-b54c-db9aa14ee9ac type=6 filter=description, count = 18 usagerecord: ++ | description | ++ | Volume Id: usage time (Template: 471) | | Volume Id: 2420 usage time (Template: 521) | | Volume Id: 2567 usage time (DiskOffering: 147) | | Volume Id: 2719 usage time (DiskOffering: 96) | | Volume Id: 2920 usage time (DiskOffering: 95) | | Volume Id: 2528 usage time (Template: 521) | | Volume Id: 2809 usage time (Template: 394) | | Volume Id: 2243 usage time (Template: 467) | | Volume Id: 2505 usage time (Template: 394) | | Volume Id: 2396 usage time (Template: 517) | | Volume Id: 3696 usage time (Template: 521) | | Volume Id: 2239 usage time (Template: 400) | | Volume Id: 3174 usage time (DiskOffering: 95) | | Volume Id: 3675 usage time (Template: 521) | | Volume Id: 2172 usage time (Template: 394) | | Volume Id: 2225 usage time (Template: 390) | | Volume Id: 2223 usage time (Template: 471) | | Volume Id: 3255 usage time (Template: 521) | ++ Quering the IDs in the database I get records for a lot of destroyed and expunged volumes. mysql> select distinct id,removed,state from volumes where id= or id=2420 or id=2567 or id=2719 or id=2920 or id=2528 or id=2809 or id=2243 or id=2505 or id=2396 or id=3696 or id=2239 or id=3174 or id=3675 or id=2172 or id=2225 or id=2223 or id=3255 order by id; +--+-+--+ | id | removed | state| +--+-+--+ | 2172 | 2017-08-28 12:37:57 | Destroy | | | 2017-01-30 13:06:40 | Destroy | | 2223 | 2017-01-30 12:08:54 | Destroy | | 2225 | 2017-01-30 13:06:21 | Destroy | | 2239 | 2017-02-09 13:25:26 | Destroy | | 2243 | 2017-08-28 12:28:36 | Destroy | | 2396 | 2017-05-15 10:13:24 | Destroy | | 2420 | 2017-08-28 11:48:57 | Destroy | | 2505 | NULL| Ready| | 2528 | 2017-07-15 08:54:32 | Destroy | | 2567 | 2017-08-28 12:27:57 | Destroy | | 2719 | 2017-07-15 09:03:36 | Expunged | | 2809 | 2017-07-25 12:51:50 | Destroy | | 2920 | 2017-10-24 12:12:05 | Expunged | | 3174 | NULL| Ready| | 3255 | NULL| Ready| | 3675 | NULL| Ready| | 3696 | NULL| Ready| +--+-+--+ 18 rows in set (0.00 sec) I would usage expect to list only the volumes actually provisioned. So listing "Destroyed" volumes might be to be expected. But listing "Expunged" volumes seems wrong to me. Greetings, Melanie -- -- Heinlein Support GmbH Linux: Akademie - Support - Hosting http://www.heinlein-support.de Tel: 030 / 40 50 51 - 0 Fax: 030 / 40 50 51 - 19 Zwangsangaben lt. §35a GmbHG: HRB 93818 B / Amtsgericht Berlin-Charlottenburg, Geschäftsführer: Peer Heinlein -- Sitz: Berlin signature.asc Description: OpenPGP digital signature