Changeset 854


Ignore:
Timestamp:
05/13/13 22:27:15 (11 years ago)
Author:
ramonb
Message:

jobmond.py:

  • print warning if BATCH_SERVER != localhost and BATCH_API does not support connecting to remote BATCH_SERVER
  • fun fact: discovered that developers of the SGE/LSF implementation also completely ignore the BATCH_SERVER setting
  • see #162
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/1.0/jobmond/jobmond.py

    r853 r854  
    20802080
    20812081    global PBSQuery, PBSError, lsfObject, pyslurm
    2082     global SYSLOG_FACILITY, USE_SYSLOG, BATCH_API, DAEMONIZE
     2082    global SYSLOG_FACILITY, USE_SYSLOG, BATCH_API, DAEMONIZE, BATCH_SERVER
    20832083
    20842084    if not processArgs( sys.argv[1:] ):
     
    20962096        except ImportError, details:
    20972097
    2098             print "FATAL ERROR: BATCH_API set to 'pbs' but python module 'pbs_python' cannot be loaded"
     2098            print "FATAL ERROR: BATCH_API set to 'pbs' but python module 'pbs_python' is not found or installed"
    20992099            print details
    21002100            sys.exit( 1 )
     
    21032103
    21042104    elif BATCH_API == 'sge':
     2105
     2106        if BATCH_SERVER != 'localhost':
     2107
     2108            # Print and log, but continue execution
     2109            err_msg = "WARNING: BATCH_API 'sge' ignores BATCH_SERVER (can only be 'localhost')"
     2110            print err_msg
     2111            debug_msg( 0, err_msg )
    21052112
    21062113        # Tested with SGE 6.0u11.
     
    21102117    elif BATCH_API == 'lsf':
    21112118
     2119        if BATCH_SERVER != 'localhost':
     2120
     2121            # Print and log, but continue execution
     2122            err_msg = "WARNING: BATCH_API 'lsf' ignores BATCH_SERVER (can only be 'localhost')"
     2123            print err_msg
     2124            debug_msg( 0, err_msg )
     2125
    21122126        try:
    21132127            from lsfObject import lsfObject
    21142128        except:
    2115             print "FATAL ERROR: BATCH_API set to 'lsf' but python module is not found or installed"
    2116             sys.exit( 1)
     2129            print "FATAL ERROR: BATCH_API set to 'lsf' but python module 'lsfObject' is not found or installed"
     2130            sys.exit( 1 )
    21172131
    21182132        gather = LsfDataGatherer()
    21192133
    21202134    elif BATCH_API == 'slurm':
     2135
     2136        if BATCH_SERVER != 'localhost':
     2137
     2138            # Print and log, but continue execution
     2139            err_msg = "WARNING: BATCH_API 'slurm' ignores BATCH_SERVER (can only be 'localhost')"
     2140            print err_msg
     2141            debug_msg( 0, err_msg )
    21212142
    21222143        try:
     
    21242145        except:
    21252146            print "FATAL ERROR: BATCH_API set to 'slurm' but python module is not found or installed"
    2126             sys.exit( 1)
     2147            sys.exit( 1 )
    21272148
    21282149        gather = SLURMDataGatherer()
Note: See TracChangeset for help on using the changeset viewer.