Re: [openstack-dev] [ceilometer] unable to collect compute.node.cpu.* data

2014-11-07 Thread Hang H Liu
 phil.n...@hp.com:
 Frank, I'd echo Hang Liu's suggestion, but also encourage you to
 take this question to the general OpenStack mailing
 list (see https://wiki.openstack.org/wiki/Mailing_Lists).

 - Phil

 From: Hang H Liu [mailto:hang...@cn.ibm.com]
 Sent: Wednesday, November 05, 2014 7:36 AM
 To: OpenStack Development Mailing List (not for usage questions)
 Subject: Re: [openstack-dev] [ceilometer] unable to collect
 compute.node.cpu.* data

 Same steps I can get below results.
 You may need debug into get_meters() in ceilometer/storage/
 impl_sqlalchemy.py to see if some filters are taking effect.


 localadmin@ostest2:~/devstack$ ceilometer meter-list
 +-++-
 +--
 +--+--+
 | Name                            | Type       | Unit    | Resource
 ID                          | User ID                          |
 Project ID                       |
 +-++-
 +--
 +--+--+
 | compute.node.cpu.frequency      | gauge      | MHz     |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.idle.percent   | gauge      | %       |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.idle.time      | cumulative | ns      |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.iowait.percent | gauge      | %       |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.iowait.time    | cumulative | ns      |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.kernel.percent | gauge      | %       |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.kernel.time    | cumulative | ns      |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.percent        | gauge      | %       |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.user.percent   | gauge      | %       |
 ostest2_ostest2                      | None
     | None                             |
 | compute.node.cpu.user.time      | cumulative | ns      |
 ostest2_ostest2                      | None



 Lu, Lianhao lianhao...@intel.com 写于 2014/11/05 15:23:14:

  From: Lu, Lianhao lianhao...@intel.com
  To: OpenStack Development Mailing List (not for usage questions)
  openstack-dev@lists.openstack.org
  Date: 2014/11/05 15:31
  Subject: Re: [openstack-dev] [ceilometer] unable to collect
  compute.node.cpu.* data
 
  Hi Frank,
 
  Could you try ‘celometer sample-list’ to see if the compute.node.cpu
  samples are there?
 
  -Lianhao
 
  From: Du Jun [mailto:dj199...@gmail.com]
  Sent: Wednesday, November 05, 2014 3:44 AM
  To: openstack-dev@lists.openstack.org
  Subject: [openstack-dev] [ceilometer] unable to collect
  compute.node.cpu.* data
 
  Hi all,
 
  I attempt to collect compute.node.cpu as the following link mentions:
 
  http://docs.openstack.org/developer/ceilometer/
 measurements.html#compute-nova
 
  I set:
 
  compute_monitors = ComputeDriverCPUMonitor
 
  in /etc/nova/nova.conf and restart nova-compute, nova-scheduler,
  ceilometer-agent-notification, ceilometer-api, ceilometer-collector.
 
  From ceilometer-agent-notification's log, I can see agent transform
  and publish data samples compute.node.cpu.*
 
  What's more, from ceilometer database, I can see all the meters
  compute.node.cpu.*
 
  mysql select * from meter;
  ++-++---+
  | id | name                            | type       | unit      |
  ++-++---+
  | 39 | compute.node.cpu.frequency      | gauge      | MHz       |
  | 41 | compute.node.cpu.idle.percent   | gauge      | %         |
  | 38 | compute.node.cpu.idle.time      | cumulative | ns        |
  | 45 | compute.node.cpu.iowait.percent | gauge      | %         |
  | 42 | compute.node.cpu.iowait.time    | cumulative | ns        |
  | 36 | compute.node.cpu.kernel.percent | gauge      | %         |
  | 44 | compute.node.cpu.kernel.time    | cumulative | ns        |
  | 37 | compute.node.cpu.percent        | gauge      | %         |
  | 43 | compute.node.cpu.user.percent   | gauge      | %         |
  | 40 | compute.node.cpu.user.time      | cumulative | ns        |
 
 
  However, when I type
 
  ceilometer meter-list
 
  It shows nothing about compute.node.cpu.*, so I wonder what's wrong
  with my steps.
 
  --
  Regards,
  Frank___
  OpenStack-dev mailing list

Re: [openstack-dev] [heat] How to expose the error messages if the heat stack creation fails with software config/software deployment

2014-11-06 Thread Hang H Liu

Hi, Tao Tao,

Here is an example,

DEBUG (session) REQ: curl -i -X GET
http://9.186.100.22:8004/v1/f334fc078b944b60a08d121022fae0f0/stacks/s1
... ...

RESP BODY:
{ stack : { capabilities : [  ],

  ... ...

  parent : null,
  stack_name : s1,
  stack_owner : admin,
  stack_status : CREATE_FAILED,
  stack_status_reason : Resource CREATE failed: Error: Resource
CREATE failed: Forbidden: Quota exceeded for instances: Requested 1, but
already used 4 of 4 instances (HTTP 403) (Request-ID:
req-02784ecc-4713-4601-84b5-099586d7b436),
  template_description : Creates an autoscaling application using
Ceilometer.,
  timeout_mins : null,
  updated_time : null
} }


Whether stack_status_reason can satisfy your requirement?


Best Regards,
Liu, Hang(Henry)

--
hang...@cn.ibm.com | Tel: +8610-58748871   | ITN: 6-9058871
--
OpenStack-dev mailing list
OpenStack-dev@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev



Tao Tao t...@us.ibm.com 写于 2014/11/07 08:08:17:

 From: Tao Tao t...@us.ibm.com
 To: OpenStack Development Mailing List \(not for usage questions\)
 openstack-dev@lists.openstack.org
 Date: 2014/11/07 08:11
 Subject: Re: [openstack-dev] [heat] How to expose the error messages
 if the heat stack creation fails with software config/software deployment

 Hi, Ton:

 Thanks for your kind reply.

 What I really mean is how to expose the error messages so that I can
 use Heat REST API to find the error messages?

 In another word, how would a user to be able to find out the
 specific error message as a Heat client?


 Thanks,
 Tao Tao, Ph.D.
 IBM T. J. Watson Research Center
 1101 Kitchawan Road
 Yorktown Heights, NY 10598
 Phone: (914) 945-4541
 Email: t...@us.ibm.com

 [图像已删除] Ton Ngo---11/06/2014 07:04:30 PM---Hi Tao Tao,If
 you use Ubuntu image, you can check /var/log/syslog

 From: Ton Ngo/Watson/IBM@IBMUS
 To: OpenStack Development Mailing List \(not for usage questions\)
 openstack-dev@lists.openstack.org
 Date: 11/06/2014 07:04 PM
 Subject: Re: [openstack-dev] [heat] How to expose the error messages
 if the heat stack creation fails with software config/software deployment



 Hi Tao Tao,
   If you use Ubuntu image, you can check /var/log/syslog
 Look for section like:
 Running /opt/stack/os-config-refresh/configure.d/20-os-apply-config
 You should see the logs for running the script, error message, script
 output
 The scripts are stored on the VM instance
 in:  /var/lib/heat-config/heat-config-script
 Ton Ngo,



 From: Tao Tao/Watson/IBM@IBMUS
 To: OpenStack List openstack-dev@lists.openstack.org
 Date: 11/06/2014 12:09 PM
 Subject: [openstack-dev] [heat] How to expose the error messages if the
heat stack creation fails with software config/software
deployment



 Hi, All:

 When the heat stack creation fails due to software config/software
 deployment with scripts/chef/puppet, we are not able to locate the error
 message with Heat REST APIs.

 What is the best practice to solve this problem?


 Thanks,
 Tao Tao, Ph.D.
 IBM T. J. Watson Research Center
 1101 Kitchawan Road
 Yorktown Heights, NY 10598
 Phone: (914) 945-4541
 Email: t...@us.ibm.com___
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev



 ___
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

 ___
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev___
OpenStack-dev mailing list
OpenStack-dev@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [heat] How to expose the error messages if the heat stack creation fails with software config/software deployment

2014-11-06 Thread Hang H Liu
I am using devstack, which should be juno version.

Best Regards,
Liu, Hang(Henry)

 --
 hang...@cn.ibm.com | Tel: +8610-58748871   | ITN: 6-9058871
 --
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
Tao Tao t...@us.ibm.com 写于 2014/11/07 11:17:49:

 From: Tao Tao t...@us.ibm.com
 To: OpenStack Development Mailing List \(not for usage questions\)
 openstack-dev@lists.openstack.org
 Date: 2014/11/07 11:21
 Subject: Re: [openstack-dev] [heat] How to expose the error messages
 if the heat stack creation fails with software config/software deployment

 Hi, Henry:

 Appreciate very much for your kind reply!

 Yes, this is what I want, however, I am not seeing the detailed
 error message as you are seeing.

 I am still using OpenStack Icehouse, are you using OpenStack Juno
orIcehouse?

 [root@openstack-03 heat(keystone_admin)]# heat stack-show LCH_test1
 +--

+--

 +
 | Property | Value
|
 +--

+

 |
 | stack_status_reason  | Resource CREATE failed: Error: Deployment
 to server
|
 |  | failed: deploy_status_code : Deployment
 exited with
|
 |  | non-zero status code: 1
|

|
 +--

+--

 +


 Thanks,
 Tao Tao, Ph.D.
 IBM T. J. Watson Research Center
 1101 Kitchawan Road
 Yorktown Heights, NY 10598
 Phone: (914) 945-4541
 Email: t...@us.ibm.com

 [图像已删除] Hang H Liu ---11/06/2014 09:53:40 PM---Hi, Tao Tao,
 Here is an example,

 From: Hang H Liu hang...@cn.ibm.com
 To: OpenStack Development Mailing List \(not for usage questions\)
 openstack-dev@lists.openstack.org
 Date: 11/06/2014 09:53 PM
 Subject: Re: [openstack-dev] [heat] How to expose the error messages
 if the heat stack creation fails with software config/software deployment



 Hi, Tao Tao,

 Here is an example,

 DEBUG (session) REQ: curl -i -X GET http://9.186.100.22:8004/v1/
 f334fc078b944b60a08d121022fae0f0/stacks/s1  ... ...

 RESP BODY:
 { stack : { capabilities : [  ],

  ... ...

  parent : null,
  stack_name : s1,
  stack_owner : admin,
  stack_status : CREATE_FAILED,
  stack_status_reason : Resource CREATE failed: Error:
 Resource CREATE failed: Forbidden: Quota exceeded for instances:
 Requested 1, but already used 4 of 4 instances (HTTP 403) (Request-
 ID: req-02784ecc-4713-4601-84b5-099586d7b436),
  template_description : Creates an autoscaling application
 using Ceilometer.,
  timeout_mins : null,
  updated_time : null
} }


 Whether stack_status_reason can satisfy your requirement?


 Best Regards,
 Liu, Hang(Henry)

 --
 hang...@cn.ibm.com | Tel: +8610-58748871   | ITN: 6-9058871
 --
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev



 Tao Tao t...@us.ibm.com 写于 2014/11/07 08:08:17:

  From: Tao Tao t...@us.ibm.com
  To: OpenStack Development Mailing List \(not for usage questions\)
  openstack-dev@lists.openstack.org
  Date: 2014/11/07 08:11
  Subject: Re: [openstack-dev] [heat] How to expose the error messages
  if the heat stack creation fails with software config/software
deployment
 
  Hi, Ton:
 
  Thanks for your kind reply.
 
  What I really mean is how to expose the error messages so that I can
  use Heat REST API to find the error messages?
 
  In another word, how would a user to be able to find out the
  specific error message as a Heat client?
 
 
  Thanks,
  Tao Tao, Ph.D.
  IBM T. J. Watson Research Center
  1101 Kitchawan Road
  Yorktown Heights, NY 10598
  Phone: (914) 945-4541
  Email: t...@us.ibm.com
 
  [图像已删除] Ton Ngo---11/06/2014 07:04:30 PM---Hi Tao Tao,If
  you use Ubuntu image, you can check /var/log/syslog
 
  From: Ton Ngo/Watson/IBM@IBMUS
  To: OpenStack Development Mailing List \(not for usage questions\)
  openstack-dev@lists.openstack.org
  Date: 11/06/2014 07:04 PM
  Subject: Re: [openstack-dev] [heat] How to expose the error messages
  if the heat stack creation fails with software config/software
deployment
 
 
 
  Hi Tao Tao,
If you use Ubuntu image, you can check /var/log/syslog
  Look for section like:
  Running /opt/stack/os-config-refresh

Re: [openstack-dev] [ceilometer] unable to collect compute.node.cpu.* data

2014-11-05 Thread Hang H Liu
Same steps I can get below results.
You may need debug into get_meters() in
ceilometer/storage/impl_sqlalchemy.py to see if some filters are taking
effect.


localadmin@ostest2:~/devstack$ ceilometer meter-list
+-++-+--+--+--+
| Name| Type   | Unit| Resource ID
| User ID  | Project ID   |
+-++-+--+--+--+
| compute.node.cpu.frequency  | gauge  | MHz | ostest2_ostest2
| None | None |
| compute.node.cpu.idle.percent   | gauge  | %   | ostest2_ostest2
| None | None |
| compute.node.cpu.idle.time  | cumulative | ns  | ostest2_ostest2
| None | None |
| compute.node.cpu.iowait.percent | gauge  | %   | ostest2_ostest2
| None | None |
| compute.node.cpu.iowait.time| cumulative | ns  | ostest2_ostest2
| None | None |
| compute.node.cpu.kernel.percent | gauge  | %   | ostest2_ostest2
| None | None |
| compute.node.cpu.kernel.time| cumulative | ns  | ostest2_ostest2
| None | None |
| compute.node.cpu.percent| gauge  | %   | ostest2_ostest2
| None | None |
| compute.node.cpu.user.percent   | gauge  | %   | ostest2_ostest2
| None | None |
| compute.node.cpu.user.time  | cumulative | ns  | ostest2_ostest2
| None



Lu, Lianhao lianhao...@intel.com 写于 2014/11/05 15:23:14:

 From: Lu, Lianhao lianhao...@intel.com
 To: OpenStack Development Mailing List (not for usage questions)
 openstack-dev@lists.openstack.org
 Date: 2014/11/05 15:31
 Subject: Re: [openstack-dev] [ceilometer] unable to collect
 compute.node.cpu.* data

 Hi Frank,

 Could you try ‘celometer sample-list’ to see if the compute.node.cpu
 samples are there?

 -Lianhao

 From: Du Jun [mailto:dj199...@gmail.com]
 Sent: Wednesday, November 05, 2014 3:44 AM
 To: openstack-dev@lists.openstack.org
 Subject: [openstack-dev] [ceilometer] unable to collect
 compute.node.cpu.* data

 Hi all,

 I attempt to collect compute.node.cpu as the following link mentions:


http://docs.openstack.org/developer/ceilometer/measurements.html#compute-nova

 I set:

 compute_monitors = ComputeDriverCPUMonitor

 in /etc/nova/nova.conf and restart nova-compute, nova-scheduler,
 ceilometer-agent-notification, ceilometer-api, ceilometer-collector.

 From ceilometer-agent-notification's log, I can see agent transform
 and publish data samples compute.node.cpu.*

 What's more, from ceilometer database, I can see all the meters
 compute.node.cpu.*

 mysql select * from meter;
 ++-++---+
 | id | name| type   | unit  |
 ++-++---+
 | 39 | compute.node.cpu.frequency  | gauge  | MHz   |
 | 41 | compute.node.cpu.idle.percent   | gauge  | % |
 | 38 | compute.node.cpu.idle.time  | cumulative | ns|
 | 45 | compute.node.cpu.iowait.percent | gauge  | % |
 | 42 | compute.node.cpu.iowait.time| cumulative | ns|
 | 36 | compute.node.cpu.kernel.percent | gauge  | % |
 | 44 | compute.node.cpu.kernel.time| cumulative | ns|
 | 37 | compute.node.cpu.percent| gauge  | % |
 | 43 | compute.node.cpu.user.percent   | gauge  | % |
 | 40 | compute.node.cpu.user.time  | cumulative | ns|


 However, when I type

 ceilometer meter-list

 It shows nothing about compute.node.cpu.*, so I wonder what's wrong
 with my steps.

 --
 Regards,
 Frank___
 OpenStack-dev mailing list
 OpenStack-dev@lists.openstack.org
 http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev___
OpenStack-dev mailing list
OpenStack-dev@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev