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

Raja Pullela commented on CLOUDSTACK-8924:
------------------------------------------

[~miguel.cd.ferreira] yes, you are right.  

I feel that "test_02_scale_vm_without_hypervisor_specifics" looks duplicate to 
"test_01_scale_vm".  
Just modify the "test_01_scale_vm"  attributes/tags - "required_hardware=true"  
to "false" and delete the "test_02_scale_vm_without_hypervisor_specifics".   

> [Blocker] test duplicated in test_scale_vm.py
> ---------------------------------------------
>
>                 Key: CLOUDSTACK-8924
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-8924
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the 
> default.) 
>    Affects Versions: 4.6.0
>            Reporter: Raja Pullela
>            Priority: Blocker
>             Fix For: 4.6.0
>
>
> This is a blocker because BVTs for XS and Simulator are failing.
> Simulator zone - it is failing because
> This is a genuine failure - because the setup didn't have Dynamic Scaling 
> enabled as part of global settings.  Once it is enabled the tests ran fine.
> XS basic/Advzone - it is failing because
> the methods 
> test_01_scale_vm(self):
> test_02_scale_vm_without_hypervisor_specifics(self):
> are essentially same with the exception of tags -
> first one - test_01_scale_vm - had a "required_hardware=true"
> second - test_02_scale_vm_without_hypervisor_specific had a 
> "required_hardware=false"
> essentially we can get this test run on both Simulator and XenServer by 
> modifying the "required_hardware=false". 
> and test_02_scale_vm_without_hypervisor_specifc - can be deleted.
> The reason for failure on the XS is due to the following - "Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering"
> Following are the logs:
> Test scale virtual machine ... === TestName: test_01_scale_vm | Status : 
> SUCCESS ===
> ok
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm) ... === TestName: 
> test_02_scale_vm_without_hypervisor_specifics | Status : EXCEPTION ===
> ERROR
> ======================================================================
> ERROR: test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File "/root/cloudstack/test/integration/smoke/test_scale_vm.py", line 234, 
> in test_02_scale_vm_without_hypervisor_specifics
>     self.apiclient.scaleVirtualMachine(cmd)
>   File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackAPI/cloudstackAPIClient.py",
>  line 797, in scaleVirtualMachine
>     response = self.connection.marvinRequest(command, response_type=response, 
> method=method)
>   File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackConnection.py", line 
> 379, in marvinRequest
>     raise e
> Exception: Job failed: {jobprocstatus : 0, created : 
> u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}
> -------------------- >> begin captured stdout << ---------------------
> === TestName: test_02_scale_vm_without_hypervisor_specifics | Status : 
> EXCEPTION ===
> --------------------- >> end captured stdout << ----------------------
> -------------------- >> begin captured logging << --------------------
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: ::::::::::::STARTED : 
> TC: test_02_scale_vm_without_hypervisor_specifics :::::::::::
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Payload: 
> {'isdynamicallyscalable': 'true', 'apiKey': 
> u'FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w',
>  'response': 'json', 'command': 'updateVirtualMachine', 'signature': 
> '4dANF6uDGtaOk6jIDb901ES+Oq8=', 'id': u'38c1ced0-693f-4e31-b976-9f4161ac57bb'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: ========Sending GET Cmd 
> : updateVirtualMachine=======
> urllib3.connectionpool: INFO: Starting new HTTP connection (1): 10.220.135.73
> urllib3.connectionpool: DEBUG: "GET 
> /client/api?isdynamicallyscalable=true&apiKey=FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w&response=json&command=updateVirtualMachine&signature=4dANF6uDGtaOk6jIDb901ES%2BOq8%3D&id=38c1ced0-693f-4e31-b976-9f4161ac57bb
>  HTTP/1.1" 200 1703
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Response : {domain : 
> u'ROOT', domainid : u'a6d8fc3a-670a-11e5-8245-96e5a2a4ae9a', haenable : 
> False, templatename : u'CentOS 5.6(64-bit) no GUI (XenServer)', securitygroup 
> : [{egressrule : [], account : u'test-a-TestScaleVm-D0XS7G', name : 
> u'basic_sec_grp-9HYGF7', virtualmachineids : [], tags : [], ingressrule : [], 
> id : u'544c2c1e-5487-4ed2-8a5a-716477c915c8'}], zoneid : 
> u'ca2f3c87-c0ed-44c5-99ad-911287e8ef1d', cpunumber : 1, ostypeid : 142, 
> passwordenabled : False, instancename : u'i-23-28-VM', id : 
> u'38c1ced0-693f-4e31-b976-9f4161ac57bb', hostname : u'bear', displayvm : 
> True, state : u'Running', guestosid : 
> u'a6ecb7ca-670a-11e5-8245-96e5a2a4ae9a', cpuspeed : 100, serviceofferingid : 
> u'5bd4c9d3-9ebb-4cae-8b2f-af434b951b40', zonename : u'XenRT-Zone-0', username 
> : u'test-a-TestScaleVm-D0XS7G', isdynamicallyscalable : True, displayname : 
> u'testserver', tags : [], nic : [{networkid : 
> u'0b0d6645-db6c-43e4-a37d-3e538eec313b', macaddress : u'06:b3:ca:00:00:18', 
> type : u'Shared', broadcasturi : u'vlan://untagged', traffictype : u'Guest', 
> netmask : u'255.255.224.0', ipaddress : u'10.219.197.191', id : 
> u'09105737-3ba0-4010-a854-93c8e2ceaf65', secondaryip : [], networkname : 
> u'guestNetworkForBasicZone', gateway : u'10.219.192.1', isdefault : True}], 
> memory : 512, templateid : u'a6dd7c74-670a-11e5-8245-96e5a2a4ae9a', 
> affinitygroup : [], account : u'test-a-TestScaleVm-D0XS7G', hostid : 
> u'a7876350-8351-4573-8f7e-dd13be87b0e0', name : 
> u'VM-38c1ced0-693f-4e31-b976-9f4161ac57bb', created : 
> u'2015-09-30T01:16:29+0000', hypervisor : u'XenServer', userid : 
> u'30234acc-9495-4b95-8d7b-74257fb6f0fa', rootdevicetype : u'ROOT', 
> rootdeviceid : 0, serviceofferingname : u'BigInstance', templatedisplaytext : 
> u'CentOS 5.6(64-bit) no GUI (XenServer)'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Scaling VM-ID: 
> 38c1ced0-693f-4e31-b976-9f4161ac57bb to service offering: 
> 5bd4c9d3-9ebb-4cae-8b2f-af434b951b40 and state Running
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Payload: {'apiKey': 
> u'FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w',
>  'response': 'json', 'command': 'scaleVirtualMachine', 'signature': 
> 'gWVLy4f9yEbyFlw1RdqZ42IPHV0=', 'id': 
> u'38c1ced0-693f-4e31-b976-9f4161ac57bb', 'serviceofferingid': 
> u'5bd4c9d3-9ebb-4cae-8b2f-af434b951b40'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: ========Sending GET Cmd 
> : scaleVirtualMachine=======
> urllib3.connectionpool: INFO: Starting new HTTP connection (1): 10.220.135.73
> urllib3.connectionpool: DEBUG: "GET 
> /client/api?apiKey=FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w&serviceofferingid=5bd4c9d3-9ebb-4cae-8b2f-af434b951b40&command=scaleVirtualMachine&signature=gWVLy4f9yEbyFlw1RdqZ42IPHV0%3D&response=json&id=38c1ced0-693f-4e31-b976-9f4161ac57bb
>  HTTP/1.1" 200 80
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: === Jobid: 
> ad32dee5-da3c-42c3-bdc3-35928b47697f Started ===
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Payload: {'signature': 
> 'o8y/6mVqO/C5dgJ5wuVYavnCJhU=', 'apiKey': 
> u'FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w',
>  'command': 'queryAsyncJobResult', 'response': 'json', 'jobid': 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: ========Sending GET Cmd 
> : queryAsyncJobResult=======
> urllib3.connectionpool: INFO: Starting new HTTP connection (1): 10.220.135.73
> urllib3.connectionpool: DEBUG: "GET 
> /client/api?jobid=ad32dee5-da3c-42c3-bdc3-35928b47697f&apiKey=FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w&command=queryAsyncJobResult&response=json&signature=o8y%2F6mVqO%2FC5dgJ5wuVYavnCJhU%3D
>  HTTP/1.1" 200 335
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Response : 
> {jobprocstatus : 0, created : u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 0, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 0, accountid : 
> u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: === 
> JobId:ad32dee5-da3c-42c3-bdc3-35928b47697f is Still Processing, Will TimeOut 
> in:3595 ====
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Payload: {'signature': 
> 'o8y/6mVqO/C5dgJ5wuVYavnCJhU=', 'apiKey': 
> u'FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w',
>  'command': 'queryAsyncJobResult', 'response': 'json', 'jobid': 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: ========Sending GET Cmd 
> : queryAsyncJobResult=======
> urllib3.connectionpool: INFO: Starting new HTTP connection (1): 10.220.135.73
> urllib3.connectionpool: DEBUG: "GET 
> /client/api?jobid=ad32dee5-da3c-42c3-bdc3-35928b47697f&apiKey=FI3p7aHiRMfWK_oV_T9_i8uY-YegVuIR3mvV7pS3w7s_2-krRV-GMGXoBoVm0454fiZt6FgwOH86gEPenLox0w&command=queryAsyncJobResult&response=json&signature=o8y%2F6mVqO%2FC5dgJ5wuVYavnCJhU%3D
>  HTTP/1.1" 200 509
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Response : 
> {jobprocstatus : 0, created : u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): ERROR: ==== __poll: Exception 
> Occurred :Job failed: {jobprocstatus : 0, created : 
> u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'} ====
> Traceback (most recent call last):
>   File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackConnection.py", line 
> 105, in __poll
>     % async_response)
> Exception: Job failed: {jobprocstatus : 0, created : 
> u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): DEBUG: Response : FAILED
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): ERROR: marvinRequest : 
> CmdName: <marvin.cloudstackAPI.scaleVirtualMachine.scaleVirtualMachineCmd 
> object at 0x7fbb8b431f50> Exception: ['Traceback (most recent call last):\n', 
> '  File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackConnection.py", line 
> 374, in marvinRequest\n    raise self.__lastError\n', "Exception: Job failed: 
> {jobprocstatus : 0, created : u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}\n"]
> Traceback (most recent call last):
>   File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackConnection.py", line 
> 374, in marvinRequest
>     raise self.__lastError
> Exception: Job failed: {jobprocstatus : 0, created : 
> u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}
> test_02_scale_vm_without_hypervisor_specifics 
> (integration.smoke.test_scale_vm.TestScaleVm): CRITICAL: EXCEPTION: 
> test_02_scale_vm_without_hypervisor_specifics: ['Traceback (most recent call 
> last):\n', '  File "/usr/lib/python2.7/unittest/case.py", line 329, in run\n  
>   testMethod()\n', '  File 
> "/root/cloudstack/test/integration/smoke/test_scale_vm.py", line 234, in 
> test_02_scale_vm_without_hypervisor_specifics\n    
> self.apiclient.scaleVirtualMachine(cmd)\n', '  File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackAPI/cloudstackAPIClient.py",
>  line 797, in scaleVirtualMachine\n    response = 
> self.connection.marvinRequest(command, response_type=response, 
> method=method)\n', '  File 
> "/usr/local/lib/python2.7/dist-packages/marvin/cloudstackConnection.py", line 
> 379, in marvinRequest\n    raise e\n', "Exception: Job failed: {jobprocstatus 
> : 0, created : u'2015-09-30T01:16:45+0000', cmd : 
> u'org.apache.cloudstack.api.command.admin.vm.ScaleVMCmdByAdmin', userid : 
> u'd46c0476-670a-11e5-8245-96e5a2a4ae9a', jobstatus : 2, jobid : 
> u'ad32dee5-da3c-42c3-bdc3-35928b47697f', jobresultcode : 530, jobresulttype : 
> u'object', jobresult : {errorcode : 431, errortext : u'Not upgrading vm 
> VM[User|i-23-28-VM] since it already has the requested service offering 
> (BigInstance)'}, accountid : u'd46bf47c-670a-11e5-8245-96e5a2a4ae9a'}\n"]
> --------------------- >> end captured logging << ---------------------
> ----------------------------------------------------------------------
> XML: /root/marvinko64sWgn/results.xml
> ----------------------------------------------------------------------
> Ran 2 tests in 33.462s
> FAILED (errors=1)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to