From: Ian Jackson Subject: Re: Current LibXL Status Date: Thu, 18 Feb 2016 18:30:57 +0000 Message-ID: <22214.3553.260609.617265@mariner.uk.xensource.com> References: <564CC43B.1000904@ainfosec.com> <1447924858.5647.15.camel@citrix.com> <564DAA8D.5060305@citrix.com> <1447932195.5647.46.camel@citrix.com> <564DB393.3070805@citrix.com> <1447933727.5647.51.camel@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <1447933727.5647.51.camel@citrix.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: Ian Campbell Cc: Andrew Cooper , Martin Osterloh , "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Ian Campbell writes ("Re: [Xen-devel] Current LibXL Status"): > The only one I can find which isn't one of this is > in=A0libxl__event_disaster, and that is only if the applications (or lang= uage > bindings) haven't provided a suitable disaster callback. libxl__event_disaster can currently happen in the following cases. Disasters which are specific to a specific requested event (type!=3D0): xc_domain_getinfolist failure (breaks reporting domain death, only xw_write failure for acknowledging disk eject (breaks reporting ejects, only) General disasters (type=3D=3D0) due to xenstore problems: POLLERR or POLLHUP on xenstore fd xs_check_watch fails (represents trouble on xenstore fd or with xenstore) xs_read for domain death check General disasters (type=3D=3D0) due to hypercall trouble: xenevtchn_pending fails other than with EAGAIN (unrequested) event other than POLLIN on evtchn fd General disasters (type=3D=3D0) due to syscall failure: poll syscall fails (unrequested) event other than POLLIN on self-pipe read() or write() fails on a self-pipe (other than EAGAIN/EWOULDBLOCK) waitpid() syscall fails General disasters (type=3D=3D0) induced by the application: waitpid reports ECHILD when we know we have a child (probably, something else in the process reaped it; arguably this should abort) application's childproc_hooks->reaped_callback failure Disasters are not reported unless it is impossible to proceed. So in general it is not possible for a process to recover from a disaster reported by libxl. But disasters are never expected. They should occur only if everything is totally doomed anyway. Having a daemon crash is a perfectly reasonable response. Ian.