Return-Path: X-Original-To: apmail-cloudstack-issues-archive@www.apache.org Delivered-To: apmail-cloudstack-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8850811252 for ; Tue, 16 Sep 2014 06:58:35 +0000 (UTC) Received: (qmail 43696 invoked by uid 500); 16 Sep 2014 06:58:35 -0000 Delivered-To: apmail-cloudstack-issues-archive@cloudstack.apache.org Received: (qmail 43666 invoked by uid 500); 16 Sep 2014 06:58:35 -0000 Mailing-List: contact issues-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list issues@cloudstack.apache.org Received: (qmail 43656 invoked by uid 500); 16 Sep 2014 06:58:35 -0000 Delivered-To: apmail-incubator-cloudstack-issues@incubator.apache.org Received: (qmail 43653 invoked by uid 99); 16 Sep 2014 06:58:35 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 16 Sep 2014 06:58:35 +0000 Date: Tue, 16 Sep 2014 06:58:35 +0000 (UTC) From: "Gaurav Aradhye (JIRA)" To: cloudstack-issues@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (CLOUDSTACK-7391) [Automation] Fix the script "test_host_high_availability.py" - Error Message: "suitablehost should not be None" MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CLOUDSTACK-7391?page=3Dcom.atl= assian.jira.plugin.system.issuetabpanels:all-tabpanel ] Gaurav Aradhye resolved CLOUDSTACK-7391. ---------------------------------------- Resolution: Fixed > [Automation] Fix the script "test_host_high_availability.py" - Error Mess= age: "suitablehost should not be None" > -------------------------------------------------------------------------= -------------------------------------- > > Key: CLOUDSTACK-7391 > URL: https://issues.apache.org/jira/browse/CLOUDSTACK-739= 1 > Project: CloudStack > Issue Type: Test > Security Level: Public(Anyone can view this level - this is the defa= ult.)=20 > Components: Automation, Test > Affects Versions: 4.5.0 > Reporter: Chandan Purushothama > Assignee: Gaurav Aradhye > Fix For: 4.5.0 > > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > Client Code: > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > def test_03_cant_migrate_vm_to_host_with_ha_positive(self): > """ Verify you can not migrate VMs to hosts with an ha.tag (posit= ive) """ > . > . > . > vm =3D vms[0] > self.debug("Deployed VM on host: %s" % vm.hostid) > #Find out a Suitable host for VM migration > list_hosts_response =3D list_hosts( > self.apiclient, *BUG: Query the list of hosts with vm id. On= ly then the response will have list of suitable and non-suitable hosts. Els= e "suitableforMigration" is not returned in the response* > ) > self.assertEqual( > isinstance(list_hosts_response, list), > True, > "The listHosts API returned the invalid list" > ) > self.assertNotEqual( > len(list_hosts_response), > 0, > "The listHosts returned nothing." > ) > suitableHost =3D None > for host in list_hosts_response: > if host.suitableformigration =3D=3D True and host.hostid !=3D= vm.hostid: > suitableHost =3D host > break > self.assertTrue(suitableHost is not None, "suitablehost should no= t be None") > *Error Message: "suitablehost should not be None"* > {code} > Cmd : listHosts=3D=3D=3D=3D=3D=3D=3D > requests.packages.urllib3.connectionpool: INFO: Starting new HTTP connect= ion (1): 10.220.135.39 > requests.packages.urllib3.connectionpool: DEBUG: "GET /client/api?apiKey= =3DNpffyWZkfwK7gPcNpx28Ohv6K56ftl57A409SyokqHjJ2ZNe3AvvF3F0teTETeIIqrtlcWpQ= OooM3cQyPveGXw&command=3DlistHosts&response=3Djson&signature=3Dgh2gh3mSzQNA= cfMdspqc9v1JE3U%3D HTTP/1.1" 200 3708 > test_03_cant_migrate_vm_to_host_with_ha_positive (integration.component.m= aint.test_host_high_availability.TestHostHighAvailability): DEBUG: Response= : [{name : u's-2-VM', created : u'2014-08-20T04:31:37+0000', ipaddress : u= '10.220.136.107', islocalstorageactive : False, podid : u'027c1e45-5867-40f= 8-8ad9-685b5eb63dd2', resourcestate : u'Enabled', zoneid : u'f2acfe0c-c8c8-= 4353-8f97-a3e0f14d6357', state : u'Up', version : u'4.5.0-SNAPSHOT', manage= mentserverid : 231707544610094, podname : u'XenRT-Zone-0-Pod-0', id : u'bb0= 04159-d510-42b4-bfd5-878140a11f78', lastpinged : u'1970-01-16T22:04:57+0000= ', type : u'SecondaryStorageVM', events : u'AgentDisconnected; PingTimeout;= Remove; ShutdownRequested; AgentConnected; HostDown; ManagementServerDown;= Ping; StartAgentRebalance', zonename : u'XenRT-Zone-0'}, {name : u'v-1-VM'= , created : u'2014-08-20T04:31:37+0000', ipaddress : u'10.220.136.105', isl= ocalstorageactive : False, podid : u'027c1e45-5867-40f8-8ad9-685b5eb63dd2',= resourcestate : u'Enabled', zoneid : u'f2acfe0c-c8c8-4353-8f97-a3e0f14d635= 7', state : u'Up', version : u'4.5.0-SNAPSHOT', managementserverid : 231707= 544610094, podname : u'XenRT-Zone-0-Pod-0', id : u'f328a0d1-f4cb-4486-9550-= dd46c403c3ed', lastpinged : u'1970-01-16T22:04:57+0000', type : u'ConsolePr= oxy', events : u'AgentDisconnected; PingTimeout; Remove; ShutdownRequested;= AgentConnected; HostDown; ManagementServerDown; Ping; StartAgentRebalance'= , zonename : u'XenRT-Zone-0'}, {cpuwithoverprovisioning : u'28800.0', versi= on : u'4.5.0-SNAPSHOT', memorytotal : 31073792896, zoneid : u'f2acfe0c-c8c8= -4353-8f97-a3e0f14d6357', cpunumber : 12, managementserverid : 231707544610= 094, cpuallocated : u'2.08%', memoryused : 4211653, id : u'1f5f180e-3eb1-4a= 6a-92f8-8df71df57962', cpuused : u'0.03%', hypervisorversion : u'6.2.0', cl= usterid : u'af55ad36-15c8-424b-916b-db1550aae5ff', capabilities : u'xen-3.0= -x86_64 , xen-3.0-x86_32p , hvm-3.0-x86_32 , hvm-3.0-x86_32p , hvm-3.0-x86_= 64', state : u'Up', memoryallocated : 268435456, networkkbswrite : 5383, cp= uspeed : 2400, cpusockets : 2, type : u'Routing', events : u'AgentDisconnec= ted; PingTimeout; Remove; ShutdownRequested; AgentConnected; HostDown; Mana= gementServerDown; Ping; StartAgentRebalance', zonename : u'XenRT-Zone-0', p= odid : u'027c1e45-5867-40f8-8ad9-685b5eb63dd2', clustertype : u'CloudManage= d', hahost : False, lastpinged : u'1970-01-16T22:04:56+0000', ipaddress : u= '10.220.131.132', disconnected : u'2014-08-20T04:27:31+0000', name : u'cl08= -15', networkkbsread : 2563, created : u'2014-08-20T04:25:28+0000', cluster= name : u'XenRT-Zone-0-Pod-0-Cluster-0', hypervisor : u'XenServer', islocals= torageactive : False, resourcestate : u'Enabled', hosttags : u'host2', podn= ame : u'XenRT-Zone-0-Pod-0'}, {cpuwithoverprovisioning : u'28800.0', versio= n : u'4.5.0-SNAPSHOT', memorytotal : 31073784960, zoneid : u'f2acfe0c-c8c8-= 4353-8f97-a3e0f14d6357', cpunumber : 12, managementserverid : 2317075446100= 94, cpuallocated : u'19.79%', memoryused : 4332244, id : u'9746bc8b-efb7-46= e1-93ac-70fb571776f4', cpuused : u'0.03%', hypervisorversion : u'6.2.0', cl= usterid : u'af55ad36-15c8-424b-916b-db1550aae5ff', capabilities : u'xen-3.0= -x86_64 , xen-3.0-x86_32p , hvm-3.0-x86_32 , hvm-3.0-x86_32p , hvm-3.0-x86_= 64', state : u'Up', memoryallocated : 3221225472, networkkbswrite : 5562, c= puspeed : 2400, cpusockets : 2, type : u'Routing', events : u'AgentDisconne= cted; PingTimeout; Remove; ShutdownRequested; AgentConnected; HostDown; Man= agementServerDown; Ping; StartAgentRebalance', zonename : u'XenRT-Zone-0', = podid : u'027c1e45-5867-40f8-8ad9-685b5eb63dd2', clustertype : u'CloudManag= ed', hahost : False, lastpinged : u'1970-01-16T22:04:56+0000', ipaddress : = u'10.220.131.133', disconnected : u'2014-08-20T04:27:31+0000', name : u'cl0= 8-16', networkkbsread : 8995, created : u'2014-08-20T04:25:11+0000', cluste= rname : u'XenRT-Zone-0-Pod-0-Cluster-0', hypervisor : u'XenServer', islocal= storageactive : False, resourcestate : u'Enabled', podname : u'XenRT-Zone-0= -Pod-0'}] > test_03_cant_migrate_vm_to_host_with_ha_positive (integration.component.m= aint.test_host_high_availability.TestHostHighAvailability): CRITICAL: FAILE= D: test_03_cant_migrate_vm_to_host_with_ha_positive: ['Traceback (most rece= nt call last):\n', ' File "/usr/lib/python2.7/unittest/case.py", line 332,= in run\n testMethod()\n', ' File "/root/cloudstack/test/integration/co= mponent/maint/test_host_high_availability.py", line 398, in test_03_cant_mi= grate_vm_to_host_with_ha_positive\n self.assertTrue(suitableHost is not = None, "suitablehost should not be None")\n', ' File "/usr/lib/python2.7/un= ittest/case.py", line 425, in assertTrue\n raise self.failureException(m= sg)\n', 'AssertionError: suitablehost should not be None\n'] > --------------------- >> end captured logging << --------------------- > Stacktrace > File "/usr/lib/python2.7/unittest/case.py", line 332, in run > testMethod() > File "/root/cloudstack/test/integration/component/maint/test_host_high_= availability.py", line 398, in test_03_cant_migrate_vm_to_host_with_ha_posi= tive > self.assertTrue(suitableHost is not None, "suitablehost should not be= None") > File "/usr/lib/python2.7/unittest/case.py", line 425, in assertTrue > raise self.failureException(msg) > 'suitablehost should not be None\n-------------------- >> begin captured = stdout << ---------------------\n=3D=3D=3D TestName: test_03_cant_migrate_v= m_to_host_with_ha_positive | Status : FAILED =3D=3D=3D\n\n\n---------------= ------ >> end captured stdout << ----------------------\n------------------= -- >> begin captured logging << --------------------\ntest_03_cant_migrate_= vm_to_host_with_ha_positive (integration.component.maint.test_host_high_ava= ilability.TestHostHighAvailability): DEBUG: ::::::::::::STARTED : TC: test_= 03_cant_migrate_vm_to_host_with_ha_positive=20 > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)