Changeset 364


Ignore:
Timestamp:
Feb 13, 2012, 9:37:44 PM (13 years ago)
Author:
Rick van der Zwet
Message:

Well, ehm epoch is in seconds.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • misc/power-saver

    r363 r364  
    5555# Count the amount entries we are current on our way
    5656IDLE_COUNTS=`awk -vMAX_LOAD=$MAX_LOAD -vMAX_IDLE=$MAX_IDLE -vEPOCH=$EPOCH \
    57   'BEGIN{MIN_TIME=EPOCH-MAX_IDLE;s=0}{if ($1 > MIN_TIME && $2 < MAX_LOAD){s += 1}}END{print s}' $DAT_FILE`
     57  'BEGIN{MIN_TIME=EPOCH-MAX_IDLE * 60;s=0}{if ($1 > MIN_TIME && $2 < MAX_LOAD){s += 1}}END{print s}' $DAT_FILE`
    5858
    5959# We are idle for over $MAX_IDLE time, starting shutdown
Note: See TracChangeset for help on using the changeset viewer.