Ceci est une ancienne révision du document !


RAPPEL : allo-psmn is just a connexion server; it allows you to have access to your files and to transfer them, and that's all. To work, you have to connect, from allo-psmn, on one of the compilation servers

The batch system currently used at the PSMN is Sun Grid Engine (SGE). Its documentation is on this page as well as in the F.A.Q..

Submit a job

We use the command qsub to submit a job to the PSMN batch system. For exemple :

qsub submission_script 

Submission scripts

Here are some scripts for submitting a job to the PSMN batch system.

Some variables have to be updated, for exemple, according to the actual configurations of the queues.

Othere exemples of submission scripts , exemples of submission scripts as well as tutorials.

for sequential programs (shell bash)

You can submit your job using the following command:

 qsub submission_script 
submission_script
#!/bin/bash
#
### variables SGE
### shell du job
#$ -S /bin/bash
### job name (to change):
#$ -N SommeVecVecSEQ
### queue (to change)
#$ -q E5-2670_test
### load the user environment for SGE
#$ -cwd
### to export environment variables to all runtime nodes
#$ -V
### mails at the beginning and end of execution
#$ -m be
 
# go to the work / submission directory
# important, otherwise the program is running since ~/
cd ${SGE_O_WORKDIR}
 
### configure the environment (to change)
 
module load iccifort/2017.4 
 
### program execution (to change with your executable)
###EXECDIR=${HOME}/Formations/Sequentiel
###${EXECDIR}/SommeVecVecSEQ.exe < Monfichierdedata > monfichierresultat
./SommeVecVecSEQ.f90.exe
 
# fin

Travailler dans le /scratch

batch.sh
#!/bin/bash
#
### variables SGE
#
### shell du job
#$ -S /bin/bash
### nom du job (a changer)
#$ -N SommeVecVecSEQ
### file d'attente (a changer)
#$ -q E5-2670_test
### charger l'environnement utilisateur pour SGE
#$ -cwd
### exporter les variables d'environnement sur tous les noeuds d'execution
#$ -V
### mails en debut et fin d'execution
#$ -m be
# aller dans le repertoire de travail/soumission
# important, sinon, le programme est lancé depuis ~/
cd ${SGE_O_WORKDIR}
### configurer l'environnement (a changer)
 
module load iccifort/2017.4 
 
# for bash:
SCRATCHDIR=${SGE_O_WORKDIR/home/scratch}
/bin/mkdir -p $SCRATCHDIR
 
/bin/cp -rf SommeVecVecSEQ.f90.exe $SCRATCHDIR/
###/bin/cp -rf $INPUT $SCRATCHDIR/
 
# go to scratch (instead of workdir) before running binary
cd ${SCRATCHDIR}
 
### execution du programme
######EXECDIR=/scratch/cicaluga/tempo
EXECDIR=${SCRATCHDIR}
${EXECDIR}/SommeVecVecSEQ.f90.exe > output
####./SommeVecVecSEQ.f90.exe
 
# copy results from scratch to home
/bin/cp -r $SCRATCHDIR/output $SGE_O_WORKDIR/
 
rm -fr ${SCRATCHDIR}/*
 
# fin

Surveiller un job

Voir la documentation qui correspond et les exemples.

en/documentation/tutorials/submit/jobsequentielbash.1516170310.txt.gz · Dernière modification : 2020/08/25 15:58 (modification externe)