source: trunk/libIGCM/libIGCM_sys/libIGCM_sys_default.ksh @ 98

Last change on this file since 98 was 98, checked in by sdipsl, 15 years ago
  • Try to avoid having stack files every where during post-processing job.
  • Property licence set to
    The following licence information concerns ONLY the libIGCM tools
    ==================================================================

    Copyright © Centre National de la Recherche Scientifique CNRS
    Commissariat à l'Énergie Atomique CEA

    libIGCM : Library for Portable Models Computation of IGCM Group.

    IGCM Group is the french IPSL Global Climate Model Group.

    This library is a set of shell scripts and functions whose purpose is
    the management of the initialization, the launch, the transfer of
    output files, the post-processing and the monitoring of datas produce
    by any numerical program on any plateforme.

    This software is governed by the CeCILL license under French law and
    abiding by the rules of distribution of free software. You can use,
    modify and/ or redistribute the software under the terms of the CeCILL
    license as circulated by CEA, CNRS and INRIA at the following URL
    "http://www.cecill.info".

    As a counterpart to the access to the source code and rights to copy,
    modify and redistribute granted by the license, users are provided only
    with a limited warranty and the software's author, the holder of the
    economic rights, and the successive licensors have only limited
    liability.

    In this respect, the user's attention is drawn to the risks associated
    with loading, using, modifying and/or developing or reproducing the
    software by the user in light of its specific status of free software,
    that may mean that it is complicated to manipulate, and that also
    therefore means that it is reserved for developers and experienced
    professionals having in-depth computer knowledge. Users are therefore
    encouraged to load and test the software's suitability as regards their
    requirements in conditions enabling the security of their systems and/or
    data to be ensured and, more generally, to use and operate it in the
    same conditions as regards security.

    The fact that you are presently reading this means that you have had
    knowledge of the CeCILL license and that you accept its terms.
  • Property svn:keywords set to Date Author Revision
