                  Hibernator Checkpointing
                  ------------------------

___INFO__MARK_BEGIN__
-------------------------------------------------------------------------
  The Contents of this file are made available subject to the terms of
  the Sun Industry Standards Source License Version 1.2
 
  Sun Microsystems Inc., March, 2001
 
 
  Sun Industry Standards Source License Version 1.2
  ================================================= 
  The contents of this file are subject to the Sun Industry Standards
  Source License Version 1.2 (the "License"); You may not use this file
  except in compliance with the License. You may obtain a copy of the
  License at http://gridengine.sunsource.net/Gridengine_SISSL_license.html
 
  Software provided under this License is provided on an "AS IS" basis,
  WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
  WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
  MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
  See the License for the specific provisions governing your rights and
  obligations concerning the Software.
 
  The Initial Developer of the Original Code is: Sun Microsystems, Inc.
 
  Copyright: 2001 by Sun Microsystems, Inc.
 
  All Rights Reserved.
-------------------------------------------------------------------------
___INFO__MARK_END__

Definition of a checkpoint environment

  % qconf -ackpt hiber         (or whatever name you like)

or use the approbriate qmon dialog
  
You must fill in these fields:
------------------------------

  interface  hibernator      this name is mandatory for Hibernator
                             checkpointing. It defines the actions 
                             which SGE will do, if SGE has to
                             checkpoint a Hibernator job
  ckpt_command    full path name to the checkpoint command
  migr_command    full path name to the migration command
  restart_command full path name to the restart command
  clean_command   full path name to the clean command

  queue_list list of the queues. Must all reside on one host, if the
             Hibernator checkpoint arena is on the local disk.
  
  when       smx         currently "m" (checkpoint at min_cpu_interval) and
                         "s" (checkpoint a batch server shutdown (qconf
                         -kej) are supported.

If your command is a shell script, the first line must begin with the directive
which shell should be used, e.g.

#!/bin/sh

In general it's a good idea to start scripts insted of checkpointing
commands directly. The command are started under the user id of the job.
It's is possible to log (and append) messages to the output files.

Please see the following examples for a sample set of commands which may be
used for Hibernator checkpointing:

checkpoint_command      migration_command
clean_command           restart_command

in the directory
   $SGE_ROOT/ckpt/ directory

There are some special variables which may appear in the command line of the
checkpointing command set:

   $host        the host name where the job is running
   $job_owner   the user name
   $job_id      the job id
   $job_name    the name of the job
   $queue       the name of the queue 
   $job_pid     the pid of the checkpointing job

A sample checkpoting object might look like this:

% qconf -sckpt hiber
ckpt_name          hiber
interface          hibernator
ckpt_command       /tmp/ckpt_command $job_id $job_pid
migr_command       /tmp/migr_command $job_id $job_pid
restart_command    /tmp/rest_command $job_id
clean_command      /tmp/clean_command $job_id
ckpt_dir           /tmp
queue_list         fangorn fangorn1
signal             none
when               sm

See the example scripts how these variables are used.
