3 |
#PBS -q four-twelve |
#PBS -q four-twelve |
4 |
#PBS -N tst_ifc |
#PBS -N tst_ifc |
5 |
#PBS -l nodes=3:ppn=2 |
#PBS -l nodes=3:ppn=2 |
6 |
#PBS -e /home/jmc/test_ACES/output/tst_ifc.stderr |
#PBS -e /home/jmc/test_aces/output/tst_ifc.stderr |
7 |
#PBS -o /home/jmc/test_ACES/output/tst_ifc.stdout |
#PBS -o /home/jmc/test_aces/output/tst_ifc.stdout |
8 |
|
|
9 |
# $Header$ |
# $Header$ |
10 |
# $Name$ |
# $Name$ |
17 |
# Note: added "ulimit -s unlimited" in file "~/.bashrc" |
# Note: added "ulimit -s unlimited" in file "~/.bashrc" |
18 |
# to pass big test (the 2 fizhi-cs-* test & adjoint tests) with MPI |
# to pass big test (the 2 fizhi-cs-* test & adjoint tests) with MPI |
19 |
|
|
20 |
|
dNam='aces' |
21 |
|
TST_DIR="$HOME/test_$dNam" |
22 |
|
echo "start from TST_DIR='$TST_DIR' at: "`date` |
23 |
|
|
24 |
umask 0022 |
umask 0022 |
25 |
#- to get case insensitive "ls" (and order of tested experiments) |
#- to get case insensitive "ls" (and order of tested experiments) |
26 |
export LC_ALL="en_US.UTF-8" |
export LC_ALL="en_US.UTF-8" |
27 |
|
|
|
TST_DIR="/home/jmc/test_ACES" |
|
28 |
HERE=$TST_DIR/output |
HERE=$TST_DIR/output |
|
#cd $HERE |
|
|
|
|
29 |
sfx='ifc' |
sfx='ifc' |
30 |
module add mpich/intel |
module add mpich/intel |
31 |
module add netcdf/3.6.1/icc |
module add netcdf/3.6.1/icc |
38 |
#- keep a copy of MPI_MFILE: |
#- keep a copy of MPI_MFILE: |
39 |
cp -p $PBS_NODEFILE $HERE"/mf_"$sfx |
cp -p $PBS_NODEFILE $HERE"/mf_"$sfx |
40 |
|
|
41 |
checkOut=1 |
checkOut=1 ; #options="$options -do" |
42 |
#options="$options -nc" ; checkOut=0 |
#options="$options -nc" ; checkOut=0 |
43 |
#options="$options -q" ; checkOut=0 |
#options="$options -q" ; checkOut=0 |
44 |
|
|
45 |
|
addExp=0 |
46 |
|
cvsArg="-d :pserver:cvsanon@mitgcm.org:/u/gcmpack" |
47 |
gcmDIR="MITgcm_$sfx" |
gcmDIR="MITgcm_$sfx" |
48 |
cd $TST_DIR |
cd $TST_DIR |
49 |
#- check for disk space: |
#- check for disk space: relative space (99%) or absolute (1.G): |
50 |
dsp=`df -P . | tail -1 | awk '{print $5}' | sed 's/%$//'` |
#dsp=`df -P . | tail -1 | awk '{print $5}' | sed 's/%$//'` |
51 |
if [ $dsp -gt 99 ] ; then |
#if [ $dsp -gt 99 ] ; then |
52 |
|
dsp=`df -P . | tail -1 | awk '{print $4}'` |
53 |
|
if [ $dsp -le 1000000 ] ; then |
54 |
echo 'Not enough space on this disk => do not run testreport.' |
echo 'Not enough space on this disk => do not run testreport.' |
55 |
df . |
df . |
56 |
exit |
exit |
57 |
fi |
fi |
58 |
if [ $checkOut -eq 1 ] ; then |
if [ $checkOut -eq 1 ] ; then |
59 |
if test -d $gcmDIR/CVS ; then |
if test -d $gcmDIR/CVS ; then |
60 |
/bin/rm -rf $gcmDIR/verification/??_aces-${sfx}_????????_? |
#- remove previous output tar files and tar & remove previous output-dir |
61 |
|
/bin/rm -f $gcmDIR/verification/??_${dNam}-${sfx}_????????_?.tar.gz |
62 |
|
( cd $gcmDIR/verification |
63 |
|
listD=`ls -1 -d ??_${dNam}-${sfx}_????????_? 2> /dev/null` |
64 |
|
for dd in $listD |
65 |
|
do |
66 |
|
if test -d $dd ; then |
67 |
|
tar -cf ${dd}".tar" $dd > /dev/null 2>&1 && gzip ${dd}".tar" && /bin/rm -rf $dd |
68 |
|
RETVAL=$? |
69 |
|
if test "x$RETVAL" != x0 ; then |
70 |
|
echo "ERROR in tar+gzip prev outp-dir: $dd" |
71 |
|
echo " on '"`hostname`"' (return val=$RETVAL) but continue" |
72 |
|
fi |
73 |
|
fi |
74 |
|
done ) |
75 |
( cd $gcmDIR/verification ; ../tools/do_tst_2+2 -clean ) |
( cd $gcmDIR/verification ; ../tools/do_tst_2+2 -clean ) |
76 |
|
#- clean-up previous TAF output temp dir (generated on old system like here) |
77 |
|
# ( cd $gcmDIR/verification ; /bin/rm -rf */build/PaxHeaders.[0-9]* ) |
78 |
echo "cvs update of dir $gcmDIR :" |
echo "cvs update of dir $gcmDIR :" |
79 |
( cd $gcmDIR ; cvs -q -d :pserver:cvsanon@mitgcm.org:/u/gcmpack update -P -d ) 2>&1 |
( cd $gcmDIR ; cvs -q $cvsArg update -P -d ) 2>&1 |
80 |
RETVAL=$? |
RETVAL=$? |
81 |
if test "x$RETVAL" != x0 ; then |
if test "x$RETVAL" != x0 ; then |
82 |
echo "cvs update on '"`hostname`"' fail (return val=$RETVAL) => exit" |
echo "cvs update on '"`hostname`"' fail (return val=$RETVAL) => exit" |
92 |
rm -rf $gcmDIR |
rm -rf $gcmDIR |
93 |
fi |
fi |
94 |
# cvs co MITgcm |
# cvs co MITgcm |
95 |
cvs -d :pserver:cvsanon@mitgcm.org:/u/gcmpack co -P -d $gcmDIR MITgcm > /dev/null 2>&1 |
cvs $cvsArg co -P -d $gcmDIR MITgcm > /dev/null 2>&1 |
96 |
|
if [ $addExp -ge 1 ]; then |
97 |
|
echo " add dir: offline_cheapaml (from Contrib:verification_other)" |
98 |
|
( cd $gcmDIR/verification ; cvs $cvsArg co -P -d offline_cheapaml \ |
99 |
|
MITgcm_contrib/verification_other/offline_cheapaml > /dev/null 2>&1 ) |
100 |
|
fi |
101 |
/usr/bin/find $gcmDIR -type d | xargs chmod g+rxs |
/usr/bin/find $gcmDIR -type d | xargs chmod g+rxs |
102 |
/usr/bin/find $gcmDIR -type f | xargs chmod g+r |
/usr/bin/find $gcmDIR -type f | xargs chmod g+r |
103 |
fi |
fi |
112 |
exit |
exit |
113 |
fi |
fi |
114 |
|
|
115 |
echo ./testreport $options -of $OPTFILE -command \"$EXE\" -odir aces-$sfx |
SavD="$HOME/test_$dNam/send" |
116 |
./testreport $options -of $OPTFILE -command "$EXE" -odir aces-$sfx |
SEND="ssh geo $SavD/mpack" |
117 |
|
|
118 |
|
echo ./testreport $options -of $OPTFILE -command \"$EXE\" -odir ${dNam}-$sfx \ |
119 |
|
-send \"$SEND\" -sd $SavD -a jmc@mitgcm.org |
120 |
|
./testreport $options -of $OPTFILE -command "$EXE" -odir ${dNam}-$sfx \ |
121 |
|
-send "$SEND" -sd $SavD -a jmc@mitgcm.org |
122 |
|
|
123 |
echo '' |
echo '' |
124 |
echo ../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe \"$EXE\" -o aces-$sfx -a NONE |
#echo ../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe \"$EXE\" -o ${dNam}-$sfx -a NONE |
125 |
../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe "$EXE" -o aces-$sfx -a NONE |
#../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe "$EXE" -o ${dNam}-$sfx -a NONE |
126 |
|
echo ../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe \"$EXE\" -o ${dNam}-$sfx \ |
127 |
|
-send \"$SEND\" -sd $SavD -a jmc@mitgcm.org |
128 |
|
../tools/do_tst_2+2 -mpi -mf $PBS_NODEFILE -exe "$EXE" -o ${dNam}-$sfx \ |
129 |
|
-send "$SEND" -sd $SavD -a jmc@mitgcm.org |
130 |
|
|