Changeset 708


Ignore:
Timestamp:
09/27/12 15:39:06 (12 years ago)
Author:
sdipsl
Message:
  • More adjustement to bypass some curie filesystem issue. #78 and #75
File:
1 edited

Legend:

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

    r702 r708  
    10091009#    fi 
    10101010 
    1011     typeset RET 
     1011    typeset NB_ESSAI DELAI status i 
     1012    # number of tentative 
     1013    NB_ESSAI=3 
     1014    # time delay between tentative 
     1015    DELAI=2 
    10121016 
    10131017    # Only if we use rsync 
    10141018    #IGCM_sys_TestDirArchive $( dirname $2 ) 
    10151019    # 
    1016     #USUAL WAY 
    1017     # add get (to demigrate all offline files) to reduce time of this command : 
     1020    # USUAL WAY 
     1021    # add 'ccc_hsm get' (to demigrate all offline files) to reduce time of this command : 
    10181022    ccc_hsm get $1/* 
    1019     \cp -r $1 $2 > out_rsync 2>&1 
    1020     RET=$? 
    1021  
    1022     if [ ${RET} -gt 0 ] ; then 
     1023 
     1024    while [ $i -lt $NB_ESSAI ] ; do 
     1025      \cp -ur $1 $2 >> out_rsync 2>&1 
     1026      status=$? 
     1027      if [ ${status} -gt 0 ]; then 
     1028        IGCM_debug_Print 2 "IGCM_sys_Get_Dir : cp failed ${i}/${NB_ESSAI}" 
     1029        IGCM_debug_Print 2 "IGCM_sys_Get_Dir : sleep ${DELAI} seconds and try again." 
     1030        sleep $DELAI 
     1031      else 
     1032        break 
     1033      fi 
     1034      (( i = i + 1 )) 
     1035    done 
     1036 
     1037    if [ ${status} -gt 0 ] ; then 
    10231038      echo "IGCM_sys_Get_Dir : error." 
    10241039      cat out_rsync 
     
    10501065    fi 
    10511066 
    1052     typeset RET 
    1053  
    1054     #USUAL WAY 
    1055     \cp -rL $1 $2 > out_rsync 2>&1 
    1056     RET=$? 
    1057  
    1058     if [ ${RET} -gt 0 ] ; then 
     1067    typeset NB_ESSAI DELAI status i 
     1068    # number of tentative 
     1069    NB_ESSAI=3 
     1070    # time delay between tentative 
     1071    DELAI=2 
     1072 
     1073    while [ $i -lt $NB_ESSAI ] ; do 
     1074      \cp -urL $1 $2 > out_rsync 2>&1 
     1075      status=$? 
     1076      if [ ${status} -gt 0 ]; then 
     1077        IGCM_debug_Print 2 "IGCM_sys_Get_Master : cp failed ${i}/${NB_ESSAI}" 
     1078        IGCM_debug_Print 2 "IGCM_sys_Get_Master : sleep ${DELAI} seconds and try again." 
     1079        sleep $DELAI 
     1080      else 
     1081        break 
     1082      fi 
     1083      (( i = i + 1 )) 
     1084    done 
     1085 
     1086    if [ ${status} -gt 0 ] ; then 
    10591087      echo "IGCM_sys_Get_Master : error." 
    10601088      cat out_rsync 
Note: See TracChangeset for help on using the changeset viewer.