heat resource-show failed

Bug #1696396 reported by yong sheng gong
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Heat
Expired
Medium
Unassigned

Bug Description

the &2F should be / at curl -g -i -X GET http://192.168.112.13/heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-27e52de0-fc03-49b9-b6d6-12d32c02c348%2F5f3995be-49f5-41c1-bd29-d2bfee411b03/resources/CP1

the whole call stack is following with heat resource-show stackid cp1:

DEBUG (session) GET call to orchestration for http://192.168.112.13/heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/5f3995be-49f5-41c1-bd29-d2bfee411b03 used request id req-618d2a36-488b-42cd-908a-9d5e8f589b71
DEBUG (session) REQ: curl -g -i -X GET http://192.168.112.13/heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-27e52de0-fc03-49b9-b6d6-12d32c02c348%2F5f3995be-49f5-41c1-bd29-d2bfee411b03/resources/CP1 -H "User-Agent: python-heatclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}ceadc1e8267c29647762e175b03478c3622ccf55"
DEBUG (session) RESP: [404] Date: Wed, 07 Jun 2017 10:53:29 GMT Server: Apache/2.4.18 (Ubuntu) Content-Length: 473 Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Content-Type: text/html; charset=iso-8859-1
RESP BODY: Omitted, Content-Type is set to text/html; charset=iso-8859-1. Only application/json responses have their bodies logged.

Traceback (most recent call last):
  File "/usr/local/bin/heat", line 11, in <module>
    sys.exit(main())
  File "/usr/local/lib/python2.7/dist-packages/heatclient/shell.py", line 607, in main
    HeatShell().main(args)
  File "/usr/local/lib/python2.7/dist-packages/heatclient/shell.py", line 557, in main
    args.func(client, args)
  File "/usr/local/lib/python2.7/dist-packages/heatclient/v1/shell.py", line 999, in do_resource_show
    {'id': args.id, 'resource': args.resource})
heatclient.exc.CommandError: Stack or resource not found: 5f3995be-49f5-41c1-bd29-d2bfee411b03 CP1

with openstack stack resource show stack cp1:

GET call to orchestration for http://192.168.112.13/heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/5f3995be-49f5-41c1-bd29-d2bfee411b03 used request id req-b2f96160-9b4a-4aff-ac42-758c8e86dfab
REQ: curl -g -i -X GET http://192.168.112.13/heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-27e52de0-fc03-49b9-b6d6-12d32c02c348%2F5f3995be-49f5-41c1-bd29-d2bfee411b03/resources/CP1 -H "User-Agent: python-heatclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}4b1aaf583a2ce0d0fbd829996f56c25ebb5643fe"
Resetting dropped connection: 192.168.112.13
http://192.168.112.13:80 "GET /heat-api/v1/d2125ab239a44ed5bd7b018d6c846ecd/stacks/tacker.vnfm.infra_drivers.openstack.openstack_OpenStack-27e52de0-fc03-49b9-b6d6-12d32c02c348%2F5f3995be-49f5-41c1-bd29-d2bfee411b03/resources/CP1 HTTP/1.1" 404 473
RESP: [404] Date: Wed, 07 Jun 2017 10:49:57 GMT Server: Apache/2.4.18 (Ubuntu) Content-Length: 473 Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Content-Type: text/html; charset=iso-8859-1
RESP BODY: Omitted, Content-Type is set to text/html; charset=iso-8859-1. Only application/json responses have their bodies logged.

Stack or resource not found: 5f3995be-49f5-41c1-bd29-d2bfee411b03 CP1
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/cliff/app.py", line 400, in run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/osc_lib/command/command.py", line 41, in run
    return super(Command, self).run(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/cliff/display.py", line 112, in run
    column_names, data = self.take_action(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/heatclient/osc/v1/resource.py", line 69, in take_action
    raise exc.CommandError(msg)
CommandError: Stack or resource not found: 5f3995be-49f5-41c1-bd29-d2bfee411b03 CP1
clean_up ResourceShow: Stack or resource not found: 5f3995be-49f5-41c1-bd29-d2bfee411b03 CP1
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/osc_lib/shell.py", line 135, in run
    ret_val = super(OpenStackShell, self).run(argv)
  File "/usr/local/lib/python2.7/dist-packages/cliff/app.py", line 279, in run
    result = self.run_subcommand(remainder)
  File "/usr/local/lib/python2.7/dist-packages/osc_lib/shell.py", line 180, in run_subcommand
    ret_value = super(OpenStackShell, self).run_subcommand(argv)
  File "/usr/local/lib/python2.7/dist-packages/cliff/app.py", line 400, in run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/osc_lib/command/command.py", line 41, in run
    return super(Command, self).run(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/cliff/display.py", line 112, in run
    column_names, data = self.take_action(parsed_args)
  File "/usr/local/lib/python2.7/dist-packages/heatclient/osc/v1/resource.py", line 69, in take_action
    raise exc.CommandError(msg)
CommandError: Stack or resource not found: 5f3995be-49f5-41c1-bd29-d2bfee411b03 CP1

Revision history for this message
Thomas Herve (therve) wrote :
Changed in heat:
milestone: none → pike-2
importance: Undecided → High
Revision history for this message
Rico Lin (rico-lin) wrote :

@yong sheng gong could you please confirm is this issue fixed by https://review.openstack.org/#/c/471730/ thx!

Changed in heat:
milestone: pike-2 → pike-3
Rico Lin (rico-lin)
Changed in heat:
status: New → Incomplete
importance: High → Medium
milestone: pike-3 → none
Revision history for this message
Rabi Mishra (rabi) wrote :

To elaborate a little about the issue, this was because we changed devstack heat to use uwsgi
by default from pike onwards in https://review.openstack.org/#/c/462216

That change was reverted by https://review.openstack.org/#/c/471730/

However, we would push that change again with https://review.openstack.org/#/c/478345/

The above issue could have been resolved by:

1. Using heatclient >= 1.10.0
2. Adding 'AlllowEncodedSlashes On' in apache config for compatibility with old heatclients.

Note: This would only be case with fresh devstack that uses apache+uwsgi by default.

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for OpenStack Heat because there has been no activity for 60 days.]

Changed in heat:
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.