[CentOS-virt] reboot guest on panic

Pasi Kärkkäinen pasik at iki.fi
Sun Mar 14 14:16:13 UTC 2010


On Sun, Mar 14, 2010 at 09:03:23AM +1100, Norman Gaywood wrote:
> I have a guest that keeps crashing and want to automatically reboot it
> when it crashes. See:
> 
>   xen PV guest kernel 2.6.32 processes lock up in D state
>   https://bugzilla.redhat.com/show_bug.cgi?id=550724
> 
> if you want to look at the details on the crashing.
> 

Btw please see: 
http://wiki.xensource.com/xenwiki/XenCommonProblems

Especially the chapter about debugging crashed guests.
It would be very helpful to grab a stacktrace of the crashed guest to debug it.

So set on_crash=preserve for the guest, and then use xenctx (with the guest kernel System.map)
to get the stack trace..

Redhat bugzilla seems to be down, so I can't check the details about 
the bugreport. Is the guest single-vcpu or multi-vcpu? 32bit or 64bit?

-- Pasi

> Anyway, I boot the guest with the kernel command line parameter:
> 
>   hung_task_panic=1
> 
> I have kernel.panic = 15 in the guest /etc/sysctl.conf
> 
> In the guest config file in dom0 I have:
> 
>   on_poweroff = "destroy"
>   on_reboot = "restart"
>   on_crash = "restart"
> 
> The guest manages to panic when it detects the hung tasks and I get this
> on the guest console:
> 
>   Kernel panic - not syncing: hung_task: blocked tasks
>   Rebooting in 15 seconds..
> 
> However, it never restarts. It just hangs around until I do a
> 
>   xm destroy <guest>
>   xm create <guest>
> 
> Have I missed something?
> 
> -- 
> Norman Gaywood, Computer Systems Officer
> University of New England, Armidale, NSW 2351, Australia
> 
> ngaywood at une.edu.au            Phone: +61 (0)2 6773 3337
> http://mcs.une.edu.au/~norm    Fax:   +61 (0)2 6773 3312
> 
> Please avoid sending me Word or PowerPoint attachments.
> See http://www.gnu.org/philosophy/no-word-attachments.html
> _______________________________________________
> CentOS-virt mailing list
> CentOS-virt at centos.org
> http://lists.centos.org/mailman/listinfo/centos-virt


More information about the CentOS-virt mailing list