From: Alex Bligh Subject: Re: Early ACPI events prevent subsequent ACPI functionality on xen 4.3 + HVM domU Date: Tue, 21 May 2013 17:25:40 +0100 Message-ID: <5CD7E2BDD43484002BA5BA15@Ximines.local> References: <752956577.8634488.1368537190555.JavaMail.root@zimbra002> <1368812151.24012.66.camel@hastur.hellion.org.uk> <71194FD00ABB7415DD6106AA@nimrod.local> <090E19BC911ECE1F10940F48@Ximines.local> <519B9154.2090709@eu.citrix.com> <8AFE377F6BC64692CB48563B@Ximines.local> <519B9C3D.5030508@eu.citrix.com> Reply-To: Alex Bligh Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <519B9C3D.5030508@eu.citrix.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: George Dunlap Cc: Ian Campbell , xen-devel@lists.xen.org, Stefano Stabellini , Alex Bligh , Anthony Perard , Diana Crisan List-Id: xen-devel@lists.xenproject.org George, > xl/libxl is working as designed. xl tried libxl_domain_shutdown() first. > libxl saw that there were PV drivers available, so it sent the PV > shutdown signal over xenstore and returned success. libxl and xl have no > way of knowing that the signal was never received, so it never falls back > to ACPI. > > "xl trigger power" is a work-around because when you detect that a guest > is stuck, you should be able to issue an ACPI shutdown and get a clean > shutdown, even when the PV shutdown path is stuck. > > (In fact, as a short-term solution, you might consider just replacing "xl > shutdown $d" with "xl trigger $d power" in your control framework.) Yup. I think this is the best option, save for the fact that 'xl trigger power' itself appears unreliable. We apparently need to send it multiple times. Diana will send more details. >> Does xl trigger reset do the same thing (i.e. a graceful shutdown)? >> If not we'd also (I think) have to recode reboots to do a power trigger >> then a restart. > > Hmm, this is what I get: > ># xl trigger h0 reset > libxl: error: libxl.c:4639:libxl_send_trigger: Send trigger 'reset' > failed: Function not implemented > > YMMV... Indeed. So presumably 'xl trigger power' (+/- repeats to get it to work), wait until the domain is dead, then power it back up again. -- Alex Bligh