[RC5] The -pausefile option

Dominique Pelle dominique.pelle at eurocontrol.fr
Fri Apr 23 10:48:41 EDT 1999

Samuel Chow wrote:

> Hi there,
>        I am running the solaris-ultra-mt client.  I
>         wrote a little script to pause the client when
>         the load on the machine is greater than
>         some number (using uptime to check).
>         I have noticed that the client does indeed
>         pause for a day or two.  After that, the
>         client ignore the present of the pause file
>         and keeping on running even when the
>         pause file is there.
>        Anyone else notice that?


I don't know why the client ignores the pause file
but here is another way to stop it: just kill it!

When the client receives the SIGINT signal, it performs
a shutdown and saves the percentage of the block computed
so far.  


     # /bin/sh

     ./rc5des &
     # --- stop the client when the load is greater than MAX_LOAD
     while true
        LOAD=`uptime | sed 's/.*load average://' | awk -F. '{print $1}'`
        if [ "$LOAD" -gt "$MAX_LOAD" ]
          kill $PID_CLIENT
        sleep 20  # do no busy wait!


Dominique Pelle                 Eurocontrol Experimental Centre
Direct      +33 (0)1.6988.7464
Switchboard +33 (0)1.6988.7500  http://home.eurocontrol.fr/~pel/
Fax         +33 (0)1.6988.7333  mailto:dominique.pelle at eurocontrol.fr

To unsubscribe, send 'unsubscribe rc5' to majordomo at lists.distributed.net
rc5-digest subscribers replace rc5 with rc5-digest

More information about the rc5 mailing list