[GE users] fluent license problem

MBC 4u mbc_4u2005 at yahoo.com
Tue Nov 8 09:33:42 GMT 2005


    [ The following text is in the "iso-8859-1" character set. ]
    [ Your display is set for the "ISO-8859-10" character set.  ]
    [ Some special characters may be displayed incorrectly. ]

hi all,
 
I am a new user of fluent. I have a load sensor script which tracks free licenses. I submit jobs based on complex resource i.e. license_fluent. but due to some interactive users, sometimes it happens that the grid has dispatched the job and at the same time before the job gets the license, some interactive user occupies the license and the grid job fails. 
I have tried prolog script for this but it dosent work. The script is as follows:
 
#!/bin/sh
    # prolog    # <settings>
    : ${SGE_ROOT:=/opt/n1ge}
    : ${SGE_CELL:=default}
    for i in $SGE_ROOT/$SGE_CELL/common/settings.sh; do [ -f $i ] && . $i; done
    # </settings>    # the (hard) requested resources
    rclist=`qstat -r -j $JOB_ID | sed -ne 's/^.*hard *resource_list: *//p'`
    # <resource_check>
    # verify that the expected resources actually exist
    # this should prevent the race condition that occurs between SGE jobs
    # before the load report (available licenses) gets updated
    #
    query="$SGE_ROOT/$SGE_CELL/common/qlicserver"
    if [ -n "$rclist" -a -x "$query" ]; then
       echo "query resources   $rclist,slots=$NSLOTS"
       available=`$query $rclist,slots=$NSLOTS`
       exitcode=$?
       if [ $exitcode -eq 99 ]; then
          echo "re-queue job      $available"
          echo "-------------------------"
          exit 99
       fi
       if [ $exitcode -ne 0 ]; then
          echo "error with license query $exitcode"
          exit $exitcode
       fi
    fi
    # </resource_check>
 
Please suggest corrections if any.
 
thanks n regards,
mbc

		
---------------------------------
 Yahoo! FareChase - Search multiple travel sites in one click.  



More information about the gridengine-users mailing list