[pve-devel] [Qemu-devel] kvm process disappears

Stefan Hajnoczi stefanha at gmail.com
Tue May 28 10:06:06 CEST 2013


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
> ><s.priebe at 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 <unistd.h>
> >#include <stdlib.h>
> >
> >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



More information about the pve-devel mailing list