From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:56124) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhEv9-0004X5-F8 for qemu-devel@nongnu.org; Tue, 28 May 2013 04:06:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UhEv4-0004T5-04 for qemu-devel@nongnu.org; Tue, 28 May 2013 04:06:15 -0400 Received: from mail-ea0-x22a.google.com ([2a00:1450:4013:c01::22a]:35891) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhEv3-0004T0-QA for qemu-devel@nongnu.org; Tue, 28 May 2013 04:06:09 -0400 Received: by mail-ea0-f170.google.com with SMTP id f15so4277174eak.1 for ; Tue, 28 May 2013 01:06:09 -0700 (PDT) Date: Tue, 28 May 2013 10:06:06 +0200 From: Stefan Hajnoczi Message-ID: <20130528080606.GE13368@stefanha-thinkpad.redhat.com> References: <518C8FD7.9080201@profihost.ag> <20130510074217.GB1500@stefanha-thinkpad.redhat.com> <518CB8E4.5090305@profihost.ag> <51A3CB9F.3050908@profihost.ag> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <51A3CB9F.3050908@profihost.ag> Subject: Re: [Qemu-devel] kvm process disappears List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Priebe Cc: Paolo Bonzini , qemu-devel , "pve-devel@pve.proxmox.com" On Mon, May 27, 2013 at 11:09:51PM +0200, Stefan Priebe wrote: > Am 10.05.2013 13:09, schrieb Stefan Hajnoczi: > >On Fri, May 10, 2013 at 11:07 AM, Stefan Priebe - Profihost AG > > wrote: > >>Am 10.05.2013 09:42, schrieb Stefan Hajnoczi: > >>>On Fri, May 10, 2013 at 08:12:39AM +0200, Stefan Priebe - Profihost AG wrote: > >>>3. Either use gdb or an LD_PRELOAD library that catches exit(3) and > >>> _exit(2) and dumps core using abort(3). Make sure core dumps are > >>> enabled. > >> > >>LD_PRELOAD sounds good can you point me to such a lib? > > > >$ cat /tmp/catchexit.c > >#include > >#include > > > >void exit(int status) > >{ > > const char msg[] = "*** CAUGHT EXIT, DUMPING CORE ***\n"; > > write(2, msg, sizeof msg); > > abort(); > >} > > > >void _exit(int status) __attribute__((alias("exit"))); > > > >$ gcc -o catchexit.so -shared -fPIC -std=gnu99 catchexit.c > > > >$ LD_PRELOAD=/tmp/catchexit.so x86_64-softmmu/qemu-system-x86_64 -m > >1024 -enable-kvm -cpu host -vga asdf > >Unknown vga type: asdf > >*** CAUGHT EXIT, DUMPING CORE *** > >Aborted (core dumped) > > > >Make sure to give the absolute path to catchexit.so. Also keep in > >mind that this does not catch a normal return from main() or possibly > >other ways of terminating the process. > > > >You can hook more library functions, if necessary. > > > >Stefan > > I'm really sorry for bothering you. It turned out to be a host > kernel bug. Without NUMA Balancing turned on (kernel 3.8.13) i see > no vm crashes at all... No worries. Glad you found the solution. Stefan