Re: Return from callback without invoking cr_checkpoint()

From: Karthik Gopalakrishnan (gopalakk_at_cse.ohio-state.edu)
Date: Fri Jul 03 2009 - 15:51:39 PDT

  • Next message: �����: "Question about CR_SIGNUM"
    Hi Paul.
    
    Thank You very much. I am sorry I missed looking at libcr.h.
    
    Regards,
    Karthik
    
    On Fri, Jul 3, 2009 at 6:29 PM, Paul H. Hargrove<PHHargrove_at_lbl_dot_gov> wrote:
    > Karthik,
    >  If you return from the callback w/o calling cr_checkpoint(), then BLCR will
    > behave as if it was called as the last statement in your callback.  So, not
    > calling cr_checkpoint() will allow the checkpoint request to proceed
    > normally.  If you want to prevent the checkpoint from being taken, you may
    > do so my calling cr_checkpoint() with an argument other than
    > CR_CHECKPOINT_READY, probably CR_CHECKPOINT_OMIT or
    > CR_CHECKPOINT_TEMP_FAILURE.  Quoting from libcr.h:
    >>
    >> // Defined values for "flags" (mutually exclusive):
    >> // CR_CHECKPOINT_READY (==0)
    >> //      The normal case.
    >> // CR_CHECKPOINT_OMIT
    >> //      To continue the checkpoint, but exclude the current process.
    >> //      Will also not run subsequent callbacks in the current group
    >> //      (thread context, or signal context in this same thread).
    >> // CR_CHECKPOINT_TEMP_FAILURE
    >> // CR_CHECKPOINT_TEMP_FAILURE_CODE(error_code)
    >> //      To abort the checkpoint and continue execution.
    >> //      Will also not run subsequent callbacks in the current group
    >> //      (thread context, or signal context in this same thread).
    >> // CR_CHECKPOINT_PERM_FAILURE
    >> // CR_CHECKPOINT_PERM_FAILURE_CODE(error_code)
    >> //      To abort the checkpoint and kill all the processes involved in it.
    >> //      Will also not run subsequent callbacks in the current group
    >> //      (thread context, or signal context in this same thread).
    >
    > -Paul
    >
    >
    > Karthik Gopalakrishnan wrote:
    >>
    >> Hi Folks.
    >>
    >> I understand that cr_checkpoint() should be called *only* from the
    >> callback function's context. However, is it mandatory to call
    >> cr_checkpoint() every time the callback gets invoked?
    >>
    >> Say my callback got invoked because someone did a 'cr_checkpoint -p
    >> <PID>' from the shell. If I want to ignore this checkpoint request,
    >> can I simply return from the callback without invoking
    >> cr_checkpoint(), or will this violate BLCR semantics?
    >>
    >> Thanks & Regards,
    >> Karthik
    >>
    >
    >
    > --
    > Paul H. Hargrove                          PHHargrove_at_lbl_dot_gov
    > Future Technologies Group                 Tel: +1-510-495-2352
    > HPC Research Department                   Fax: +1-510-486-6900
    > Lawrence Berkeley National Laboratory
    >
    

  • Next message: �����: "Question about CR_SIGNUM"