Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_MERCATOR_CLUSTER
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_MERCATOR_CLUSTER	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_MERCATOR_CLUSTER	(revision 3422)
@@ -4,8 +4,8 @@
 #PBS -e sette.$PBS_JOBID.err
 #PBS -o sette.$PBS_JOBID.out
-#PBS -l nodes=2:ppn=8
-#PBS -q multi
+#PBS -l nodes=NODES:ppn=NPROCS
+#PBS -q QUEUE
 #PBS -l walltime=03:00:00
-#PBS -l mem=24gb
+#PBS -l mem=MEMgb
 
 #
@@ -22,5 +22,6 @@
 # Local settings for machine IBM Power6 (VARGAS at IDRIS France)
 #
-export MPIRUN="mpiexec -n $OCEANCORES"
+#cbr export MPIRUN="mpiexec -n $OCEANCORES"
+export MPIRUN="mpirun -np $OCEANCORES"
 
 #
@@ -57,9 +58,10 @@
 #  Run the parallel MPI executable 
 #
+  echo "Running time ${MPIRUN} ./opa"
+#
   if [ MPI_FLAG == "yes" ]; then
-  echo "Running time ${MPIRUN} ./opa"
-     time ${MPIRUN} ./opa
+#cbr     time ${MPIRUN} ./opa
+     mpirun -np $OCEANCORES ./opa
   else
-  echo "Running time ./opa"
      time ./opa
   fi
Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM.cfg
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM.cfg	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM.cfg	(revision 3422)
@@ -1,1 +1,1 @@
-ORCA2_LIM_nemo_v3.3.tar
+ORCA2_LIM_nemo_v3.4.tar
Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM_PISCES.cfg
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM_PISCES.cfg	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/input_ORCA2_LIM_PISCES.cfg	(revision 3422)
@@ -1,1 +1,1 @@
-ORCA2_LIM_nemo_v3.3.tar
+ORCA2_LIM_nemo_v3.4.tar
Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/param.cfg
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/param.cfg	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/param.cfg	(revision 3422)
@@ -1,4 +1,4 @@
 #- forcing files storing 
-FORCING_DIR=~/FORCING
+FORCING_DIR=/data/rd_exchange/cbricaud/NEMO_3.4_dev2012/FORCING
 #- input files storing 
 INPUT_DIR=${CONFIG_DIR}/${NEW_CONF}/EXP00
Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/prepare_job.sh
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/prepare_job.sh	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/prepare_job.sh	(revision 3422)
@@ -6,9 +6,9 @@
 # prepare_job.sh   : create the job script for running job 
 ######################################################
-#set -vx
+#set -x
 set -o posix
 #set -u
 #set -e
-#+
+#
 #
 # ================
@@ -25,5 +25,5 @@
 # ::
 #
-#  $ ./prepare_job.sh INPUT_FILE_CONFIG_NAME NUMBER_PROC TEST_NAME MPI_FLAG JOB_FILE
+#  $ ./prepare_job.sh INPUT_FILE_CONFIG_NAME NUMBER_PROC TEST_NAME MPI_INTERACT MPI_FLAG
 #
 #
@@ -31,7 +31,14 @@
 # ===========
 #
-# Part of the SETTE package to run tests for NEMO
+# Simple job for SET TESTS for NEMO (SETTE)
 # 
-# prepare the script $JOB_FILE to run the tests 
+#   get input files (if needed) : tar file  
+#  (note this job needs to have an input_CONFIG.cfg in which can be found input tar file name)
+#
+#   runs job in interactive or batch mode : all jobs using 1 process are run interactive, and all MPP jobs are
+#
+#   run in batch (MPI_INTERACT="no") or interactive (MPI_INTERACT="yes") see sette.sh and BATCH_TEMPLATE directory
+#
+#   and call post_test_tidyup function (that moves in NEMO_VALIDATION_DIR solver.stat, tracer.stat (for LOBSTER & PISCES) & ocean.output)
 #
 # EXAMPLES
@@ -40,7 +47,11 @@
 # ::
 #
-#  $ ./prepare_job.sh INPUT_FILE_CONFIG_NAME NUMBER_PROC TEST_NAME MPI_FLAG $JOB_FILE
-#
-# prepare the $JOB_FILE for execution 
+#  $ ./fcm_job.sh INPUT_FILE_CONFIG_NAME NUMBER_PROC TEST_NAME MPI_INTERACT MPI_FLAG
+#
+#  run a job of config GYRE with 1 processor SHORT test ( 5 days ) using an interactive run without mpirun
+#  $ ./fcm_job.sh input_GYRE.cfg 1 SHORT yes no
+#
+#  run a job of config ORCA2_LIM_PISCES	with 8 processors test RESTARTABILITY submitting the job to the batch queue system and using mpirun
+#  $ ./fcm_job.sh input_ORCA2_LIM_PISCES.cfg 8 LONG no yes
 #
 #
@@ -54,5 +65,5 @@
 # ==========
 #
-# $Id: prepare_job.sh 3050 2011-11-07 14:11:34Z acc $
+# $Id: fcm_job.sh 3050 2011-11-07 14:11:34Z acc $
 #
 #
@@ -63,6 +74,6 @@
 #
 
