[Openstack] Instance stuck in deleting state with error

Lorin Hochstein lorin at nimbisservices.com
Wed Aug 1 19:40:59 UTC 2012


On Jul 30, 2012, at 3:35 PM, Kevin L. Mitchell <kevin.mitchell at rackspace.com> wrote:

> On Mon, 2012-07-30 at 14:25 -0500, Chris Behrens wrote:
>> You may still have to reset the instance's task_state to NULL in the
>> DB (instances table) to delete ones already in this state.
> 
> No, I fixed the state problem with soft_delete(); as long as he updates,
> delete should work fine.
> 
> That said, be aware that there is a "reset-state" command to novaclient,
> so that you can do Chris's recommended reset without having to muck
> around with the database directly.
> -- 
> Kevin L. Mitchell <kevin.mitchell at rackspace.com>



From the python-novaclient tests, it looks like  "nova reset-state <instance>" puts an instance into the error state or (with the --active) flag into the active state:

    def test_reset_state(self):
        self.run_command('reset-state sample-server')
        self.assert_called('POST', '/servers/1234/action',
                           {'os-resetState': {'state': 'error'}})
        self.run_command('reset-state sample-server --active')
        self.assert_called('POST', '/servers/1234/action',
                           {'os-resetState': {'state': 'active'}})


What's the use case for resetting an instance to the error state? Is the idea to do:

nova reset-state <instance>
nova delete <instance>



Take care,

Lorin
--
Lorin Hochstein
Lead Architect - Cloud Services
Nimbis Services, Inc.
www.nimbisservices.com





-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20120801/3a937ee6/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4897 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20120801/3a937ee6/attachment.bin>


More information about the Openstack mailing list