deltacloud-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michal Fojtik (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DTACLOUD-328) Instance state is not updated properly when stopping an openstack instance
Date Tue, 25 Sep 2012 14:12:08 GMT

    [ https://issues.apache.org/jira/browse/DTACLOUD-328?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13462758#comment-13462758
] 

Michal Fojtik commented on DTACLOUD-328:
----------------------------------------

Hi, I spent some time testing this and I think this is a OpenStack bug. I recorded communication
after 'stop' call:


127.0.0.1 - - [25/Sep/2012 16:09:37] "POST /api/instances/28caf43f-96b2-4ba5-bf3e-17e745500fcd/stop
HTTP/1.1" 202 1356 0.5069

[#<Instance:0x007fcf5352e098 @id="28caf43f-96b2-4ba5-bf3e-17e745500fcd", @image_id="41d25563-7d09-45eb-8717-f6fe01dff66f",
@actions=[:reboot, :stop], @public_addresses=[], @private_addresses=[192.168.0.2], @realm_id="default",
@owner_id="mfojtik", @name="test-repro", @state="RUNNING", @instance_profile=1, @username="root",
@password="", @keyname="", @create_image=true>]
127.0.0.1 - - [25/Sep/2012 16:09:38] "GET /api/instances/28caf43f-96b2-4ba5-bf3e-17e745500fcd
HTTP/1.1" 200 1356 0.2876

As you can see OpenStack return state as 'RUNNING', even that this machine was deleted and
stopped. I think this has something to do with caching or processing query in OpenStack internally.
                
> Instance state is not updated properly when stopping an openstack instance
> --------------------------------------------------------------------------
>
>                 Key: DTACLOUD-328
>                 URL: https://issues.apache.org/jira/browse/DTACLOUD-328
>             Project: DeltaCloud
>          Issue Type: Bug
>         Environment: deltacloud from git repo (last commit 4d019838dec68c4ce50e1311129932cebf185577)
> + applied manually marios's patch: http://tracker.deltacloud.org/patch/957a640e#diff
> rubygem-deltacloud-client-0.5.0-3.fc17.noarch
>            Reporter: Jan Provaznik
>            Assignee: Michal Fojtik
>
> when I try to stop running openstack instance, instance's state should be set to 'stopped'
after successful call, but the state is not updated at all:
> irb(main):004:0> i.send('stop!')
> => [{:method_name=>"stopped?", :type=>:state, :state=>"STOPPED"}, {:method_name=>"running?",
:type=>:state, :state=>"RUNNING"}, {:method_name=>"pending?", :type=>:state, :state=>"PENDING"},
{:method_name=>"shutting_down?", :type=>:state, :state=>"SHUTTING_DOWN"}, {:type=>:text,
:method_name=>"name", :value=>"os1-6-openstack-import"}, {:type=>:text, :method_name=>"owner_id",
:value=>"jprovazn"}, {:type=>:link, :method_name=>"image", :id=>"1dc5da85-81f3-4077-abc8-f6e9bed9f3f6"},
{:type=>:text, :method_name=>"image_id", :value=>"1dc5da85-81f3-4077-abc8-f6e9bed9f3f6"},
{:type=>:link, :method_name=>"realm", :id=>"default"}, {:type=>:text, :method_name=>"realm_id",
:value=>"default"}, {:type=>:text, :method_name=>"state", :value=>"RUNNING"},
{:type=>:link, :method_name=>"hardware_profile", :id=>"2"}, {:type=>:text, :method_name=>"hardware_profile_id",
:value=>"2"}, {:type=>:collection, :method_name=>"public_addresses", :values=>[]},
{:type=>:collection, :method_name=>"private_addresses", :values=>[{:address=>"192.168.0.5",
:type=>"ipv4"}, {:address=>"10.34.59.4", :type=>"ipv4"}]}, {:type=>:text, :method_name=>"storage_volumes",
:value=>""}, {:type=>:collection, :method_name=>"authentication", :values=>{:key=>"os1-6_openstack-import_1348570306_key_59713380"}},
{:type=>:action_link, :method_name=>"reboot!", :id=>"00cd5dfd-6788-4fd5-94a1-d83462445c18",
:href=>"http://localhost:3002/api/instances/00cd5dfd-6788-4fd5-94a1-d83462445c18/reboot",
:rel=>"reboot", :method=>"post"}, {:type=>:action_link, :method_name=>"stop!",
:id=>"00cd5dfd-6788-4fd5-94a1-d83462445c18", :href=>"http://localhost:3002/api/instances/00cd5dfd-6788-4fd5-94a1-d83462445c18/stop",
:rel=>"stop", :method=>"post"}, {:type=>:action_link, :method_name=>"create_image!",
:id=>"00cd5dfd-6788-4fd5-94a1-d83462445c18", :href=>"http://localhost:3002/api/create_image;instance_id=00cd5dfd-6788-4fd5-94a1-d83462445c18",
:rel=>"create_image", :method=>"post"}]
> irb(main):005:0> i.state
> => "RUNNING"

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message