On 08/01/14 at 12:37am, WANG Chao wrote:
[..]
> > --- /dev/null
> > +++ b/dracut-kdump-error-handler.sh
> > @@ -0,0 +1,18 @@
> > +#!/bin/sh
> > +
> > +. /lib/kdump-lib-initramfs.sh
> > +
> > +set -o pipefail
> > +export PATH=$PATH:$KDUMP_SCRIPT_DIR
> > +
> > +# We only allow to enter kdump error handler once.
> > +# If error happens in error handling path and we simply reboot.
> > +if [ -f /kdump-error-handler ]; then
> > + do_final_action
In fact, this checking is useless. because systemd doesn't allow us to
isolate to kdump-error-handler if we're already in kdump-error-handler.
IOW, we will always have one instance of kdump-error-handler running in
isolation mode,
So we don't have to worry about entering it again because we can't be
interrupt by another instance, and after we finish, we should reboot in
any case.
Thanks
WANG Chao