Changeset 835


Ignore:
Timestamp:
03/22/13 16:05:09 (11 years ago)
Author:
labetoulle
Message:

Runchecker : add rsh access for monitoring files on Ada. See #128.

Location:
trunk/libIGCM
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/libIGCM/AA_RunChecker

    r834 r835  
    4141  fi 
    4242 
    43   if ( [ ${NbOcc} -eq 0 ] && ( $fg_path ) ) ; then 
     43  if ( [ ${NbOcc} -eq 0 ] && ( ${fg_path} ) ) ; then 
    4444    set -A FileList $( ls ${ConfigPath}/Job_* ) 
    4545    if [ X$FileList == X ] ; then 
     
    114114        exit 
    115115      fi 
    116       break ;; 
     116      ;; 
    117117    *) 
    118118      break ;; 
     
    184184      Fatal) 
    185185        Color=${ColFat} 
    186         break ;; 
     186        ;; 
    187187      Completed) 
    188188        Color=${ColCpl} 
    189         break ;; 
     189        ;; 
    190190      Waiting|OnQueue) 
    191191        Color=${ColAtt} 
    192         break ;; 
     192        ;; 
    193193      *) 
    194194        Color=${ColDef} 
    195         break ;; 
     195        ;; 
    196196    esac 
    197197    printf "${Color}%-11s${ColNon} | " $PeriodState 
     
    273273#======================================================================# 
    274274 
    275 #D- Task type (computing ,post-processing or checking) 
     275#D- Task type (computing, post-processing or checking) 
    276276TaskType=checking 
    277277typeset -i Verbosity=0 
     
    340340 
    341341 
    342 if ( ( ! $fg_path ) && [ $# -lt 1 ] ) ; then 
     342if ( ( ! ${fg_path} ) && [ $# -lt 1 ] ) ; then 
    343343  $0 -h 
    344344  exit 
     
    356356 
    357357DEBUG_debug=false 
     358DEBUG_sys=false 
    358359 
    359360. ${libIGCM}/libIGCM_debug/libIGCM_debug.ksh 
     
    392393 
    393394  echo "Submit:  >${SUBMIT_DIR}<" 
    394   cd $SUBMIT_DIR 
     395  IGCM_sys_Cd $SUBMIT_DIR 
    395396 
    396397 
     
    589590    # ========================== 
    590591    JobType=monitoring 
    591     if [ -d ${CWORK_DIR}/MONITORING ] ; then 
    592       LastDate=$( cdo showyear ${CWORK_DIR}/MONITORING/files/ATM_bils_global_ave.nc 2> /dev/null | \ 
    593                       gawk '{ print $NF }' ) 
     592    IGCM_sys_TestDirArchive ${CWORK_DIR}/MONITORING 
     593    RC=$? 
     594    if [ $RC == 0 ] ; then 
     595      FileTmp=$( IGCM_sys_RshArchive "ls ${CWORK_DIR}/MONITORING/files/*.nc | head -n 1" ) 
     596      IGCM_sys_GetDate_Monitoring ${FileTmp} LastDate 
    594597      eval ${JobType}_Date=${LastDate} 
    595598    fi 
     
    598601    # ===================== 
    599602    JobType=atlas 
    600     if [ -d ${CWORK_DIR}/ATLAS ] ; then 
    601       set -A FileList $( ls ${CWORK_DIR}/ATLAS | tail -n ${NbHisto} ) 
     603    IGCM_sys_TestDirArchive ${CWORK_DIR}/ATLAS 
     604    RC=$? 
     605    if [ $RC == 0 ] ; then 
     606      set -A FileList $( IGCM_sys_RshArchive "ls ${CWORK_DIR}/ATLAS | tail -n ${NbHisto}" ) 
    602607 
    603608      if [ ${#FileList[*]} -gt ${NbLines} ] ; then 
  • trunk/libIGCM/libIGCM_sys/libIGCM_sys_ada.ksh

    r828 r835  
    15441544 
    15451545#D-#================================================== 
     1546#D-function IGCM_sys_GetDate_Monitoring 
     1547#D-* Purpose: get the last year for which the monitoring has been computed 
     1548#D-* Examples: 
     1549#D- 
     1550function IGCM_sys_GetDate_Monitoring { 
     1551#set -vx 
     1552  IGCM_debug_PushStack "IGCM_sys_GetDate_Monitoring" $@ 
     1553  if ( $DEBUG_sys ) ; then 
     1554    echo "IGCM_sys_GetDate_Monitoring :" $@ 
     1555  fi 
     1556 
     1557  IGCM_sys_Cd /tmp 
     1558  IGCM_sys_Get ${1} . 
     1559  eval ${2}=$( cdo showyear $( basename ${1} ) 2> /dev/null | gawk '{ print $NF }' ) 
     1560  IGCM_sys_Cd - 
     1561 
     1562#set +vx 
     1563  IGCM_debug_PopStack "IGCM_sys_GetDate_Monitoring" 
     1564} 
     1565 
     1566#D-#================================================== 
    15461567#D-function IGCM_sys_Put_Dods 
    15471568#D-* Purpose: Put $(ARCHIVE) files on DODS internet protocole. 
  • trunk/libIGCM/libIGCM_sys/libIGCM_sys_curie.ksh

    r834 r835  
    16941694 
    16951695#D-#================================================== 
     1696#D-function IGCM_sys_GetDate_Monitoring 
     1697#D-* Purpose: get the last year for which the monitoring has been computed 
     1698#D-* Examples: 
     1699#D- 
     1700function IGCM_sys_GetDate_Monitoring { 
     1701  IGCM_debug_PushStack "IGCM_sys_GetDate_Monitoring" $@ 
     1702  if ( $DEBUG_sys ) ; then 
     1703    echo "IGCM_sys_GetDate_Monitoring :" $@ 
     1704  fi 
     1705 
     1706  eval ${2}=$( cdo showyear ${1} 2> /dev/null | gawk '{ print $NF }' ) 
     1707 
     1708  IGCM_debug_PopStack "IGCM_sys_GetDate_Monitoring" 
     1709} 
     1710 
     1711#D-#================================================== 
    16961712#D-function IGCM_sys_Dods_Rm 
    16971713#D-* Purpose: DO NOTHING ! Put ${ARCHIVE} files on DODS internet protocole. 
Note: See TracChangeset for help on using the changeset viewer.