-usage=" Usage : ./prepare_job.sh INPUT_FILE_CONFIG_NAME NUMBER_PROC TEST_NAME MPI_FLAG JOB_FILE"
-usage=" example : ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg 8 SHORT no/yes $JOB_FILE"
+usage=" Usage : ./fcm_job.sh input_CONFIG_NAME.cfg  NUMBER_OF_PROCS TEST_NAME INTERACT MPI_FLAG"
+usage=" example : ./fcm_job.sh input_ORCA2_LIM_PISCES.cfg 8 SHORT no/yes no/yes"
 
 
@@ -70,6 +81,6 @@
         if [ ${#} -lt ${minargcount} ]
         then
-                echo "not enough arguments for prepare_job.sh script"
-                echo "control number of argument of prepare_job.sh in sette.sh"
+                echo "not enought arguments for fcm_job.sh script"
+                echo "control number of argument of fcm_job.sh in sette.sh"
                 echo "${usage}"
         exit 1
@@ -154,8 +165,31 @@
     exit 1
 fi
-
+#if [ ${NB_PROC} == 1 ] ; then
+#    echo "running opa" >> ${SETTE_DIR}/output.sette
+#    echo "            " >> ${SETTE_DIR}/output.sette
+#    ./opa
+#
+# Tidy out output from this test and populate the NEMO_VALIDATION_DIR tree
+#
+#    post_test_tidyup
+#else
+#    echo "running opa in MPI" >> ${SETTE_DIR}/output.sette
+#    echo "            " >> ${SETTE_DIR}/output.sette
+
+#    if [ ${MPI_INTERACT} == "yes" ] ; then
+#	#
+#	# example for brodie (NEC SX8) machine
+#	#	mpirun -np ${NB_PROC} opa
+#	# example for dedale machine
+#	#	mpirun --mca btl self,tcp -np ${NB_PROC} opa
+#	# example for vargas (IBM Power6) machine
+#	mpiexec -n ${NB_PROC} opa
+#	#
+#	post_test_tidyup
+#    fi
+#
 # example for NOCS Altix system using PBS batch submission (requires ${SETTE_DIR}/sette_batch_template file)
 #
-  #  if [ ${MPI_FLAG} == "no" ] ; then
+  #  if [ ${MPI_INTERACT} == "no" ] ; then
 		case ${COMPILER} in 
 			ALTIX_NAUTILUS_MPT)
@@ -164,5 +198,5 @@
 					# number of processes required is an integer multiple of 4
 					#
-					NB_NODES=$( echo $NB_PROC | awk '{print $1 / 4}')
+					NB_NODES=$( echo $NB_PROC | awk '{print $1  $1 / 4}')
 				else
 					#
@@ -173,4 +207,20 @@
 	       			fi
 				;;
+                        ifort_MERCATOR_CLUSTER)
+                                echo NB_PROCS ${NB_PROC}
+                                NB_NODES=$( echo $NB_PROC | awk '{print $1 - $1 % 8}'  | awk '{print $1 / 8 + 1 }')
+                                echo NB_NODES ${NB_NODES}
+                                echo  NB_PROC ${NB_PROC} 
+                                if [ ${NB_PROC} -eq 1 ] ; then
+                                   QUEUE=monoproc
+                                else
+                                   if [ ${NB_PROC} -le 8 ] ; then 
+                                      QUEUE=mono
+                                   else
+                                      QUEUE=multi
+                                      NB_PROC=8
+                                  fi    
+                                fi    
+				;;
 			*)
 				NB_NODES=${NB_PROC}
@@ -181,5 +231,8 @@
 # Pass settings into job file by using sed to edit predefined strings
 #
+         ((mem=5*NB_PROC))
+         echo NB_NODES NB_PROC QUEUE ${NB_NODES} ${NB_PROC} ${QUEUE}
         cat ${SETTE_DIR}/job_batch_template | sed -e"s/NODES/${NB_NODES}/" -e"s/NPROCS/${NB_PROC}/" \
+             -e"s/QUEUE/${QUEUE}/" -e"s/MEM/${mem}/" \
              -e"s:DEF_SETTE_DIR:${SETTE_DIR}:" -e"s:DEF_INPUT_DIR:${INPUT_DIR}:" \
              -e"s:DEF_EXE_DIR:${EXE_DIR}:" \
@@ -205,5 +258,5 @@
 	fi
 	
-	chmod a+x $JOB_FILE ; echo "$JOB_FILE is ready"
+	chmod a+x $JOB_FILE
 
 #fi
Index: branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/sette.sh
===================================================================
--- branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/sette.sh	(revision 3411)
+++ branches/2012/dev_r3342_MERCATOR7_SST/NEMOGCM/SETTE/sette.sh	(revision 3422)
@@ -133,6 +133,6 @@
 #-
 # Compiler among those in NEMOGCM/ARCH
-COMPILER=PW6_VARGAS
-export BATCH_COMMAND_PAR="llsubmit"
+COMPILER=ifort_MERCATOR_CLUSTER 
+export BATCH_COMMAND_PAR="qsub"
 export BATCH_COMMAND_SEQ=$BATCH_COMMAND_PAR
 export INTERACT_FLAG="no"
@@ -152,5 +152,5 @@
 cp BATCH_TEMPLATE/batch-${COMPILER} job_batch_template || exit
 
-for config in 1 2 3 4 5 6 7 8 9
+for config in 1 2 3 4 5 6 7 8
 do
 
