source: TOOLS/SYNCHRO_SCRIPTS/synchro_igcmg_to_scratch_occigen @ 4292

Last change on this file since 4292 was 4093, checked in by acosce, 6 years ago

sauvegarde des scripts permettant la synchronisation des donnees inter centres

File size: 1.3 KB
Line 
1CINES_LOGIN_DEFAULT=foujols
2CINES_LOGIN=${1:-${CINES_LOGIN_DEFAULT}}
3echo CINES_LOGIN : ${CINES_LOGIN}
4
5cd /ccc/work/cont003/igcmg/igcmg
6echo "Verification des droits des repertoires TGCC"
7ccc_shspace_chmod userread /ccc/work/cont003/igcmg/igcmg/IGCM
8is_problem=` ccc_shspace_modck IGCM |grep ccc_shspace_chmod |wc -l`
9if [ "x${is_problem}" != "x0" ]
10then
11  echo "Il y a un probleme de droit sur un repertoire qui ne vous appartient pas"
12  echo "vous pouvez utiliser la commande ccc_shspace_modck IGCM pour savoir qui doit mettre a jour les droits"
13  echo -n "voulez-vous tout de meme continuer la synchronisation [oui/non]"
14  read reponse
15  case ${reponse} in
16  non|NON|N|n)
17  exit
18  ;;
19esac
20fi
21
22
23cd /ccc/work/cont003/igcmg/igcmg
24echo " Resultat du rsync en dry-run : "
25echo ""
26echo rsync -n -vrltgoD --progress --delete  IGCM ${CINES_LOGIN}@occigen.cines.fr:/scratch/cnt0024/ips2078/SHARED
27rsync -n -vrltgoD --progress --delete  IGCM ${CINES_LOGIN}@occigen.cines.fr:/scratch/cnt0024/ips2078/SHARED
28
29echo "Voulez vous effectuer les actions listees ci dessus oui/non ?"
30echo -n " Votre reponse : "
31read reponse
32
33case ${reponse} in
34
35oui|OUI|o)
36rsync -vrltgoD --progress --chmod=u-w --chmod=g-w --chmod=o-w  --delete IGCM ${CINES_LOGIN}@occigen.cines.fr:/scratch/cnt0024/ips2078/SHARED
37;;
38non|NON|n)
39echo "RIEN A FAIRE !"
40;;
41*)
42echo "Reponse non reconnue"
43;;
44esac
45
Note: See TracBrowser for help on using the repository browser.