monsterQueriesHod 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #!/usr/bin/env bash
  2. # Licensed under the Apache License, Version 2.0 (the "License");
  3. # you may not use this file except in compliance with the License.
  4. # You may obtain a copy of the License at
  5. #
  6. # http://www.apache.org/licenses/LICENSE-2.0
  7. #
  8. # Unless required by applicable law or agreed to in writing, software
  9. # distributed under the License is distributed on an "AS IS" BASIS,
  10. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  11. # See the License for the specific language governing permissions and
  12. # limitations under the License.
  13. GRID_DIR=`dirname "$0"`
  14. GRID_DIR=`cd "$GRID_DIR"; pwd`
  15. source $GRID_DIR/../gridmix-env
  16. for ((i=0; i < $NUM_OF_SMALL_JOBS_PER_CLASS; i++))
  17. do
  18. echo $i
  19. CLUSTER_DIR=$CLUSTER_DIR_BASE/monster_query.small.$i
  20. mkdir $CLUSTER_DIR
  21. hod script -d $CLUSTER_DIR $SMALL_JOB_HOD_OPTIONS -s $GRID_MIX_HOME/monsterQuery/monster_query.small 2>&1 > monster_query.small.$i.out &
  22. $GRID_MIX_HOME/submissionScripts/sleep_if_too_busy
  23. done
  24. for ((i=0; i < $NUM_OF_MEDIUM_JOBS_PER_CLASS; i++))
  25. do
  26. echo $i
  27. CLUSTER_DIR=$CLUSTER_DIR_BASE/monster_query.medium.$i
  28. mkdir $CLUSTER_DIR
  29. hod script -d $CLUSTER_DIR $MEDIUM_JOB_HOD_OPTIONS -s $GRID_MIX_HOME/monsterQuery/monster_query.medium 2>&1 > monster_query.medium.$i.out &
  30. $GRID_MIX_HOME/submissionScripts/sleep_if_too_busy
  31. done
  32. for ((i=0; i < $NUM_OF_LARGE_JOBS_PER_CLASS; i++))
  33. do
  34. echo $i
  35. CLUSTER_DIR=$CLUSTER_DIR_BASE/monster_query.large.$i
  36. mkdir $CLUSTER_DIR
  37. hod script -d $CLUSTER_DIR $LARGE_JOB_HOD_OPTIONS -s $GRID_MIX_HOME/monsterQuery/monster_query.large 2>&1 > monster_query.large.$i.out &
  38. $GRID_MIX_HOME/submissionScripts/sleep_if_too_busy
  39. done