Ignore:
Timestamp:
10/24/14 15:05:25 (10 years ago)
Author:
sdipsl
Message:
  • Hunting /tmp usage on Ada
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/libIGCM/libIGCM_sys/libIGCM_sys_ada.ksh

    r1101 r1121  
    321321  fi 
    322322  # keep standard input (stdin) for the loop onto temporary file 
    323   cat >/tmp/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
    324  
    325   /bin/ksh </tmp/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
     323  cat >${RUN_DIR_PATH}/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
     324 
     325  /bin/ksh <${RUN_DIR_PATH}/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
    326326  if [ $? -gt 0 ] ; then 
    327327    echo "IGCM_sys_RshPost : erreur." 
     
    329329  fi 
    330330  # delete temporary file 
    331   \rm /tmp/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
     331  \rm ${RUN_DIR_PATH}/tmp_IGCM_sys_RshPost_$$_${LOGNAME} 
    332332 
    333333  IGCM_debug_PopStack "IGCM_sys_RshPost" 
     
    761761      -e "s:\# \@ error *= .*:\# \@ error = ${Script_Output}:"   \ 
    762762      $1 > ${REP_FOR_JOB}/JOB_FOR_IGCM 
    763   cd $REP_FOR_JOB ; /usr/bin/llsubmit JOB_FOR_IGCM > /tmp/out_command.$$ 2>&1 ; status=$? ; cd - ; 
    764  
    765   cat /tmp/out_command.$$ 
     763  cd $REP_FOR_JOB ; /usr/bin/llsubmit JOB_FOR_IGCM > ${RUN_DIR_PATH}/out_command.$$ 2>&1 ; status=$? ; cd - ; 
     764 
     765  cat ${RUN_DIR_PATH}/out_command.$$ 
    766766  if [ ${status} -gt 0 ] ; then 
    767767    IGCM_debug_Print 2 "IGCM_sys_Qsub $1 : error code ${status}" 
    768768    IGCM_debug_Exit "IGCM_sys_Qsub" 
    769769  else 
    770     JobID=$( gawk {'print $4'} /tmp/out_command.$$ | tail -1 | sed -e s/\"//g ) 
     770    JobID=$( gawk {'print $4'} ${RUN_DIR_PATH}/out_command.$$ | tail -1 | sed -e s/\"//g ) 
    771771    IGCM_sys_Rm ${REP_FOR_JOB}/JOB_FOR_IGCM 
    772772  fi 
     
    938938  mkdir -p ${HOME}/MIRROR/${PATHlibIGCM} 
    939939 
    940   echo ${RSYNC} ${RSYNC_opt} ${libIGCM} ${HOME}/MIRROR/${PATHlibIGCM} > /tmp/out_command.$$ 2>&1 
    941   ${RSYNC} ${RSYNC_opt} ${libIGCM} ${HOME}/MIRROR/${PATHlibIGCM} >> /tmp/out_command.$$ 2>&1 
     940  echo ${RSYNC} ${RSYNC_opt} ${libIGCM} ${HOME}/MIRROR/${PATHlibIGCM} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     941  ${RSYNC} ${RSYNC_opt} ${libIGCM} ${HOME}/MIRROR/${PATHlibIGCM} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    942942  status=$? 
    943943 
    944944  if [ ${status} -gt 0 ] ; then 
    945945    echo "IGCM_sys_Mirror_libIGCM Warning : no libIGCM on frontend." 
    946     cat /tmp/out_command.$$ 
     946    cat ${RUN_DIR_PATH}/out_command.$$ 
    947947  fi 
    948948  IGCM_debug_PopStack "IGCM_sys_Mirror_libIGCM" 
     
    962962  typeset status 
    963963 
    964   echo cp $@ > /tmp/out_command.$$ 2>&1 
    965   \cp $@ >> /tmp/out_command.$$ 2>&1 
     964  echo cp $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     965  \cp $@ >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    966966  status=$? 
    967967 
    968968  if [ ${status} -gt 0 ] ; then 
    969969    echo "IGCM_sys_Cp : error code ${status}" 
    970     cat /tmp/out_command.$$ 
     970    cat ${RUN_DIR_PATH}/out_command.$$ 
    971971    IGCM_debug_Exit "IGCM_sys_Cp" 
    972972  else 
    973     \rm /tmp/out_command.$$ 
     973    \rm ${RUN_DIR_PATH}/out_command.$$ 
    974974  fi 
    975975  IGCM_debug_PopStack "IGCM_sys_Cp" 
     
    10331033    typeset status 
    10341034 
    1035     echo mv $@ > /tmp/out_command.$$ 2>&1 
    1036     \mv $@ >> /tmp/out_command.$$ 2>&1 
     1035    echo mv $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1036    \mv $@ >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    10371037    status=$? 
    10381038 
    10391039    if [ ${status} -gt 0 ] ; then 
    10401040      echo "IGCM_sys_Mv : error code ${status}" 
    1041       cat /tmp/out_command.$$ 
     1041      cat ${RUN_DIR_PATH}/out_command.$$ 
    10421042      IGCM_debug_Exit "IGCM_sys_Mv" 
    10431043    else 
    1044       \rm /tmp/out_command.$$ 
     1044      \rm ${RUN_DIR_PATH}/out_command.$$ 
    10451045    fi 
    10461046  fi 
     
    10741074    DEBUG_sys=false IGCM_sys_IsFileArchived $2 
    10751075    if [ $? = 0 ] ; then 
    1076       \rcp -r $1 ${STOREHOST}:$2 > /tmp/out_command.$$ 2>&1 
     1076      \rcp -r $1 ${STOREHOST}:$2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    10771077      status=$? 
    10781078    else 
    1079       \cp -r $1 $2 > /tmp/out_command.$$ 2>&1 
     1079      \cp -r $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    10801080      status=$? 
    10811081    fi 
     
    10831083    if [ ${status} -gt 0 ] ; then 
    10841084      IGCM_debug_Print 2 "IGCM_sys_Put_Dir : rcp or cp failed error code ${status}" 
    1085       cat /tmp/out_command.$$ 
     1085      cat ${RUN_DIR_PATH}/out_command.$$ 
    10861086      IGCM_debug_Exit "IGCM_sys_Put_Dir" 
    10871087    else 
    1088       \rm /tmp/out_command.$$ 
     1088      \rm ${RUN_DIR_PATH}/out_command.$$ 
    10891089    fi 
    10901090  fi 
     
    11251125      i=0 
    11261126      while [ $i -lt $NB_ESSAI ] ; do 
    1127         \rcp -rp ${STOREHOST}:$1 $2 > /tmp/out_command.$$ 2>&1 
     1127        \rcp -rp ${STOREHOST}:$1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    11281128        status=$? 
    11291129        if [ ${status} -gt 0 ]; then 
     
    11371137      done 
    11381138    else 
    1139       \cp -rp $1 $2 > /tmp/out_command.$$ 2>&1 
     1139      \cp -rp $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    11401140      status=$? 
    11411141      if [ ${status} -gt 0 ] ; then 
    11421142        IGCM_debug_Print 2 "IGCM_sys_Get_Dir : cp failed error code ${status}" 
    1143         cat /tmp/out_command.$$ 
     1143        cat ${RUN_DIR_PATH}/out_command.$$ 
    11441144        IGCM_debug_Exit "IGCM_sys_Get_Dir" 
    11451145      else 
    1146         \rm /tmp/out_command.$$ 
     1146        \rm ${RUN_DIR_PATH}/out_command.$$ 
    11471147      fi 
    11481148    fi 
    11491149    if [ ${status} -gt 0 ] ; then 
    11501150      echo "IGCM_sys_Get_Dir : error." 
    1151       cat /tmp/out_command.$$ 
     1151      cat ${RUN_DIR_PATH}/out_command.$$ 
    11521152      IGCM_debug_Exit "IGCM_sys_Get_Dir" 
    11531153    else 
    1154       \rm /tmp/out_command.$$ 
     1154      \rm ${RUN_DIR_PATH}/out_command.$$ 
    11551155    fi 
    11561156  fi 
     
    11831183    i=0 
    11841184    while [ $i -lt $NB_ESSAI ] ; do 
    1185       \cp -urL $1 $2 > /tmp/out_command.$$ 2>&1 
     1185      \cp -urL $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    11861186      status=$? 
    11871187      if [ ${status} -gt 0 ]; then 
     
    11971197    if [ ${status} -gt 0 ] ; then 
    11981198      echo "IGCM_sys_Get_Master : error." 
    1199       cat /tmp/out_command.$$ 
     1199      cat ${RUN_DIR_PATH}/out_command.$$ 
    12001200      IGCM_debug_Exit "IGCM_sys_Get_Master" 
    12011201    else 
    1202       \rm /tmp/out_command.$$ 
     1202      \rm ${RUN_DIR_PATH}/out_command.$$ 
    12031203    fi 
    12041204  fi 
     
    12391239    DEBUG_sys=false IGCM_sys_IsFileArchived $2 
    12401240    if [ $? = 0 ] ; then 
    1241       mfput $1 $2 > /tmp/out_command.$$ 2>&1 
     1241      mfput $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    12421242      status=$? 
    12431243    else 
    12441244      IGCM_sys_MkdirArchive $( dirname $2 ) 
    1245       \cp $1 $2 > /tmp/out_command.$$ 2>&1 
     1245      \cp $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    12461246      status=$? 
    12471247    fi 
     
    12491249#       #RSYNC WITH NETWORK RSH CALL 
    12501250#       IGCM_sys_MkdirArchive $( dirname $2 ) 
    1251 #       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} > /tmp/out_command.$$ 2>&1 
    1252 #       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} >> /tmp/out_command.$$ 2>&1 
     1251#       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1252#       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    12531253 
    12541254#       #RSYNC WITH NFS USE 
    1255 #       echo ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} > /tmp/out_command.$$ 2>&1 
    1256 #       ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} >> /tmp/out_command.$$ 2>&1 
     1255#       echo ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1256#       ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    12571257 
    12581258#       status=$? 
    12591259#       IGCM_sys_Rsync_out $status 
    12601260 
    1261 #       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk /tmp/out_command.$$ 
     1261#       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk ${RUN_DIR_PATH}/out_command.$$ 
    12621262#       (( status=status+$? )) 
    12631263 
    12641264    if [ ${status} -gt 0 ] ; then 
    12651265      echo "IGCM_sys_Put_Rest : mfput or cp failed error code ${status}" 
    1266       cat /tmp/out_command.$$ 
     1266      cat ${RUN_DIR_PATH}/out_command.$$ 
    12671267      IGCM_debug_Exit "IGCM_sys_Put_Rest" 
    12681268    else 
    1269       \rm /tmp/out_command.$$ 
     1269      \rm ${RUN_DIR_PATH}/out_command.$$ 
    12701270    fi 
    12711271  fi 
     
    12981298    # 
    12991299    # USUAL WAY 
    1300     \cp $1 $2 > /tmp/out_command.$$ 2>&1 
     1300    \cp $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    13011301    status=$? 
    13021302 
     
    13051305      [ -f ${2} ] && ls -l ${2} 
    13061306      [ -f ${2}/${1} ] && ls -l ${2}/${1} 
    1307       cat /tmp/out_command.$$ 
     1307      cat ${RUN_DIR_PATH}/out_command.$$ 
    13081308      IGCM_debug_Exit "IGCM_sys_PutBuffer_Rest" 
    13091309    else 
    1310       \rm /tmp/out_command.$$ 
     1310      \rm ${RUN_DIR_PATH}/out_command.$$ 
    13111311    fi 
    13121312  fi 
     
    13581358    DEBUG_sys=false IGCM_sys_IsFileArchived $2 
    13591359    if [ $? = 0 ] ; then 
    1360       mfput $1 $2 > /tmp/out_command.$$ 2>&1 
     1360      mfput $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    13611361      status=$? 
    13621362    else 
    13631363      IGCM_sys_MkdirArchive $( dirname $2 ) 
    1364       \cp $1 $2 > /tmp/out_command.$$ 2>&1 
     1364      \cp $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    13651365      status=$? 
    13661366    fi 
     
    13681368#       #RSYNC WITH NETWORK RSH CALL 
    13691369#       IGCM_sys_MkdirArchive $( dirname $2 ) 
    1370 #       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} > /tmp/out_command.$$ 2>&1 
    1371 #       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} >> /tmp/out_command.$$ 2>&1 
     1370#       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1371#       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${RUN_DIR}/$1 ${STOREHOST}:${2} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    13721372 
    13731373#       #RSYNC WITH NFS USE 
    1374 #       echo ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} > /tmp/out_command.$$ 2>&1 
    1375 #       ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} >> /tmp/out_command.$$ 2>&1 
     1374#       echo ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1375#       ${RSYNC} ${RSYNC_opt} ${RUN_DIR}/$1 ${2} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    13761376 
    13771377#       status=$? 
    13781378#       IGCM_sys_Rsync_out $status 
    13791379 
    1380 #       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk /tmp/out_command.$$ 
     1380#       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk ${RUN_DIR_PATH}/out_command.$$ 
    13811381#       (( status=status+$? )) 
    13821382 
    13831383    if [ ${status} -gt 0 ] ; then 
    13841384      IGCM_debug_Print 2 "IGCM_sys_Put_Out : mfput or cp failed error code ${status}" 
    1385       cat /tmp/out_command.$$ 
     1385      cat ${RUN_DIR_PATH}/out_command.$$ 
    13861386      IGCM_debug_Exit "IGCM_sys_Put_Out" 
    13871387    else 
    1388       \rm /tmp/out_command.$$ 
     1388      \rm ${RUN_DIR_PATH}/out_command.$$ 
    13891389    fi 
    13901390  fi 
     
    14441444      while [ $i -lt $NB_ESSAI ] ; do 
    14451445        # USUAL WAY 
    1446         \cp $1 $2 > /tmp/out_command.$$ 2>&1 
     1446        \cp $1 $2 > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    14471447        status=$? 
    14481448        if [ ${status} -gt 0 ]; then 
     
    14631463      [ -f ${2} ] && ls -l ${2} 
    14641464      [ -f ${2}/${1} ] && ls -l ${2}/${1} 
    1465       cat /tmp/out_command.$$ 
     1465      cat ${RUN_DIR_PATH}/out_command.$$ 
    14661466      IGCM_debug_Exit "IGCM_sys_PutBuffer_Out" 
    14671467    else 
     
    14741474      fi 
    14751475 
    1476       \rm /tmp/out_command.$$ 
     1476      \rm ${RUN_DIR_PATH}/out_command.$$ 
    14771477    fi 
    14781478  fi 
     
    15211521    DEBUG_sys=false IGCM_sys_IsFileArchived ${dm_liste[0]} 
    15221522    if [ $? = 0 ] ; then 
    1523       mfget ${dm_liste[*]} ${DEST} > /tmp/out_command.$$ 2>&1 
     1523      mfget ${dm_liste[*]} ${DEST} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    15241524      status=$? 
    15251525    else 
    1526       \cp ${dm_liste[*]} ${DEST} > /tmp/out_command.$$ 2>&1 
     1526      \cp ${dm_liste[*]} ${DEST} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    15271527      status=$? 
    15281528    fi 
    15291529 
    15301530#       #RSYNC WITH NETWORK RSH CALL 
    1531 #       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${STOREHOST}:"${dm_liste}" ${STOREHOST}:${RUN_DIR}/${DEST} > /tmp/out_command.$$ 2>&1 
    1532 #       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${STOREHOST}:"${dm_liste}" ${STOREHOST}:${RUN_DIR}/${DEST} >> /tmp/out_command.$$ 2>&1 
     1531#       echo ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${STOREHOST}:"${dm_liste}" ${STOREHOST}:${RUN_DIR}/${DEST} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1532#       ${RSYNC} ${RSYNC_opt} --rsync-path=${REMOTE_RSYNC} -e rsh ${STOREHOST}:"${dm_liste}" ${STOREHOST}:${RUN_DIR}/${DEST} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    15331533 
    15341534#       #RSYNC WITH NFS USE 
    1535 #       echo ${RSYNC} ${RSYNC_opt} ${dm_liste} ${RUN_DIR}/${DEST} > /tmp/out_command.$$ 2>&1 
    1536 #       ${RSYNC} ${RSYNC_opt} ${dm_liste} ${RUN_DIR}/${DEST} >> /tmp/out_command.$$ 2>&1 
     1535#       echo ${RSYNC} ${RSYNC_opt} ${dm_liste} ${RUN_DIR}/${DEST} > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
     1536#       ${RSYNC} ${RSYNC_opt} ${dm_liste} ${RUN_DIR}/${DEST} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    15371537 
    15381538#       status=$? 
    15391539#       IGCM_sys_Rsync_out $status 
    15401540 
    1541 #       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk /tmp/out_command.$$ 
     1541#       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk ${RUN_DIR_PATH}/out_command.$$ 
    15421542#       (( status=status+$? )) 
    15431543 
    15441544    if [ ${status} -gt 0 ] ; then 
    15451545      IGCM_debug_Print 2 "IGCM_sys_Get : mfget or cp failed error code ${status}" 
    1546       cat /tmp/out_command.$$ 
     1546      cat ${RUN_DIR_PATH}/out_command.$$ 
    15471547      IGCM_debug_Exit "IGCM_sys_Get" 
    15481548    else 
    1549       \rm /tmp/out_command.$$ 
     1549      \rm ${RUN_DIR_PATH}/out_command.$$ 
    15501550    fi 
    15511551  fi 
     
    15871587        i=0 
    15881588        while [ $i -lt $NB_ESSAI ] ; do 
    1589           \cp ${target} ${DEST}/${local_file} >> /tmp/out_command.$$ 2>&1 
     1589          \cp ${target} ${DEST}/${local_file} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    15901590          status=$? 
    15911591          if [ ${status} -gt 0 ]; then 
     
    16001600        if [ ${status} -gt 0 ] ; then 
    16011601          echo "IGCM_sys_Get : error" 
    1602           cat /tmp/out_command.$$ 
    1603           \rm /tmp/out_command.$$ 
     1602          cat ${RUN_DIR_PATH}/out_command.$$ 
     1603          \rm ${RUN_DIR_PATH}/out_command.$$ 
    16041604          IGCM_debug_Exit "IGCM_sys_GetBuffer" 
    16051605        else 
    1606           \rm /tmp/out_command.$$ 
     1606          \rm ${RUN_DIR_PATH}/out_command.$$ 
    16071607        fi 
    16081608      done 
     
    16101610      i=0 
    16111611      while [ $i -lt $NB_ESSAI ] ; do 
    1612         \cp ${buf_liste} ${DEST} >> /tmp/out_command.$$ 2>&1 
     1612        \cp ${buf_liste} ${DEST} >> ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    16131613        status=$? 
    16141614        if [ ${status} -gt 0 ]; then 
     
    16231623      if [ ${status} -gt 0 ] ; then 
    16241624        echo "IGCM_sys_Get : error" 
    1625         cat /tmp/out_command.$$ 
    1626         \rm /tmp/out_command.$$ 
     1625        cat ${RUN_DIR_PATH}/out_command.$$ 
     1626        \rm ${RUN_DIR_PATH}/out_command.$$ 
    16271627        IGCM_debug_Exit "IGCM_sys_GetBuffer" 
    16281628      else 
    1629         \rm /tmp/out_command.$$ 
     1629        \rm ${RUN_DIR_PATH}/out_command.$$ 
    16301630      fi 
    16311631    fi 
     
    17681768  i=0 
    17691769  while [ $i -lt $NB_ESSAI ] ; do 
    1770     /smphome/rech/psl/rpsl035/bin/rebuild -f -o $@ > /tmp/out_command.$$ 2>&1 
     1770    /smphome/rech/psl/rpsl035/bin/rebuild -f -o $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    17711771    status=$? 
    17721772    if [ ${status} -gt 0 ] ; then 
    17731773      IGCM_debug_Print 2 "IGCM_sys_rebuild : error code ${status}" 
    1774       cat /tmp/out_command.$$ 
    1775       \rm /tmp/out_command.$$ 
     1774      cat ${RUN_DIR_PATH}/out_command.$$ 
     1775      \rm ${RUN_DIR_PATH}/out_command.$$ 
    17761776      IGCM_debug_Print 2 "IGCM_sys_rebuild : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    17771777      firstArg=${1} 
     
    17791779      sleep $DELAI 
    17801780    else 
    1781       \rm /tmp/out_command.$$ 
     1781      \rm ${RUN_DIR_PATH}/out_command.$$ 
    17821782      break 
    17831783    fi 
     
    22482248  i=0 
    22492249  while [ $i -lt $NB_ESSAI ] ; do 
    2250     ncap2 -C "$@" > /tmp/out_command.$$ 2>&1 
     2250    ncap2 -C "$@" > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    22512251    status=$? 
    22522252    if [ ${status} -gt 0 ] ; then 
    22532253      IGCM_debug_Print 2 "IGCM_sys_ncap2 : error code ${status}" 
    2254       cat /tmp/out_command.$$ 
    2255       \rm /tmp/out_command.$$ 
     2254      cat ${RUN_DIR_PATH}/out_command.$$ 
     2255      \rm ${RUN_DIR_PATH}/out_command.$$ 
    22562256      IGCM_debug_Print 2 "IGCM_sys_ncap2 : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    22572257      sleep $DELAI 
    22582258    else 
    2259       \rm /tmp/out_command.$$ 
     2259      \rm ${RUN_DIR_PATH}/out_command.$$ 
    22602260      break 
    22612261    fi 
     
    22902290  i=0 
    22912291  while [ $i -lt $NB_ESSAI ] ; do 
    2292     ncatted "$@" > /tmp/out_command.$$ 2>&1 
     2292    ncatted "$@" > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    22932293    status=$? 
    22942294    if [ ${status} -gt 0 ] ; then 
    22952295      IGCM_debug_Print 2 "IGCM_sys_ncatted : error code ${status}" 
    2296       cat /tmp/out_command.$$ 
    2297       \rm /tmp/out_command.$$ 
     2296      cat ${RUN_DIR_PATH}/out_command.$$ 
     2297      \rm ${RUN_DIR_PATH}/out_command.$$ 
    22982298      IGCM_debug_Print 2 "IGCM_sys_ncatted : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    22992299      sleep $DELAI 
    23002300    else 
    2301       \rm /tmp/out_command.$$ 
     2301      \rm ${RUN_DIR_PATH}/out_command.$$ 
    23022302      break 
    23032303    fi 
     
    23322332  i=0 
    23332333  while [ $i -lt $NB_ESSAI ] ; do 
    2334     ncbo -C $@ > /tmp/out_command.$$ 2>&1 
     2334    ncbo -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    23352335    status=$? 
    23362336    if [ ${status} -gt 0 ] ; then 
    23372337      IGCM_debug_Print 2 "IGCM_sys_ncbo : error code ${status}" 
    2338       cat /tmp/out_command.$$ 
    2339       \rm /tmp/out_command.$$ 
     2338      cat ${RUN_DIR_PATH}/out_command.$$ 
     2339      \rm ${RUN_DIR_PATH}/out_command.$$ 
    23402340      IGCM_debug_Print 2 "IGCM_sys_ncbo : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    23412341      sleep $DELAI 
    23422342    else 
    2343       \rm /tmp/out_command.$$ 
     2343      \rm ${RUN_DIR_PATH}/out_command.$$ 
    23442344      break 
    23452345    fi 
     
    23742374  i=0 
    23752375  while [ $i -lt $NB_ESSAI ] ; do 
    2376     ncdiff -C $@ > /tmp/out_command.$$ 2>&1 
     2376    ncdiff -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    23772377    status=$? 
    23782378    if [ ${status} -gt 0 ] ; then 
    23792379      IGCM_debug_Print 2 "IGCM_sys_ncdiff : error code ${status}" 
    2380       cat /tmp/out_command.$$ 
    2381       \rm /tmp/out_command.$$ 
     2380      cat ${RUN_DIR_PATH}/out_command.$$ 
     2381      \rm ${RUN_DIR_PATH}/out_command.$$ 
    23822382      IGCM_debug_Print 2 "IGCM_sys_ncdiff : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    23832383      sleep $DELAI 
    23842384    else 
    2385       \rm /tmp/out_command.$$ 
     2385      \rm ${RUN_DIR_PATH}/out_command.$$ 
    23862386      break 
    23872387    fi 
     
    24162416  i=0 
    24172417  while [ $i -lt $NB_ESSAI ] ; do 
    2418     ncea -C $@ > /tmp/out_command.$$ 2>&1 
     2418    ncea -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    24192419    status=$? 
    24202420    if [ ${status} -gt 0 ] ; then 
    24212421      IGCM_debug_Print 2 "IGCM_sys_ncea : error code ${status}" 
    2422       cat /tmp/out_command.$$ 
    2423       \rm /tmp/out_command.$$ 
     2422      cat ${RUN_DIR_PATH}/out_command.$$ 
     2423      \rm ${RUN_DIR_PATH}/out_command.$$ 
    24242424      IGCM_debug_Print 2 "IGCM_sys_ncea : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    24252425      sleep $DELAI 
    24262426    else 
    2427       \rm /tmp/out_command.$$ 
     2427      \rm ${RUN_DIR_PATH}/out_command.$$ 
    24282428      break 
    24292429    fi 
     
    24582458  i=0 
    24592459  while [ $i -lt $NB_ESSAI ] ; do 
    2460     ncecat -C $@ > /tmp/out_command.$$ 2>&1 
     2460    ncecat -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    24612461    status=$? 
    24622462    if [ ${status} -gt 0 ] ; then 
    24632463      IGCM_debug_Print 2 "IGCM_sys_ncecat : error code ${status}" 
    2464       cat /tmp/out_command.$$ 
    2465       \rm /tmp/out_command.$$ 
     2464      cat ${RUN_DIR_PATH}/out_command.$$ 
     2465      \rm ${RUN_DIR_PATH}/out_command.$$ 
    24662466      IGCM_debug_Print 2 "IGCM_sys_ncecat : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    24672467      sleep $DELAI 
    24682468    else 
    2469       \rm /tmp/out_command.$$ 
     2469      \rm ${RUN_DIR_PATH}/out_command.$$ 
    24702470      break 
    24712471    fi 
     
    25002500  i=0 
    25012501  while [ $i -lt $NB_ESSAI ] ; do 
    2502     ncflint -C $@ > /tmp/out_command.$$ 2>&1 
     2502    ncflint -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    25032503    status=$? 
    25042504    if [ ${status} -gt 0 ] ; then 
    25052505      IGCM_debug_Print 2 "IGCM_sys_ncflint : error code ${status}" 
    2506       cat /tmp/out_command.$$ 
    2507       \rm /tmp/out_command.$$ 
     2506      cat ${RUN_DIR_PATH}/out_command.$$ 
     2507      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25082508      IGCM_debug_Print 2 "IGCM_sys_ncflint : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    25092509      sleep $DELAI 
    25102510    else 
    2511       \rm /tmp/out_command.$$ 
     2511      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25122512      break 
    25132513    fi 
     
    25422542  i=0 
    25432543  while [ $i -lt $NB_ESSAI ] ; do 
    2544     ncks -C $@ > /tmp/out_command.$$ 2>&1 
     2544    ncks -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    25452545    status=$? 
    25462546    if [ ${status} -gt 0 ] ; then 
    25472547      IGCM_debug_Print 2 "IGCM_sys_ncks : error code ${status}" 
    2548       cat /tmp/out_command.$$ 
    2549       \rm /tmp/out_command.$$ 
     2548      cat ${RUN_DIR_PATH}/out_command.$$ 
     2549      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25502550      IGCM_debug_Print 2 "IGCM_sys_ncks : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    25512551      sleep $DELAI 
    25522552    else 
    2553       \rm /tmp/out_command.$$ 
     2553      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25542554      break 
    25552555    fi 
     
    25842584  i=0 
    25852585  while [ $i -lt $NB_ESSAI ] ; do 
    2586     ncpdq -C $@ > /tmp/out_command.$$ 2>&1 
     2586    ncpdq -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    25872587    status=$? 
    25882588    if [ ${status} -gt 0 ] ; then 
    25892589      IGCM_debug_Print 2 "IGCM_sys_ncpdq : error code ${status}" 
    2590       cat /tmp/out_command.$$ 
    2591       \rm /tmp/out_command.$$ 
     2590      cat ${RUN_DIR_PATH}/out_command.$$ 
     2591      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25922592      IGCM_debug_Print 2 "IGCM_sys_ncpdq : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    25932593      sleep $DELAI 
    25942594    else 
    2595       \rm /tmp/out_command.$$ 
     2595      \rm ${RUN_DIR_PATH}/out_command.$$ 
    25962596      break 
    25972597    fi 
     
    26262626  i=0 
    26272627  while [ $i -lt $NB_ESSAI ] ; do 
    2628     ncra -C $@ > /tmp/out_command.$$ 2>&1 
     2628    ncra -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    26292629    status=$? 
    26302630    if [ ${status} -gt 0 ] ; then 
    26312631      IGCM_debug_Print 2 "IGCM_sys_ncra : error code ${status}" 
    2632       cat /tmp/out_command.$$ 
    2633       \rm /tmp/out_command.$$ 
     2632      cat ${RUN_DIR_PATH}/out_command.$$ 
     2633      \rm ${RUN_DIR_PATH}/out_command.$$ 
    26342634      IGCM_debug_Print 2 "IGCM_sys_ncra : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    26352635      sleep $DELAI 
    26362636    else 
    2637       \rm /tmp/out_command.$$ 
     2637      \rm ${RUN_DIR_PATH}/out_command.$$ 
    26382638      break 
    26392639    fi 
     
    26682668  i=0 
    26692669  while [ $i -lt $NB_ESSAI ] ; do 
    2670     ncrcat -C $@ > /tmp/out_command.$$ 2>&1 
     2670    ncrcat -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    26712671    status=$? 
    26722672    if [ ${status} -gt 0 ] ; then 
    26732673      IGCM_debug_Print 2 "IGCM_sys_ncrcat : error code ${status}" 
    2674       cat /tmp/out_command.$$ 
    2675       \rm /tmp/out_command.$$ 
     2674      cat ${RUN_DIR_PATH}/out_command.$$ 
     2675      \rm ${RUN_DIR_PATH}/out_command.$$ 
    26762676      IGCM_debug_Print 2 "IGCM_sys_ncrcat : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    26772677      sleep $DELAI 
    2678     elif [ ! "X$( grep "WARNING Intra-file non-monotonicity" /tmp/out_command.$$ )" = "X" ] ; then 
     2678    elif [ ! "X$( grep "WARNING Intra-file non-monotonicity" ${RUN_DIR_PATH}/out_command.$$ )" = "X" ] ; then 
    26792679      IGCM_debug_Print 2 "IGCM_sys_ncrcat : WARNING Intra-file non-monotonicity" 
    2680       cat /tmp/out_command.$$ 
     2680      cat ${RUN_DIR_PATH}/out_command.$$ 
    26812681      # remove files having corrupted time axis 
    26822682      eval lastArg=\${$#} 
    26832683      IGCM_debug_Print 2 "IGCM_sys_ncrcat : Delete ${lastArg}" 
    26842684      \rm ${lastArg} 
    2685       \rm /tmp/out_command.$$ 
     2685      \rm ${RUN_DIR_PATH}/out_command.$$ 
    26862686      IGCM_debug_Print 2 "IGCM_sys_ncrcat : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    26872687      sleep $DELAI 
    26882688    else 
    2689       \rm /tmp/out_command.$$ 
     2689      \rm ${RUN_DIR_PATH}/out_command.$$ 
    26902690      break 
    26912691    fi 
     
    27202720  i=0 
    27212721  while [ $i -lt $NB_ESSAI ] ; do 
    2722     ncrename $@ > /tmp/out_command.$$ 2>&1 
     2722    ncrename $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    27232723    status=$? 
    27242724    if [ ${status} -gt 0 ] ; then 
    27252725      IGCM_debug_Print 2 "IGCM_sys_ncrename : error code ${status}" 
    2726       cat /tmp/out_command.$$ 
    2727       \rm /tmp/out_command.$$ 
     2726      cat ${RUN_DIR_PATH}/out_command.$$ 
     2727      \rm ${RUN_DIR_PATH}/out_command.$$ 
    27282728      IGCM_debug_Print 2 "IGCM_sys_ncrename : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    27292729      sleep $DELAI 
    27302730    else 
    2731       \rm /tmp/out_command.$$ 
     2731      \rm ${RUN_DIR_PATH}/out_command.$$ 
    27322732      break 
    27332733    fi 
     
    27622762  i=0 
    27632763  while [ $i -lt $NB_ESSAI ] ; do 
    2764     ncwa -C $@ > /tmp/out_command.$$ 2>&1 
     2764    ncwa -C $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    27652765    status=$? 
    27662766    if [ ${status} -gt 0 ] ; then 
    27672767      IGCM_debug_Print 2 "IGCM_sys_ncwa : error code ${status}" 
    2768       cat /tmp/out_command.$$ 
    2769       \rm /tmp/out_command.$$ 
     2768      cat ${RUN_DIR_PATH}/out_command.$$ 
     2769      \rm ${RUN_DIR_PATH}/out_command.$$ 
    27702770      IGCM_debug_Print 2 "IGCM_sys_ncwa : ${i}/${NB_ESSAI} sleep ${DELAI} seconds and try again." 
    27712771      sleep $DELAI 
    27722772    else 
    2773       \rm /tmp/out_command.$$ 
     2773      \rm ${RUN_DIR_PATH}/out_command.$$ 
    27742774      break 
    27752775    fi 
     
    28012801  typeset status 
    28022802 
    2803   \cdo $@ > /tmp/out_command.$$ 2>&1 
     2803  \cdo $@ > ${RUN_DIR_PATH}/out_command.$$ 2>&1 
    28042804  status=$? 
    28052805  if [ ${status} -gt 0 ] ; then 
    28062806    echo "IGCM_sys_cdo : error code ${status}" 
    2807     cat /tmp/out_command.$$ 
    2808     \rm /tmp/out_command.$$ 
     2807    cat ${RUN_DIR_PATH}/out_command.$$ 
     2808    \rm ${RUN_DIR_PATH}/out_command.$$ 
    28092809    IGCM_debug_PopStack "IGCM_sys_cdo" 
    28102810    return 1 
Note: See TracChangeset for help on using the changeset viewer.