File size: 33.3 KB
Line 
1#!/bin/ksh
2
3#**************************************************************
4# Author: Sebastien Denvil, Martial Mancip
5# Contact: Martial.Mancip_ipsl.jussieu.fr
6# $Date$
7# $Author$
8# $Revision$
9# IPSL (2006)
10#  This software is governed by the CeCILL licence see libIGCM/libIGCM_CeCILL.LIC
11# History:
12# Modification:
13#
14#**************************************************************
15
16#=========================================================
17# The documentation of this file can be automatically generated
18# if you use the prefix #D- for comments to be extracted.
19# Extract with command: cat lib* | grep "^#D-" | cut -c "4-"
20#=========================================================
21 
22#D-#==================================================
23#D-LibIGCM_sys Default host
24#D-#==================================================
25#D-
26#D- This ksh library if a layer under some usefull
27#D- environment variables and shell commands.
28#D- All those definitions depend on host particularities.
29#D- It manages a stack mechanism and test validity of operations.
30#D- All function described bellow must be prefixed by IGCM_sys.
31
32#====================================================
33# libIGCM_sys PARAMETERS
34#====================================================
35
36#=====================================================
37#set DEBUG_sys to true to output calls of function
38typeset -r DEBUG_sys=${DEBUG_sys:=true}
39
40#=====================================================
41# Turn in dry run mode ? (sys_Put_Rest, sys_Put_Out, sys_Get)
42typeset -r DRYRUN=${DRYRUN:=0}
43
44# YOU MUST COMPILE YOUR EXE FILES FOR DRYRUN MODE !
45# -------------------------------------------------------------------------------------
46# | DRYRUN=  |  Date computations, | sys_Get    |  Exe    | sys_Put_Out; sys_Put_Rest |
47# |          |  Cp/Exe param files |            |  Chmod  |                           |
48# |          |      Qsub           |            |         |                           |
49# -------------------------------------------------------------------------------------
50# |    0     |       yes           |    yes     |  yes    |      yes                  |
51# -------------------------------------------------------------------------------------
52# |    1     |       yes           |    yes     |  yes    |      no                   |
53# -------------------------------------------------------------------------------------
54# |    2     |       yes           |    yes     |  no     |      no                   |
55# -------------------------------------------------------------------------------------
56# |    3     |       yes           |    no      |  no     |      no                   |
57# -------------------------------------------------------------------------------------
58
59#=====================================================
60#Global Variables :
61#=====================================================
62# Language : "fr" or "en"
63typeset -r MYLANG="fr"
64
65#=====================================================
66# Host and user names
67# $hostname ou hostname
68typeset -r HOST=$( hostname )
69# $username ou whoami
70typeset -r LOGIN=$( whoami )
71# $hostname of the MASTER job
72typeset -r MASTER=${HOST}
73
74#D-
75#D-#==================================================
76#D-Program used in libIGCM
77#D-#==================================================
78
79# rsync with path
80typeset -r RSYNC=/usr/bin/rsync 
81#RSYNC_opt args to rsync
82typeset -r RSYNC_opt="-Lt -v"
83
84#====================================================
85# Source Ferret
86. /home/${LOGIN}/.atlas_env_${HOST}_ksh
87
88#=========================================================
89# Host specific DIRECTORIES
90#====================================================
91
92#====================================================
93#- R_EXE   (==> BIN_DIR = ${MODIPSL}/bin )
94typeset -r R_EXE="${MODIPSL}/bin"
95
96#====================================================
97#- SCRATCHDIR (=> ${R_DONNEES})
98typeset -r SCRATCHDIR=/tmp
99
100#====================================================
101#- SUBMIT_DIR : submission dir
102typeset SUBMIT_DIR=${SUBMIT_DIR:=${PWD}}
103
104#====================================================
105#- ARCHIVE
106typeset -r ARCHIVE=/home
107
108#====================================================
109#- libIGCM_POST
110typeset -r libIGCM_POST=${libIGCM}
111
112#====================================================
113#- IN
114typeset -r R_IN=${R_IN:=${ARCHIVE}/${LOGIN}/IGCM}
115
116#====================================================
117#- OUT
118typeset -r R_OUT=${ARCHIVE}/${LOGIN}/IGCM_OUT
119
120#====================================================
121#- OUT_POST
122typeset -r R_OUT_POST=${R_OUT}
123
124#====================================================
125#- RUN_DIR_PATH : Temporary working directory (=> TMP)
126typeset -r RUN_DIR_PATH=${RUN_DIR_PATH:=${SCRATCHDIR}/tmp$$}
127
128#====================================================
129#- HOST_MPIRUN_COMMAND
130typeset -r HOST_MPIRUN_COMMAND=${HOST_MPIRUN_COMMAND:="time mpirun"}
131
132#=========================================================
133#- Add "time" before mpirun command
134MPIRUN_COMMAND="time "${MPIRUN_COMMAND}
135echo ${MPIRUN_COMMAND}
136
137#====================================================
138#- Max number of arguments passed to nco operator or demigration command
139UNIX_MAX_LIMIT=360
140
141#D-#==================================================
142#D-function IGCM_sys_RshMaster
143#D-* Purpose: Master rsh command
144#D-* Examples:
145#D-
146function IGCM_sys_RshMaster {
147    IGCM_debug_PushStack "IGCM_sys_RshMaster" $@
148    ssh ${HOST} /bin/ksh  <<-EOF
149    export libIGCM=${libIGCM}
150    export DEBUG_debug=${DEBUG_debug}
151    . ${libIGCM}/libIGCM_debug/libIGCM_debug.ksh
152    . ${libIGCM}/libIGCM_card/libIGCM_card.ksh
153    ${@}
154EOF
155    if [ $? -gt 0 ] ; then
156        echo "IGCM_sys_RshMaster : erreur."
157        IGCM_debug_Exit "IGCM_sys_RshMaster"
158    fi
159    IGCM_debug_PopStack "IGCM_sys_RshMaster"
160}
161
162#D-#==================================================
163#D-function IGCM_sys_RshArchive
164#D-* Purpose: Archive rsh command
165#D-* Examples:
166#D-
167function IGCM_sys_RshArchive {
168    IGCM_debug_PushStack "IGCM_sys_RshArchive" $@
169    /bin/ksh  <<-EOF
170    ${@}
171EOF
172    if [ $? -gt 0 ] ; then
173        echo "IGCM_sys_RshArchive : erreur."
174        IGCM_debug_Exit "IGCM_sys_RshArchive"
175    fi
176    IGCM_debug_PopStack "IGCM_sys_RshArchive"
177}
178
179#D-#==================================================
180#D-function IGCM_sys_RshPost
181#D-* Purpose: Master rsh command
182#D-* Examples:
183#D-
184(( RshPNum = 0 ))
185function IGCM_sys_RshPost {
186    IGCM_debug_PushStack "IGCM_sys_RshPost" $@
187    if ( $DEBUG_sys ) ; then
188        echo "IGCM_sys_RshPost :" $@
189    fi
190    #ssh ${HOST} exec /bin/ksh -vx $@ > out_RshPost.${RshPNum}
191    ssh ${HOST} exec /bin/ksh $@ > out_RshPost.${RshPNum}
192    if [ $? -gt 0 ] ; then
193        echo "IGCM_sys_RshPost : erreur."
194        IGCM_debug_Exit "IGCM_sys_RshPost"
195    fi
196    (( RshPNum = RshPNum + 1 ))
197    IGCM_debug_PopStack "IGCM_sys_RshPost"
198}
199
200#D-#==================================================
201#D-function IGCM_sys_Mkdir
202#D-* Purpose: Master locale mkdir command
203#D-* Examples:
204#D-
205function IGCM_sys_Mkdir {
206    IGCM_debug_PushStack "IGCM_sys_Mkdir" $@
207    if ( $DEBUG_sys ) ; then
208        echo "IGCM_sys_Mkdir :" $@
209    fi
210    if [ ! -d ${1} ]; then
211        \mkdir -p $1
212        if [ $? -gt 0 ] ; then
213            echo "IGCM_sys_Mkdir : erreur."
214            IGCM_debug_Exit "IGCM_sys_Mkdir"
215        fi
216    fi
217    # vérification :
218    if [ ! -d ${1} ] ; then
219        echo "IGCM_sys_Mkdir : erreur."
220        IGCM_debug_Exit "IGCM_sys_Mkdir"
221    fi
222    IGCM_debug_PopStack "IGCM_sys_Mkdir"
223}
224
225#D-#==================================================
226#D-function IGCM_sys_MkdirArchive
227#D-* Purpose: Mkdir on Archive
228#D-* Examples:
229#D-
230function IGCM_sys_MkdirArchive {
231    IGCM_debug_PushStack "IGCM_sys_MkdirArchive" $@
232    if ( $DEBUG_sys ) ; then
233        echo "IGCM_sys_MkdirArchive :" $@
234    fi
235    #- creation de repertoire sur le serveur fichier
236    if [ ! -d ${1} ]; then 
237        \mkdir -p $1
238        if [ $? -gt 0 ] ; then
239            echo "IGCM_sys_MkdirArchive : erreur."
240            IGCM_debug_Exit "IGCM_sys_MkdirArchive"
241        fi
242    fi
243    # vérification ?? :
244    if [ ! -d ${1} ] ; then
245        echo "IGCM_sys_MkdirArchive : erreur."
246        IGCM_debug_Exit "IGCM_sys_MkdirArchive"
247    fi
248    IGCM_debug_PopStack "IGCM_sys_MkdirArchive"
249}
250
251#D-#==================================================
252#D-function IGCM_sys_MkdirWork
253#D-* Purpose: Mkdir on Work
254#D-* Examples:
255#D-
256function IGCM_sys_MkdirWork {
257    IGCM_debug_PushStack "IGCM_sys_MkdirWork" $@
258    if ( $DEBUG_sys ) ; then
259        echo "IGCM_sys_MkdirWork :" $@
260    fi
261    #- creation de repertoire sur le serveur fichier
262    if [ ! -d ${1} ]; then 
263        \mkdir -p $1
264        if [ $? -gt 0 ] ; then
265            echo "IGCM_sys_MkdirWork : erreur."
266            IGCM_debug_Exit "IGCM_sys_MkdirWork"
267        fi
268    fi
269    # vérification ?? :
270    if [ ! -d ${1} ] ; then
271        echo "IGCM_sys_MkdirWork : erreur."
272        IGCM_debug_Exit "IGCM_sys_MkdirWork"
273    fi
274    IGCM_debug_PopStack "IGCM_sys_MkdirWork"
275}
276IGCM_sys_MkdirWork ${RUN_DIR_PATH}
277echo "RUN_DIR_PATH ${RUN_DIR_PATH} ok."
278
279#D-#==================================================
280#D-function IGCM_sys_Cd
281#D-* Purpose: master cd command
282#D-* Examples:
283#D-
284function IGCM_sys_Cd {
285    IGCM_debug_PushStack "IGCM_sys_Cd" $@
286    if ( $DEBUG_sys ) ; then
287        echo "IGCM_sys_Cd :" $@
288    fi
289    \cd $1
290    if [ $? -gt 0 ] ; then
291        echo "IGCM_sys_Cd : erreur."
292        IGCM_debug_Exit "IGCM_sys_Cd"
293    fi
294    IGCM_debug_PopStack "IGCM_sys_Cd"
295}
296
297#D-#==================================================
298#D-function IGCM_sys_Chmod
299#D-* Purpose: Chmod
300#D-* Examples:
301#D-
302function IGCM_sys_Chmod {
303    IGCM_debug_PushStack "IGCM_sys_Chmod" $@
304    if ( $DEBUG_sys ) ; then
305        echo "IGCM_sys_Chmod :" $@
306    fi
307    if [ $DRYRUN -le 1 ]; then
308        \chmod $@
309        if [ $? -gt 0 ] ; then
310            echo "IGCM_sys_Chmod : erreur."
311            IGCM_debug_Exit "IGCM_sys_Chmod"
312        fi
313    else
314        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
315    fi
316    IGCM_debug_PopStack "IGCM_sys_Chmod"
317}
318
319#D-#==================================================
320#D-function IGCM_sys_FileSize
321#D-* Purpose: Filesize
322#D-* Examples:
323#D-
324function IGCM_sys_FileSize {
325    IGCM_debug_PushStack "IGCM_sys_FileSize" $@
326
327    typeset sizeF
328    set +A sizeF -- $( ls -la ${1} )
329    if [ $? -gt 0 ] ; then
330        IGCM_debug_Exit "IGCM_sys_FileSize"
331    fi
332    eval ${2}=${sizeF[4]}
333
334    IGCM_debug_PopStack "IGCM_sys_FileSize"
335}
336
337#D-#==================================================
338#D-function IGCM_sys_TestDir
339#D-* Purpose: Test Directory that must exists
340#D-* Examples:
341#D-
342function IGCM_sys_TestDir {
343    IGCM_debug_PushStack "IGCM_sys_TestDir" $@
344    if ( $DEBUG_sys ) ; then
345        echo "IGCM_sys_TestDir :" $@
346    fi
347    typeset ExistFlag
348    ExistFlag=$( [ -d $1 ] && echo 0 || echo 1 )
349    IGCM_debug_PopStack "IGCM_sys_TestDir"
350
351    return ${ExistFlag}
352}
353
354#D-#==================================================
355#D-function IGCM_sys_TestDirArchive
356#D-* Purpose: Test Directory that must exists on Archive
357#D-* Examples:
358#D-
359function IGCM_sys_TestDirArchive {
360    IGCM_debug_PushStack "IGCM_sys_TestDirArchive" $@
361    if ( $DEBUG_sys ) ; then
362        echo "IGCM_sys_TestDirArchive :" $@
363    fi
364    typeset ExistFlag
365    ExistFlag=$( [ -d $1 ] && echo 0 || echo 1 )
366    IGCM_debug_PopStack "IGCM_sys_TestDirArchive"
367
368    return ${ExistFlag}
369}
370
371#D-#==================================================
372#D-function IGCM_sys_TestFileArchive
373#D-* Purpose: Test file that must NOT EXISTS on Archive
374#D-* Examples:
375#D-
376function IGCM_sys_TestFileArchive {
377    IGCM_debug_PushStack "IGCM_sys_TestFileArchive" $@
378    if ( $DEBUG_sys ) ; then
379        echo "IGCM_sys_TestFileArchive :" $@
380    fi
381    typeset ExistFlag
382    ExistFlag=$( [ -f $1 ] && echo 0 || echo 1 )
383    IGCM_debug_PopStack "IGCM_sys_TestFileArchive"
384
385    return ${ExistFlag}
386}
387
388#D-#==================================================
389#D-function IGCM_sys_CountFileArchive
390#D-* Purpose: Count files on Archive filesystem
391#D-* Examples:
392#D-
393function IGCM_sys_CountFileArchive {
394    IGCM_debug_PushStack "IGCM_sys_CountFileArchive" $@
395    ls ${@} 2>/dev/null | wc -l
396    if [ $? -gt 0 ] ; then
397        echo "IGCM_sys_CountFileArchive : erreur."
398    fi
399    IGCM_debug_PopStack "IGCM_sys_CountFileArchive"
400}
401
402#D-#==================================================
403#D-function IGCM_sys_Tree
404#D-* Purpose: Tree directories with files on ${ARCHIVE}
405#D-* Examples: IGCM_sys_Tree ${R_IN} ${R_OUT}
406#D-
407function IGCM_sys_Tree {
408    IGCM_debug_PushStack "IGCM_sys_Tree" $@
409    if ( $DEBUG_sys ) ; then
410        echo "IGCM_sys_Tree :" $@
411    fi
412
413    \tree -f $@
414
415    IGCM_debug_PopStack "IGCM_sys_Tree"
416}
417
418#D-#==================================================
419#D-function IGCM_sys_Tar
420#D-* Purpose: master un-tar command
421#D-* Examples:
422#D-
423function IGCM_sys_Tar {
424    IGCM_debug_PushStack "IGCM_sys_Tar" $@
425    if ( $DEBUG_sys ) ; then
426        echo "IGCM_sys_Tar :" $@
427    fi
428    \tar cvf $@
429    if [ $? -gt 0 ] ; then
430        echo "IGCM_sys_Tar : erreur."
431        IGCM_debug_Exit "IGCM_sys_Tar"
432    fi
433    \tar tvf $1
434
435    IGCM_debug_PopStack "IGCM_sys_Tar"
436}
437
438#D-#==================================================
439#D-function IGCM_sys_UnTar
440#D-* Purpose: master un-tar command
441#D-* Examples:
442#D-
443function IGCM_sys_UnTar {
444    IGCM_debug_PushStack "IGCM_sys_UnTar" $@
445    if ( $DEBUG_sys ) ; then
446        echo "IGCM_sys_UnTar :" $@
447    fi
448    \tar xvf $1
449    if [ $? -gt 0 ] ; then
450        echo "IGCM_sys_UnTar : erreur."
451        IGCM_debug_Exit "IGCM_sys_UnTar"
452    fi
453    IGCM_debug_PopStack "IGCM_sys_UnTar"
454}
455
456#D-#==================================================
457#D-function IGCM_sys_Qsub
458#D-* Purpose: Qsub new job
459#D-* Examples:
460#D-
461function IGCM_sys_Qsub {
462    IGCM_debug_PushStack "IGCM_sys_Qsub" $@
463    if ( $DEBUG_sys ) ; then
464        echo "IGCM_sys_Qsub :" $@
465    fi
466    echo "ssh -l ${LOGIN} ${HOST} ""cd ${SUBMIT_DIR} ; ${@}"" > ${Script_Output} 2>&1 &"
467    ssh -l ${LOGIN} ${HOST} "cd ${SUBMIT_DIR} ; ${@}" > ${Script_Output} 2>&1 &
468    if [ $? -gt 0 ] ; then
469        echo "IGCM_sys_Qsub : erreur."
470        IGCM_debug_Exit "IGCM_sys_Qsub"
471    fi
472    IGCM_debug_PopStack "IGCM_sys_Qsub"
473}
474
475#D-#==================================================
476#D-function IGCM_sys_QsubPost
477#D-* Purpose: Qsub new job on scalaire
478#D-* Examples:
479#D-
480function IGCM_sys_QsubPost {
481    IGCM_debug_PushStack "IGCM_sys_QsubPost" $@
482    if ( $DEBUG_sys ) ; then
483        echo "IGCM_sys_QsubPost :" $@
484    fi
485    #echo "ssh -x -l ${LOGIN} ${HOST} ${3} > ${2} 2>&1 &"
486    #    ssh -x -l ${LOGIN} ${HOST}
487    echo "${3} > ${2} 2>&1 &"
488    ${3} > ${2} 2>&1 &
489    if [ $? -gt 0 ] ; then
490        echo "IGCM_sys_QsubPost : erreur."
491        IGCM_debug_Exit "IGCM_sys_QsubPost"
492    fi
493    IGCM_debug_PopStack "IGCM_sys_QsubPost"
494}
495
496#D-*************************
497#D- File transfer functions
498#D-*************************
499#D-
500
501#D-#==================================================
502#D-function IGCM_sys_Rsync_out
503#D-* Purpose: treat return val of rsync
504#D-* Examples:  IGCM_sys_Rsync_out out_RET_rsync
505#D-  Error values and explanations can depend on your system version.
506function IGCM_sys_Rsync_out {
507    RET=$1
508    if [ ! $RET ] ; then
509        echo "rsync error !"
510    fi
511
512    if [ $MYLANG = "fr" ]; then
513        case $RET in
514            0)  return ;;
515            1)  echo "Erreur de rsync ; RERR_SYNTAX : "
516                echo "Erreur de syntaxe ou d'utilisation."
517                return;;
518            2)  echo "Erreur de rsync ; RERR_PROTOCOL : "
519                echo "Incompatibilité de protocole."
520                return;;
521            3)  echo "Erreur de rsync ; RERR_FILESELECT 3"
522                echo "Erreurs  lors  de  la  sélection des fichiers d'entrée sortie et"
523                echo "répertoires"
524                return;;
525            4)  echo "Erreur de rsync ; RERR_UNSUPPORTED"
526                echo "Action demandée non supportée : une tentative de manipulation de"
527                echo "fichiers  64-bits  sur une plate-forme qui ne les supporte pas a"
528                echo "été faite ; ou une option qui est supportée par le  client  mais"
529                echo "pas par le serveur a été spécifiée."
530                return;;
531            10) echo "Erreur de rsync ; RERR_SOCKETIO"
532                echo "Erreur dans le socket d'entrée sortie"
533                return;;
534            11) echo "Erreur de rsync ; RERR_FILEIO"
535                echo "Erreur d'entrée sortie fichier"
536                return;;
537            12) echo "Erreur de rsync ; RERR_STREAMIO"
538                echo "Erreur dans flux de donnée du protocole rsync"
539                return;;
540            13) echo "Erreur de rsync ; RERR_MESSAGEIO"
541                echo "Erreur avec les diagnostics du programme"
542                return;;
543            14) echo "Erreur de rsync ; RERR_IPC"
544                echo "Erreur dans le code IPC"
545                return;;
546            20) echo "Erreur de rsync ; RERR_SIGNAL"
547                echo "SIGUSR1 ou SIGINT reçu"
548                return;;
549            21) echo "Erreur de rsync ; RERR_WAITCHILD"
550                echo "Une erreur retournée par waitpid()"
551                return;;
552            22) echo "Erreur de rsync ; RERR_MALLOC"
553                echo "Erreur lors de l'allocation des tampons de mémoire de coeur"
554                return;;
555            23) echo ""
556                echo "Erreur fichier inexistant"
557                return;;
558            30) echo "Erreur de rsync ; RERR_TIMEOUT"
559                echo "Temps d'attente écoulé dans l'envoi/réception de données"
560                return;;
561            *)  echo "Erreur de rsync : code de retour de rsync inconnu :" $RET
562                return;;
563        esac
564    elif [ $MYLANG = "en" ] ; then
565        case $RET in
566            0)  return;;               
567            1)  echo "rsync error : Syntax or usage error "
568                return;;
569            2)  echo "rsync error : Protocol incompatibility "
570                return;;
571            3)  echo "rsync error : Errors selecting input/output files, dirs"
572                return;;
573            4)  echo "rsync error : Requested action not supported: an attempt"
574                echo "was made to manipulate 64-bit files on a platform that cannot support"
575                echo "them; or an option was specified that is supported by the client and"
576                echo "not by the server."
577                return;;
578            5)  echo "rsync error : Error starting client-server protocol"
579                return;;
580            10) echo "rsync error : Error in socket I/O "
581                return;;
582            11) echo "rsync error : Error in file I/O "
583                return;;
584            12) echo "rsync error : Error in rsync protocol data stream "
585                return;;
586            13) echo "rsync error : Errors with program diagnostics "
587                return;;
588            14) echo "rsync error : Error in IPC code "
589                return;;
590            20) echo "rsync error : Received SIGUSR1 or SIGINT "
591                return;;
592            21) echo "rsync error : Some error returned by waitpid() "
593                return;;
594            22) echo "rsync error : Error allocating core memory buffers "
595                return;;
596            23) echo "rsync error : Partial transfer due to error"
597                return;;
598            24) echo "rsync error : Partial transfer due to vanished source files"
599                return;;
600            30) echo "rsync error : Timeout in data send/receive "
601                return;;
602            *)  echo "rsync error : return code of rsync unknown :" $RET
603                return;;
604        esac
605    else
606        echo "unknown language $MYLANG."
607        return
608    fi
609}
610   
611#D-#==================================================
612#D-function IGCM_sys_Cp
613#D-* Purpose: generic cp
614#D-* Examples:
615#D-
616function IGCM_sys_Cp {
617    IGCM_debug_PushStack "IGCM_sys_Cp" $@
618    if ( $DEBUG_sys ) ; then
619        echo "IGCM_sys_Cp :" $@
620    fi
621
622    typeset RET
623
624    echo cp --preserve=timestamps $@ > out_rsync 2>&1
625    \cp --preserve=timestamps $@ >> out_rsync 2>&1
626    RET=$?
627   
628    if [ ${RET} -gt 0 ] ; then
629        echo "IGCM_sys_Cp : error."
630        cat out_rsync
631        IGCM_debug_Exit "IGCM_sys_Cp"
632    fi
633    IGCM_debug_PopStack "IGCM_sys_Cp"
634}
635
636#D-#==================================================
637#D-function IGCM_sys_Rm
638#D-* Purpose: generic rm
639#D-* Examples:
640#D-
641function IGCM_sys_Rm {
642    IGCM_debug_PushStack "IGCM_sys_Rm" $@
643    if ( $DEBUG_sys ) ; then
644        echo "IGCM_sys_Rm :" $@
645    fi
646
647    typeset RET
648
649    echo rm $@ > out_rsync 2>&1
650    \rm $@ >> out_rsync 2>&1
651    RET=$?
652   
653    if [ ${RET} -gt 0 ] ; then
654        echo "IGCM_sys_Rm : error."
655        cat out_rsync
656        IGCM_debug_Exit "IGCM_sys_Rm"
657    fi
658    IGCM_debug_PopStack "IGCM_sys_Rm"
659}
660
661#D-#==================================================
662#D-function IGCM_sys_Mv
663#D-* Purpose: generic move
664#D-* Examples:
665#D-
666function IGCM_sys_Mv {
667    IGCM_debug_PushStack "IGCM_sys_Mv" $@
668    if ( $DEBUG_sys ) ; then
669        echo "IGCM_sys_Mv :" $@
670    fi
671
672    typeset RET
673
674    echo mv $@ > out_rsync 2>&1
675    \mv $@ >> out_rsync 2>&1
676    RET=$?
677   
678    if [ ${RET} -gt 0 ] ; then
679        echo "IGCM_sys_Mv : error in mv."
680        cat out_rsync
681        IGCM_debug_Exit "IGCM_sys_Mv"
682    fi
683
684    IGCM_debug_PopStack "IGCM_sys_Mv"
685}
686
687#D-#==================================================
688#D-function IGCM_sys_Put_Dir
689#D-* Purpose: Copy a complete directory on $(ARCHIVE)
690#D-* Examples:
691#D-
692function IGCM_sys_Put_Dir {
693    IGCM_debug_PushStack "IGCM_sys_Put_Dir" $@
694    if ( $DEBUG_sys ) ; then
695        echo "IGCM_sys_Put_Dir :" $@
696    fi
697    if [ $DRYRUN = 0 ]; then
698        if [ ! -d ${1} ] ; then
699            echo "WARNING : IGCM_sys_Put_Dir ${1} DOES NOT EXIST ."
700            IGCM_debug_PopStack "IGCM_sys_Put_Dir"
701            return
702        fi
703
704        typeset RET
705
706        # Only if we use rsync
707        #IGCM_sys_TestDirArchive $( dirname $2 )
708        #
709        #USUAL WAY
710        \cp -R $1 $2 > out_rsync 2>&1
711        RET=$?
712
713        if [ ${RET} -gt 0 ] ; then
714            echo "IGCM_sys_Put_Dir : error."
715            cat out_rsync
716            IGCM_debug_Exit "IGCM_sys_Put_Dir"
717        fi
718    else
719        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
720    fi
721    IGCM_debug_PopStack "IGCM_sys_Put_Dir"
722}
723
724#D-#==================================================
725#D-function IGCM_sys_Get_Dir
726#D-* Purpose: Copy a complete directory from $(ARCHIVE)
727#D-* Examples:
728#D-
729function IGCM_sys_Get_Dir {
730    IGCM_debug_PushStack "IGCM_sys_Get_Dir" $@
731    if ( $DEBUG_sys ) ; then
732        echo "IGCM_sys_Get_Dir :" $@
733    fi
734    if [ $DRYRUN = 0 ]; then
735        if [ ! -d ${1} ] ; then
736            echo "WARNING : IGCM_sys_Get_Dir ${1} DOES NOT EXIST ."
737            IGCM_debug_PopStack "IGCM_sys_Get_Dir"
738            return
739        fi
740
741        typeset RET
742
743        #USUAL WAY
744        \cp -R $1 $2 > out_rsync 2>&1
745        RET=$?
746
747        if [ ${RET} -gt 0 ] ; then
748            echo "IGCM_sys_Get_Dir : error."
749            cat out_rsync
750            IGCM_debug_Exit "IGCM_sys_Get_Dir"
751        fi
752    else
753        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
754    fi
755    IGCM_debug_PopStack "IGCM_sys_Get_Dir"
756}
757
758#D-#==================================================
759#D-function IGCM_sys_Get_Master
760#D-* Purpose: Copy a complete directory from MASTER filesystem
761#D-* Examples:
762#D-
763function IGCM_sys_Get_Master {
764    IGCM_debug_PushStack "IGCM_sys_Get_Master" $@
765    if ( $DEBUG_sys ) ; then
766        echo "IGCM_sys_Get_Master :" $@
767    fi
768    if [ $DRYRUN = 0 ]; then
769        if [ ! -d ${1} ] ; then
770            echo "WARNING : IGCM_sys_Get_Master ${1} DOES NOT EXIST ."
771            IGCM_debug_PopStack "IGCM_sys_Get_Master"
772            return
773        fi
774
775        typeset RET
776        sleep 60
777
778        #USUAL WAY
779        cp -R $1 $2 > out_rsync 2>&1
780        RET=$?
781
782        if [ ${RET} -gt 0 ] ; then
783            echo "IGCM_sys_Get_Master : error."
784            cat out_rsync
785            IGCM_debug_Exit "IGCM_sys_Get_Master"
786        fi
787    else
788        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
789    fi
790    IGCM_debug_PopStack "IGCM_sys_Get_Master"
791}
792
793#D-#==================================================
794#D-function IGCM_sys_Put_Rest
795#D-* Purpose: commande de transfert des restarts $(ARCHIVE).
796#D-           Quitte si le fichier ou si le répertoire d'arriver n'existe pas.
797#D-* Examples:
798#D-
799function IGCM_sys_Put_Rest {
800    IGCM_debug_PushStack "IGCM_sys_Put_Rest" $@
801    if ( $DEBUG_sys ) ; then
802        echo "IGCM_sys_Put_Rest :" $@
803    fi
804    if [ $DRYRUN = 0 ]; then
805
806        IGCM_sys_TestDirArchive $( dirname $2 )
807
808        if [ ! -f ${1} ] ; then
809            echo "ERROR : IGCM_sys_Put_Rest ${1} DOES NOT EXIST ."
810            IGCM_debug_Exit "IGCM_sys_Put_Rest"
811        fi
812        IGCM_sys_Chmod 444 ${1}
813
814        typeset RET
815
816        echo ${RSYNC} ${RSYNC_opt} $1 $2 > out_rsync 2>&1
817        ${RSYNC} ${RSYNC_opt} $1 $2 >> out_rsync 2>&1
818        RET=$?
819        IGCM_sys_Rsync_out $RET
820
821        ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk out_rsync
822        (( RET=RET+$? ))
823
824        if [ ${RET} -gt 0 ] ; then
825            echo "IGCM_sys_Put_Rest : error."
826            cat out_rsync
827            IGCM_debug_Exit "IGCM_sys_Put_Rest"
828        fi
829    else
830        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
831    fi
832    IGCM_debug_PopStack "IGCM_sys_Put_Rest"
833}
834
835#D-#==================================================
836#D-function IGCM_sys_Put_Out
837#D-* Purpose: Copy a file on $(ARCHIVE) after have chmod it in readonly
838#D-* Examples:
839#D-
840function IGCM_sys_Put_Out {
841    IGCM_debug_PushStack "IGCM_sys_Put_Out" $@
842    if ( $DEBUG_sys ) ; then
843        echo "IGCM_sys_Put_Out :" $@
844    fi
845    if [ $DRYRUN = 0 ]; then
846        if [ -f ${1} ] ; then
847            if [ ! -d $( dirname $2 ) ] ; then
848                IGCM_sys_MkdirArchive $( dirname $2 )
849            fi
850        else
851            echo "WARNING : IGCM_sys_Put_Out ${1} DOES NOT EXIST ."
852            IGCM_debug_PopStack "IGCM_sys_Put_Out"
853            return 1
854        fi
855
856        typeset RET
857        #
858        IGCM_sys_Chmod 444 ${1}
859        #
860
861        echo ${RSYNC} ${RSYNC_opt} $1 $2 > out_rsync 2>&1
862        ${RSYNC} ${RSYNC_opt} $1 $2 >> out_rsync 2>&1
863        RET=$?
864        IGCM_sys_Rsync_out $RET
865
866        ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk out_rsync
867        (( RET=RET+$? ))
868
869        if [ ${RET} -gt 0 ] ; then
870            echo "IGCM_sys_Put_Out : error."
871            cat out_rsync
872            IGCM_debug_Exit "IGCM_sys_Put_Out"
873        fi
874    else
875        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
876    fi
877    IGCM_debug_PopStack "IGCM_sys_Put_Out"
878    return 0
879}
880
881#D-#==================================================
882#D-function IGCM_sys_Get
883#D-* Purpose: Get a file from ${ARCHIVE}
884#D-* Examples: IGCM_sys_Get myfile /destpath/myfile_with_PREFIX
885#D-            IGCM_sys_Get /l Array_contain_myfiles /destpath/
886function IGCM_sys_Get {
887    IGCM_debug_PushStack "IGCM_sys_Get" $@
888
889    typeset DEST RET dm_liste ifile target
890
891    if ( $DEBUG_sys ) ; then
892        echo "IGCM_sys_Get :" $@
893    fi
894    if [ $DRYRUN -le 2 ]; then
895        if [ X${1} = X'/l' ] ; then
896            # test if the first file is present in the old computation :
897            eval set +A dm_liste \${${2}}
898        else
899            dm_liste=${1}
900        fi
901        eval DEST=\${${#}}
902
903        # test if the (first) file is present in the old computation :
904        IGCM_sys_TestFileArchive ${dm_liste[0]}
905        RET=$?
906        if [ ${RET} -gt 0 ] ; then
907            echo "IGCM_sys_Get, ERROR : regular file ${dm_liste[0]} DOES NOT EXIST ."
908            IGCM_debug_Exit "IGCM_sys_Get"
909            return
910        fi
911
912        (( RET=0 ))
913        for target in ${dm_liste[*]} ; do
914          \cp ${target} ${DEST} >> out_rsync 2>&1
915          (( RET=RET+$? ))
916        done
917
918#       echo ${RSYNC} ${RSYNC_opt} $@ > out_rsync 2>&1
919#       ${RSYNC} ${RSYNC_opt} $@ >> out_rsync 2>&1
920#       RET=$?
921#       IGCM_sys_Rsync_out $RET
922
923#       ${libIGCM}/libIGCM_sys/IGCM_analyse_rsync_out.awk out_rsync
924#       (( RET=RET+$? ))
925
926        if [ ${RET} -gt 0 ] ; then
927            echo "IGCM_sys_Get : copy error."
928            cat out_rsync
929            IGCM_debug_Exit "IGCM_sys_Get"
930        fi
931    else
932        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
933    fi
934    IGCM_debug_PopStack "IGCM_sys_Get"
935}
936
937#D-#==================================================
938#D-function IGCM_sys_Put_Dods
939#D-* Purpose: DO NOTHING ! Put $(ARCHIVE) files on DODS internet protocole.
940#D-* Examples:
941#D-
942function IGCM_sys_Put_Dods {
943    IGCM_debug_PushStack "IGCM_sys_Put_Dods" $@
944    if ( $DEBUG_sys ) ; then
945        echo "IGCM_sys_Put_Dods :" $@
946    fi
947    if [ $DRYRUN = 0 ]; then
948        if [ ! -f ${1} ] ; then
949            echo "WARNING : IGCM_sys_Put_Dods ${1} DOES NOT EXIST ."
950            IGCM_debug_PopStack "IGCM_sys_Put_Dods"
951            return
952        fi
953        #DO NOTHING
954    else
955        ( ${DEBUG_debug} ) && echo "DRYRUN mode = " $DRYRUN >> stack
956    fi
957    IGCM_debug_PopStack "IGCM_sys_Put_Dods"
958}
959
960############################################################## A REVOIR !!
961
962#D-#==================================================
963#D-function IGCM_sys_Rapatrie
964#D-* Purpose: Rapatrie
965#D-* Examples:
966#D-
967function IGCM_sys_Rapatrie {
968    IGCM_debug_PushStack "IGCM_sys_Rapatrie" $@
969    if ( $DEBUG_sys ) ; then
970        echo "IGCM_sys_Rapatrie :" $@
971    fi
972
973    typeset RET=0
974
975    IGCM_sys_Get ${R_STOCKAGE}/$2 $1 ;
976    let $(( RET=RET+$? ))
977    IGCM_sys_Cd $1 ;
978    let $(( RET=RET+$? ))
979    IGCM_sys_UnTar $2 ;
980    let $(( RET=RET+$? ))
981
982    if [ ${RET} -gt 0 ] ; then
983        echo "IGCM_sys_Rapatrie : erreur."
984        IGCM_debug_Exit "IGCM_sys_Rapatrie"
985    fi
986    IGCM_debug_PopStack "IGCM_sys_Rapatrie"
987}
988
989############################################################## A FINIR !!
990
991#D-#==================================================
992#D-function IGCM_sys_GetDate_FichWork
993#D-* Purpose: donne la date filesys d'un fichier sur le filesystem WORK
994#D-* Examples:
995#D-
996function IGCM_sys_GetDate_FichWork {
997    IGCM_debug_PushStack "IGCM_sys_FichWork" $@
998    if ( $DEBUG_sys ) ; then
999        echo "IGCM_sys_GetDate_FichWork :" $@
1000    fi
1001    # donne la date filesys d'un fichier sur la machine work
1002    IGCM_debug_PopStack "IGCM_sys_FichWork"
1003}
1004
1005#D-#==================================================
1006#D-function IGCM_sys_GetDate_FichArchive
1007#D-* Purpose: donne la date filesys d'un fichier sur le filesystem ARCHIVE
1008#D-* Examples:
1009#D-
1010function IGCM_sys_GetDate_FichArchive {
1011    IGCM_debug_PushStack "IGCM_sys_FichArchive" $@
1012    if ( $DEBUG_sys ) ; then
1013        echo "IGCM_sys_GetDate_FichArchive :" $@
1014    fi
1015    IGCM_debug_PopStack "IGCM_sys_FichArchive"
1016}
1017
1018
1019##############################################################
1020# REBUILD OPERATOR
1021
1022function IGCM_sys_rebuild {
1023    IGCM_debug_PushStack "IGCM_sys_rebuild" -- $@
1024    if ( $DEBUG_sys ) ; then
1025        echo "IGCM_sys_rebuild :" $@
1026    fi
1027    rebuild -f -o $@
1028    if [ $? -gt 0 ] ; then
1029       echo "IGCM_sys_rebuild : erreur ${@}."
1030       IGCM_debug_Exit "rebuild"
1031    fi
1032
1033    IGCM_debug_PopStack "IGCM_sys_rebuild"
1034}
1035
1036##############################################################
1037# NCO OPERATOR
1038
1039function IGCM_sys_ncap {
1040    IGCM_debug_PushStack "IGCM_sys_ncap" -- $@
1041    if ( $DEBUG_sys ) ; then
1042        echo "IGCM_sys_ncap :" $@
1043    fi
1044    /usr/local/bin/ncap $@
1045    if [ $? -gt 0 ] ; then
1046       echo "IGCM_sys_ncap : erreur ${@}."
1047#       IGCM_debug_Exit "ncap"
1048    fi
1049
1050    IGCM_debug_PopStack "IGCM_sys_ncap"
1051}
1052
1053ncatted=/usr/local/bin/ncatted
1054# Problem with ksh and string passed in this function to ncatted !
1055# function IGCM_sys_ncatted {
1056#     IGCM_debug_PushStack "IGCM_sys_ncatted" -- $@
1057#     if ( $DEBUG_sys ) ; then
1058#       echo "IGCM_sys_ncatted :" $@
1059#     fi
1060#     /usr/local/bin/ncatted $@
1061#     if [ $? -gt 0 ] ; then
1062#        echo "IGCM_sys_ncatted : erreur ${@}."
1063#        IGCM_debug_Exit "ncatted"
1064#     fi
1065
1066#     IGCM_debug_PopStack "IGCM_sys_ncatted"
1067# }
1068
1069function IGCM_sys_ncbo {
1070    IGCM_debug_PushStack "IGCM_sys_ncbo" -- $@
1071    if ( $DEBUG_sys ) ; then
1072        echo "IGCM_sys_ncbo :" $@
1073    fi
1074    /usr/local/bin/ncbo $@
1075    if [ $? -gt 0 ] ; then
1076       echo "IGCM_sys_ncbo : erreur ${@}."
1077#       IGCM_debug_Exit "ncbo"
1078    fi
1079
1080    IGCM_debug_PopStack "IGCM_sys_ncbo"
1081}
1082
1083function IGCM_sys_ncdiff {
1084    IGCM_debug_PushStack "IGCM_sys_ncdiff" -- $@
1085    if ( $DEBUG_sys ) ; then
1086        echo "IGCM_sys_ncdiff :" $@
1087    fi
1088    /usr/local/bin/ncdiff $@
1089    if [ $? -gt 0 ] ; then
1090       echo "IGCM_sys_ncdiff : erreur ${@}."
1091#       IGCM_debug_Exit "ncdiff"
1092    fi
1093
1094    IGCM_debug_PopStack "IGCM_sys_ncdiff"
1095}
1096
1097function IGCM_sys_ncea {
1098    IGCM_debug_PushStack "IGCM_sys_ncea" -- $@
1099    if ( $DEBUG_sys ) ; then
1100        echo "IGCM_sys_ncea :" $@
1101    fi
1102    /usr/local/bin/ncea $@
1103    if [ $? -gt 0 ] ; then
1104       echo "IGCM_sys_ncea : erreur ${@}."
1105#       IGCM_debug_Exit "ncea"
1106    fi
1107
1108    IGCM_debug_PopStack "IGCM_sys_ncea"
1109}
1110
1111function IGCM_sys_ncecat {
1112    IGCM_debug_PushStack "IGCM_sys_ncecat" -- $@
1113    if ( $DEBUG_sys ) ; then
1114        echo "IGCM_sys_ncecat :" $@
1115    fi
1116    /usr/local/bin/ncecat $@
1117    if [ $? -gt 0 ] ; then
1118       echo "IGCM_sys_ncecat : erreur ${@}."
1119#       IGCM_debug_Exit "ncecat"
1120    fi
1121
1122    IGCM_debug_PopStack "IGCM_sys_ncecat"
1123}
1124
1125function IGCM_sys_ncflint {
1126    IGCM_debug_PushStack "IGCM_sys_ncflint" -- $@
1127    if ( $DEBUG_sys ) ; then
1128        echo "IGCM_sys_ncflint :" $@
1129    fi
1130    /usr/local/bin/ncflint $@
1131    if [ $? -gt 0 ] ; then
1132       echo "IGCM_sys_ncflint : erreur ${@}."
1133#       IGCM_debug_Exit "ncflint"
1134    fi
1135
1136    IGCM_debug_PopStack "IGCM_sys_ncflint"
1137}
1138
1139function IGCM_sys_ncks {
1140    IGCM_debug_PushStack "IGCM_sys_ncks" -- $@
1141    if ( $DEBUG_sys ) ; then
1142        echo "IGCM_sys_ncks :" $@
1143    fi
1144    /usr/local/bin/ncks $@
1145    if [ $? -gt 0 ] ; then
1146       echo "IGCM_sys_ncks : erreur ${@}."
1147#       IGCM_debug_Exit "ncks"
1148    fi
1149
1150    IGCM_debug_PopStack "IGCM_sys_ncks"
1151}
1152
1153function IGCM_sys_ncpdq {
1154    IGCM_debug_PushStack "IGCM_sys_ncpdq" -- $@
1155    if ( $DEBUG_sys ) ; then
1156        echo "IGCM_sys_ncpdq :" $@
1157    fi
1158    /usr/local/bin/ncpdq $@
1159    if [ $? -gt 0 ] ; then
1160       echo "IGCM_sys_ncpdq : erreur ${@}."
1161#       IGCM_debug_Exit "ncpdq"
1162    fi
1163
1164    IGCM_debug_PopStack "IGCM_sys_ncpdq"
1165}
1166
1167function IGCM_sys_ncra {
1168    IGCM_debug_PushStack "IGCM_sys_ncra" -- $@
1169    if ( $DEBUG_sys ) ; then
1170        echo "IGCM_sys_ncra :" $@
1171    fi
1172    /usr/local/bin/ncra $@
1173    if [ $? -gt 0 ] ; then
1174       echo "IGCM_sys_ncra : erreur ${@}."
1175#       IGCM_debug_Exit "ncra"
1176    fi
1177
1178    IGCM_debug_PopStack "IGCM_sys_ncra"
1179}
1180
1181function IGCM_sys_ncrcat {
1182    IGCM_debug_PushStack "IGCM_sys_ncrcat" -- $@
1183    if ( $DEBUG_sys ) ; then
1184        echo "IGCM_sys_ncrcat :" $@
1185    fi
1186    /usr/local/bin/ncrcat $@
1187    if [ $? -gt 0 ] ; then
1188       echo "IGCM_sys_ncrcat : erreur ${@}."
1189#       IGCM_debug_Exit "ncrcat"
1190    fi
1191
1192    IGCM_debug_PopStack "IGCM_sys_ncrcat"
1193}
1194
1195function IGCM_sys_ncrename {
1196    IGCM_debug_PushStack "IGCM_sys_ncrename" -- $@
1197    if ( $DEBUG_sys ) ; then
1198        echo "IGCM_sys_ncrename :" $@
1199    fi
1200    /usr/local/bin/ncrename $@
1201    if [ $? -gt 0 ] ; then
1202       echo "IGCM_sys_ncrename : erreur ${@}."
1203#       IGCM_debug_Exit "ncrename"
1204    fi
1205
1206    IGCM_debug_PopStack "IGCM_sys_ncrename"
1207}
1208
1209function IGCM_sys_ncwa {
1210    IGCM_debug_PushStack "IGCM_sys_ncwa" -- $@
1211    if ( $DEBUG_sys ) ; then
1212        echo "IGCM_sys_ncwa :" $@
1213    fi
1214    /usr/local/bin/ncwa $@
1215    if [ $? -gt 0 ] ; then
1216       echo "IGCM_sys_ncwa : erreur ${@}."
1217#       IGCM_debug_Exit "ncwa"
1218    fi
1219
1220    IGCM_debug_PopStack "IGCM_sys_ncwa"
1221}
1222
1223############################################################
1224# Activate Running Environnment Variables
1225
1226function IGCM_sys_activ_variables {
1227    IGCM_debug_PushStack "IGCM_sys_activ_variables"
1228    if ( $DEBUG_sys ) ; then
1229        echo "IGCM_sys_activ_variables"
1230    fi
1231    IGCM_debug_PopStack "IGCM_sys_activ_variables"
1232}
1233
1234############################################################
1235# Desactivate Running Environnment Variables
1236
1237function IGCM_sys_desactiv_variables {
1238    IGCM_debug_PushStack "IGCM_sys_desactiv_variables"
1239    if ( $DEBUG_sys ) ; then
1240        echo "IGCM_sys_desactiv_variables"
1241    fi
1242    IGCM_debug_PopStack "IGCM_sys_desactiv_variables"
1243}
1244
1245############################################################
1246# Build run file
1247
1248function IGCM_sys_build_run_file {
1249    IGCM_debug_PushStack "IGCM_sys_build_run_file"
1250    if ( $DEBUG_sys ) ; then
1251        echo "IGCM_sys_build_run_file"
1252    fi
1253    IGCM_debug_PopStack "IGCM_sys_build_run_file"
1254}
Note: See TracBrowser for help on using the repository browser.