From: Ian Jackson Subject: Re: [OSSTEST Nested PATCH v11 6/7] Compose the main recipe of nested test job Date: Thu, 25 Jun 2015 11:21:33 +0100 Message-ID: <21899.54829.184298.240762@mariner.uk.xensource.com> References: <1432631304-27347-1-git-send-email-longtaox.pang@intel.com> <1432631304-27347-7-git-send-email-longtaox.pang@intel.com> <21880.23264.813171.606123@mariner.uk.xensource.com> <86C3224E41A7434B904EC364302132D80E4BFEC4@SHSMSX101.ccr.corp.intel.com> <21881.42757.84361.654532@mariner.uk.xensource.com> <86C3224E41A7434B904EC364302132D80E4C0A6B@SHSMSX101.ccr.corp.intel.com> <21882.64076.306554.733060@mariner.uk.xensource.com> <1434286285.25577.6.camel@localhost> <1434359303.13744.16.camel@citrix.com> <86C3224E41A7434B904EC364302132D80E4C30D5@SHSMSX101.ccr.corp.intel.com> <1434533714.13744.279.camel@citrix.com> <86C3224E41A7434B904EC364302132D80E4C70CF@SHSMSX101.ccr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <86C3224E41A7434B904EC364302132D80E4C70CF@SHSMSX101.ccr.corp.intel.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "Pang, LongtaoX" Cc: "Hu, Robert" , "wei.liu2@citrix.com" , Ian Campbell , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Pang, LongtaoX writes ("RE: [OSSTEST Nested PATCH v11 6/7] Compose the main recipe of nested test job"): > > -----Original Message----- > > From: Ian Campbell [mailto:ian.campbell@citrix.com] ... > > I think you are correct, the logs capture will fail too. > > > > I'll leave it to Ian to suggest a solution since it will no doubt > > involve some tcl plumbing (I'd be inclined to record 'hosts which are > > actually guests' somewhere and have the infra clean them up > > automatically after doing leak check and log collection). Sorry I haven't done this yet, it's still on my radar. > > I was thinking more along the lines of creating Osstest/PDU/guest.pm > > with the appropriate methods calling out to toolstack($l0)->foo, setting > > $ho->{Power} = 'guest $l1guestname' somewhere and allowing > > power_cycle_host_setup to do it's thing. > > I have reviewed power_cycle_host_setup function, inside this > function will call get_host_method_object, then we could get a $mo > which will be assigned to $ho->{PowerMethobjs}, right? Inside > power_state function, it will call pdu_power_state which is defined > in guest.pm, right? Yes. > So, I need to defined how to power off/on L1 inside pdu_power_state > function? I think we need to using 'xl destroy' and 'xl create' > command to implement the power method. Indeed. You'll need to use the appropriate toolstack object, in case it's libvirt or something. toolstack($ho) where $ho is the L0. Ian.