Bug 736734 - unable to start vsphere deployment using aeolus
Summary: unable to start vsphere deployment using aeolus
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: CloudForms Cloud Engine
Classification: Retired
Component: aeolus-conductor
Version: 1.0.0
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: rc
Assignee: Angus Thomas
QA Contact: wes hayutin
URL: na
Whiteboard:
Depends On: 737568
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-09-08 14:52 UTC by wes hayutin
Modified: 2012-01-26 12:28 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-10-07 12:50:05 UTC


Attachments (Terms of Use)
ss (135.59 KB, image/png)
2011-09-08 14:53 UTC, wes hayutin
no flags Details

Description wes hayutin 2011-09-08 14:52:13 UTC
Description of problem:

https://issues.apache.org/jira/browse/DTACLOUD-76

dcloud returns..     

./deltacloudd[25521]: RbVmomi::Fault:InvalidRequest: Error formatting number 
    /usr/lib/ruby/gems/1.8/gems/rbvmomi-1.2.3/lib/rbvmomi/connection.rb:47:in `parse_response' 
    /usr/lib/ruby/gems/1.8/gems/rbvmomi-1.2.3/lib/rbvmomi/connection.rb:71:in `call' 
    /usr/lib/ruby/gems/1.8/gems/rbvmomi-1.2.3/lib/rbvmomi/basic_types.rb:182:in `_call' 
    /usr/lib/ruby/gems/1.8/gems/rbvmomi-1.2.3/lib/rbvmomi/basic_types.rb:70:in `CloneVM_Task' 
    ././lib/deltacloud/drivers/vsphere/vsphere_driver.rb:282:in `create_instance' 
    ././lib/deltacloud/base_driver/exceptions.rb:151:in `call' 
    ././lib/deltacloud/base_driver/exceptions.rb:151:in `safely' 
    ././lib/deltacloud/drivers/vsphere/vsphere_driver.rb:208:in `create_instance' 
    ././server.rb:442 


Recreate: 
1. setup aeolus, configured w/ vsphere support 
2. setup dcloud running from trunk and the above git hash 
3. build and push an image using conductor 
4. start a deployment using conductor

Comment 1 wes hayutin 2011-09-08 14:53:17 UTC
I think this is a aeolus bug because..

I can push using aeolus-image, and start the image using dcloud.  I think aeolus is sending the wrong arguments..

[root@unused yum.repos.d]# aeolus-image push --provider vsphere --build 59ebda31-f301-4777-b642-76aacbbb75d7 

Provider Image: b99994de-db37-4fbb-a89b-f8cd0d2c0344 
Image: 
Build: 59ebda31-f301-4777-b642-76aacbbb75d7 
Status: PUSHING 
Percent Complete: 0 


2011-09-08 10:44:34,695 DEBUG imagefactory.ImageWarehouse.ImageWarehouse pid(14043) Message: Setting metadata ({'target_image': '8977ea12-8c12-43fb-9308-f9052c2a0ecb', 'uuid': 'b99994de-db37-4fbb-a89b-f8cd0d2c0344', 'icicle': 'none', 'target_identifier': 'factory-image-b99994de-db37-4fbb-a89b-f8cd0d2c0344', 'object_type': 'provider_image', 'provider': 'vsphere'}) for http://localhost:9090/provider_images/b99994de-db37-4fbb-a89b-f8cd0d2c0344 
2011-09-08 10:44:34,704 DEBUG imagefactory.BuildJob.BuildAdaptor pid(14043) Message: Raising event with agent handler (<ImageFactoryAgent(Thread-1, initial)>), changed percent complete from 0 to 100 
2011-09-08 10:44:34,705 DEBUG imagefactory.ImageWarehouse.ImageWarehouse pid(14043) Message: Setting metadata ({'latest_build': '59ebda31-f301-4777-b642-76aacbbb75d7'}) for http://localhost:9090/images/ 
2011-09-08 10:44:34,709 DEBUG imagefactory.ImageWarehouse.ImageWarehouse pid(14043) Message: Setting metadata ({'latest_unpushed': None}) for http://localhost:9090/images/ 
2011-09-08 10:44:34,711 DEBUG imagefactory.BuildJob.BuildAdaptor pid(14043) Message: Raising event with agent handler (<ImageFactoryAgent(Thread-1, initial)>), changed status from PUSHING to COMPLETED

Comment 2 wes hayutin 2011-09-08 14:53:44 UTC
Created attachment 522140 [details]
ss

Comment 3 wes hayutin 2011-09-08 14:55:32 UTC
[root@unused yum.repos.d]# rpm -qa | grep aeolus
aeolus-conductor-0.4.0-0.20110901175002git4a3e496.fc15.noarch
aeolus-conductor-daemons-0.4.0-0.20110901175002git4a3e496.fc15.noarch
aeolus-configure-2.0.2-2.20110830113535git906f985.fc15.noarch
aeolus-conductor-doc-0.4.0-0.20110901175002git4a3e496.fc15.noarch
aeolus-all-0.4.0-0.20110901175002git4a3e496.fc15.noarch
rubygem-aeolus-image-0.1.0-3.20110824113236git15b6922.fc15.noarch

