Zun

500 error when delete an Running container

Bug #1614384 reported by Eli Qiao
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Zun
Fix Released
Undecided
bharaththiruveedula

Bug Description

ubuntu@ubuntu16:~/devstack$ zun container-delete test
Delete for container test failed: Internal Server Error (HTTP 500)

 ("You cannot remove a running container 2431e888e763502da576eeff35c3954c7d2d4e7a268b0d5e219b665c4237c73e. Stop the container before attempting removal or use -f") to caller
2016-08-18 06:30:44.977 ERROR oslo_messaging._drivers.common [req-13dd36ef-1952-48d1-b466-964aba560019 None None] ['Traceback (most recent call last):\n', ' File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 138, in _dispatch_and_reply\n incoming.message))\n', ' File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 185, in _dispatch\n return self._do_dispatch(endpoint, method, ctxt, args)\n', ' File "/usr/local/lib/python2.7/dist-packages/oslo_messaging/rpc/dispatcher.py", line 127, in _do_dispatch\n result = func(ctxt, **new_args)\n', ' File "/opt/stack/higgins/zun/compute/manager.py", line 75, in container_delete\n raise e\n', 'ZunException: Unexpected Error: 409 Client Error: Conflict ("You cannot remove a running container 2431e888e763502da576eeff35c3954c7d2d4e7a268b0d5e219b665c4237c73e. Stop the container before attempting removal or use -f")\n']

There are 2 ways to fix it:

1. raise 409 when in zun-api
2. stop it in zun-compute then delete it.

I prefer 1 for now.

Eli Qiao (taget-9)
Changed in zun:
status: New → Confirmed
Changed in zun:
assignee: nobody → bharaththiruveedula (bharath-ves)
Revision history for this message
bharaththiruveedula (bharath-ves) wrote :

I have pushed the commit for this bug at https://review.openstack.org/#/c/359376/

Changed in zun:
status: Confirmed → In Progress
Changed in zun:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to zun (master)

Fix proposed to branch: master
Review: https://review.openstack.org/371822

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to zun (master)

Reviewed: https://review.openstack.org/371822
Committed: https://git.openstack.org/cgit/openstack/zun/commit/?id=33f139bd5fae929fcf713ac46e025181586370fd
Submitter: Jenkins
Branch: master

commit 33f139bd5fae929fcf713ac46e025181586370fd
Author: Hongbin Lu <email address hidden>
Date: Fri Sep 16 16:47:56 2016 -0500

    Fix an issue on deleting running container

    This issue was fixed in before, but it is re-introduced. It was
    caused by an incorrect check on "force" (need to handle the case
    when "force" is "false").

    Change-Id: Iaa4da11a16ee0853256b7e81d4488661761c5930
    Closes-Bug: #1614384

Changed in zun:
status: Fix Committed → Fix Released
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.