<html>
  <head>
    <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Hi Eoghan,<br>
      <br>
      Thanks for your reply. As we can see from the document: <br>
-------------------------------------------------------------------------<br>
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <p style="margin-top: 0.8em; margin-right: 0px; margin-bottom:
        0.5em; margin-left: 0px; color: rgb(0, 0, 0); font-family:
        ff-meta-web-pro-1, ff-meta-web-pro-2, Arial, 'Helvetica Neue',
        sans-serif; font-size: 16px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 24px; orphans: 2; text-align: left; text-indent:
        0px; text-transform: none; white-space: normal; widows: 2;
        word-spacing: 0px; -webkit-text-size-adjust: auto;
        -webkit-text-stroke-width: 0px; background-color: rgb(255, 255,
        255); ">Three type of meters are defined in ceilometer:</p>
      <table class="docutils" id="index-0" style="border-collapse:
        collapse; margin: 0px -0.5em; border-width: 0px; color: rgb(0,
        0, 0); font-family:
        ff-meta-web-pro-1,ff-meta-web-pro-2,Arial,'Helvetica
        Neue',sans-serif; font-size: 16px; font-style: normal;
        font-variant: normal; font-weight: normal; letter-spacing:
        normal; line-height: 24px; orphans: 2; text-align: left;
        text-indent: 0px; text-transform: none; white-space: normal;
        widows: 2; word-spacing: 0px; background-color: rgb(255, 255,
        255);" height="92" width="658" border="1">
        <colgroup><col width="11%"><col width="89%"></colgroup><thead
          valign="bottom"><tr class="row-odd">
            <th class="head" style="text-align: left; padding-right:
              8px; padding-top: 1px; padding-bottom: 1px; padding-left:
              5px; border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Type</th>
            <th class="head" style="text-align: left; padding-right:
              8px; padding-top: 1px; padding-bottom: 1px; padding-left:
              5px; border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Definition</th>
          </tr>
        </thead><tbody valign="top">
          <tr class="row-even">
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Cumulative</td>
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Increasing over time (instance hours)</td>
          </tr>
          <tr class="row-odd">
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Gauge</td>
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Discrete items (floating IPs, image uploads)
              and fluctuating values (disk I/O)</td>
          </tr>
          <tr class="row-even">
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Delta</td>
            <td style="padding-top: 1px; padding-right: 8px;
              padding-bottom: 1px; padding-left: 5px; text-align: left;
              border-top-width: 0px; border-top-style: initial;
              border-top-color: initial; border-left-width: 0px;
              border-left-style: initial; border-left-color: initial;
              border-right-width: 0px; border-right-style: initial;
              border-right-color: initial; border-bottom-width: 1px;
              border-bottom-style: solid; border-bottom-color: rgb(170,
              170, 170); ">Changing over time (bandwidth)</td>
          </tr>
        </tbody>
      </table>
      <p style="margin-top: 0.8em; margin-right: 0px; margin-bottom:
        0.5em; margin-left: 0px; color: rgb(0, 0, 0); font-family:
        ff-meta-web-pro-1, ff-meta-web-pro-2, Arial, 'Helvetica Neue',
        sans-serif; font-size: 16px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 24px; orphans: 2; text-align: left; text-indent:
        0px; text-transform: none; white-space: normal; widows: 2;
        word-spacing: 0px; -webkit-text-size-adjust: auto;
        -webkit-text-stroke-width: 0px; background-color: rgb(255, 255,
        255); ">----------------------------------------------------------------------------------------<br>
      </p>
      <p style="margin-top: 0.8em; margin-right: 0px; margin-bottom:
        0.5em; margin-left: 0px; color: rgb(0, 0, 0); font-family:
        ff-meta-web-pro-1, ff-meta-web-pro-2, Arial, 'Helvetica Neue',
        sans-serif; font-size: 16px; font-style: normal; font-variant:
        normal; font-weight: normal; letter-spacing: normal;
        line-height: 24px; orphans: 2; text-align: left; text-indent:
        0px; text-transform: none; white-space: normal; widows: 2;
        word-spacing: 0px; -webkit-text-size-adjust: auto;
        -webkit-text-stroke-width: 0px; background-color: rgb(255, 255,
        255); ">Cumulative type is apparent, while even with
        descriptions gauge and delta type confuse me.<br>
        Could you explain them through examples or by sharing an use
        case? <br>
      </p>
      <br>
      Thanks<br>
      <br>
      <pre wrap="">-----------------------
Yawei Wu
Dalian Hi-Think Computer Technology,Corp.

</pre>
      <br>
    </div>
    <blockquote
      cite="mid:1505758973.51174284.1351693389620.JavaMail.root@redhat.com"
      type="cite">
      <pre wrap="">

Hi Yawei Wu,

The root of the confusion is the fact the cpu meter is reporting
the cumlative cpu_time stat from libvirt. This libvirt counter is
reset when the associated qemu process is restarted (an artifact
of how cpuacct works).

So when you stop/start or suspend/resume, a fresh qemu process
is sparked up, then the cumulative time is reset.

Thanks for bringing this up, as it has implications as to how
we meter CPU time and utilization[1].

We may need to start metering the delta between CPU times on 
subsequent polling cycles, instead of using a cumulative meter
(dealing with the edge case where the instance has been restarted
within a polling period).

Cheers,
Eoghan

[1] <a class="moz-txt-link-freetext" href="https://review.openstack.org/14921">https://review.openstack.org/14921</a>


</pre>
      <blockquote type="cite">
        <pre wrap="">I am still testing ceilometer now. I am confused about the meter
volume
in the mongodb. Let's talk about cpu usage.

After I create and boot a vm named vm_1, meter data record about cpu
usage will be inserted into db in cycle(default 10 minutes). For
example,the 'counter_volume' of the first record is '52060000000',and
the second one is '123890000000'.

1) '123890000000' nanoseconds means '123.89' seconds or two
minutes,it
seem like to be 1238.9 seconds actually, is there something wrong ?

2) If I never reboot or suspend vm_1, will the 'counter_volume' of
cpu
usage record increase all the time ? Just like '8 minutes' -> '18
minutes' -> '28 minutes' ?

3) If I reboot or suspend vm_1, I find that the 'counter_volume' of
cpu
usage record will count from zero. Just like '8 minutes' -> '18
minutes'
-> '28 minutes' [-> '0 minutes'] ->'5 minutes' -> '15 minutes'. Does
it
mean that 'counter_volume' just represents how long has vm_1 been
booted
up ?

4) This one is about Web API. I find that "GET
/v1/resources/(resource)/meters/(meter)/volume/sum" just return the
sum
value of all the cpu 'counter_volume', like '8 minutes' + '18
minutes'.
Is it reduplicate ?

5) If I want to know how long has vm_1's cpu been used yesterday, how
can I do ?

It seems like that I have too many questions..

Thank you very much !


-----------------------
Yawei Wu
Dalian Hi-Think Computer Technology,Corp.

_______________________________________________
Mailing list: <a class="moz-txt-link-freetext" href="https://launchpad.net/~openstack">https://launchpad.net/~openstack</a>
Post to     : <a class="moz-txt-link-abbreviated" href="mailto:openstack@lists.launchpad.net">openstack@lists.launchpad.net</a>
Unsubscribe : <a class="moz-txt-link-freetext" href="https://launchpad.net/~openstack">https://launchpad.net/~openstack</a>
More help   : <a class="moz-txt-link-freetext" href="https://help.launchpad.net/ListHelp">https://help.launchpad.net/ListHelp</a>

</pre>
      </blockquote>
    </blockquote>
    <br>
  </body>
</html>