deltacloud vsphere drivers are not included in the testing repo.. so running from head in the dcloud project..


[root@unused core]# git show
commit c826b70bb9743628deec34859ec09913c05d3f9d
Author: Michal Fojtik <mfojtik@apache.org>
Date:   Thu Aug 25 13:44:15 2011 +0000

Comment 4 Jan Provaznik 2011-09-08 18:40:58 UTC
I think problem is in converting "hwp_cpu" value passed to DC API - vsphere lib fails to parse cpu value "1.0" which is passed by conductor to dc api. But passing "1.0" is correct as DC API defines CPU value as float.

this call fails (used ruby dc client lib):
client.create_instance(:name => "jp2", "hwp_memory"=>"512", "image_id"=>"factory-image-03720a69-84b2-4b48-bca7-ddd2c96feeb6", "keyname"=>"", "hwp_id"=>"default", "hwp_cpu"=>"1.0", "hwp_storage"=>"")

with:
./deltacloudd[11938]: RbVmomi::Fault:InvalidRequest: Error formatting number

this call succeeds:
c.create_instance(:name => "jp2", "hwp_memory"=>"512", "image_id"=>"factory-image-03720a69-84b2-4b48-bca7-ddd2c96feeb6", "keyname"=>"", "hwp_id"=>"default", "hwp_cpu"=>"1", "hwp_storage"=>"")

So I think DC API vsphere driver should take care about converting "1.0" value to "1". CCing Michal.

Comment 5 Jan Provaznik 2011-09-08 18:43:03 UTC
CCing also Francesco as he is vsphere guru ;).

Comment 6 wes hayutin 2011-09-08 19:34:43 UTC
[root@unused bin]# git show
commit 776e0a63a2919ef08322a1556fd84043381506e0

could not get things to work w/ this checkout

Comment 7 Michal Fojtik 2011-09-09 11:55:19 UTC
This bug should be fixed on deltacloud-core r1167120.

commit 7e6b54709335efe6ed7747dcb3188495c420ead8
Author: mfojtik <mfojtik@13f79535-47bb-0310-9956-ffa450edef68>
Date:   Fri Sep 9 11:54:22 2011 +0000

    Fixed wrong FloatProperty handling in client for CPU value in hardware profile (#736734)
    
    git-svn-id: https://svn.apache.org/repos/asf/incubator/deltacloud/trunk@1167120 13f79535-47bb-0310-9956-ffa450edef68

Patch:

diff --git a/client/lib/deltacloud.rb b/client/lib/deltacloud.rb
index ea106d2..28b1200 100644
--- a/client/lib/deltacloud.rb
+++ b/client/lib/deltacloud.rb
@@ -201,9 +201,9 @@ module DeltaCloud
         # Do a HWP property for hardware profile properties
         if attribute.name == 'property'
           if attribute['value'] =~ /^(\d+)$/
-            obj.add_hwp_property!(attribute['name'], attribute, :float) && next
-          else
             obj.add_hwp_property!(attribute['name'], attribute, :integer) && next
+          else
+            obj.add_hwp_property!(attribute['name'], attribute, :float) && next
           end
         end

Comment 8 wes hayutin 2011-09-12 00:35:54 UTC
Please... only QE moves bugs status to verified.. 

Lets track the details here..https://issues.apache.org/jira/browse/DTACLOUD-76

This bug is not fixed.. and its a high priority fix.
Thanks

Comment 9 Michal Fojtik 2011-09-12 08:13:55 UTC
wes FYI, this bug is not beeing caused by DC API but by Ruby client we're shipping with DC API. So in order to resolve this bug you need to update 'rubygem-deltacloud-client' package in your setup (preferably use my nightly build repo). The problem is caused by incorrect parsing of CPU value here (it's '1' not '1.0'). This value is passed to VSphere which cause 'Error formatting number' since VSPhere is expecting interger here, not float.

Comment 10 wes hayutin 2011-09-12 16:39:20 UTC
k.. this is on_qa but depends on https://bugzilla.redhat.com/show_bug.cgi?id=737568

Comment 11 wes hayutin 2011-09-20 14:00:40 UTC
Aziza please verify these bugs.. Thank you!

Comment 12 wes hayutin 2011-09-28 14:48:50 UTC
woot woot!
Instances
vmwareTools01/frontend
IP Address: 10.10.77.142
State: running


[root@unused ~]# rpm -qa | grep aeolus
aeolus-conductor-0.4.0-0.20110926211730git1cc372b.fc15.noarch
aeolus-conductor-daemons-0.4.0-0.20110926211730git1cc372b.fc15.noarch
aeolus-all-0.4.0-0.20110926211730git1cc372b.fc15.noarch
aeolus-conductor-doc-0.4.0-0.20110926211730git1cc372b.fc15.noarch
aeolus-conductor-devel-0.4.0-0.20110926211730git1cc372b.fc15.noarch
rubygem-aeolus-image-0.1.0-3.20110919115936gitd1d24b4.fc15.noarch
aeolus-configure-2.0.2-4.20110926142838git5044e56.fc15.noarch
[root@unused ~]#


Note You need to log in before you can comment on or make changes to this bug.