Ceci est une ancienne révision du document !
/scratch glusterfs
commun des queues E5-*
Le script suivant se lance avec la commande : qsub parexample.sh
#!/bin/bash ### variables SGE HOMEDIR=$SGE_O_WORKDIR ### shell du job #$ -S /bin/bash ### nom du job (a changer) #$ -N testbash ### file d'attente (a changer) #$ -q E5-2670deb68A ### parallel environnement & nslots (a changer) #$ -pe mpi8_debian 8 ### charger l'environnement utilisateur pour SGE #$ -cwd ### exporte les variables d'environnement sur tous les noeuds d'exécution #$ -V ### sinon SGE travaille dans ~/ cd ${HOMEDIR} ### modeles: #source /usr/local/modeles/set_debian7-clean.sh #source /usr/local/modeles/sge.sh #source /usr/local/modeles/openmpi-1.4.1-intel-11.1.069.sh ### environment modules source /usr/share/modules/init/bash module use /applis/PSMN/Modules module load Base/psmn module load openmpi/1.4.1-intel-11.1.069 ### definition SCRATCHDIR SCRATCHDIR=${SGE_O_WORKDIR/home/scratch} ### verif SCRATCHDIR echo "SCRATCHDIR=${SCRATCHDIR}" BINDIR="/softs/Spinevolution/spinev-3.4.5-Linux-x86_64/" EXEC="spinev" ### PREFIX doit matcher le modele openmpi (ligne 18) PREFIX=/softs/openmpi-1.4.1-intel-11.1.069 MPIRUN=${PREFIX}/bin/mpirun ### necessaire si plusieurs noeuds ### HOSTFILE=${TMPDIR}/machines ### creation du repertoire de travail dans le /scratch if [[ ! -d "${SCRATCHDIR}" ]] then /bin/mkdir -p ${SCRATCHDIR} fi ### copie des fichiers input dans le /scratch for FICHIER in INPUT.hdf5 MATHRICE cube3x3 do cp ${FICHIER} ${SCRATCHDIR}/ done ### nettoyage d'eventuels fichiers resultat indesirable AVANT le ### lancement du programme, si necessaire for FICHIER in OUTPUT.hdf5 mathrice.o do if [[ -e "${SCRATCHDIR}/${FICHIER}" ]] then /bin/rm -f ${SCRATCHDIR}/${FICHIER} fi done ### hostfile SGE si repartition sur plusieurs noeuds /bin/cat ${TMPDIR}/machines >> ${HOMEDIR}/tmp /bin/rm -f ${HOMEDIR}/Master Master="`/usr/bin/head -1 ${TMPDIR}/machines`" /bin/echo $Master >> ${HOMEDIR}/Master ### se placer dans le repertoire d'execution AVANT le lancement du programme cd ${SCRATCHDIR} ${MPIRUN} -prefix ${PREFIX} -mca btl sm,openib,self -np ${NSLOTS} ${BINDIR}/${EXEC} > ${SCRATCHDIR}/out ### recuperation des resultats à la fin du calcul for FICHIER in OUTPUT.hdf5 mathrice.o do cp ${SCRATCHDIR}/${FICHIER} ${HOMEDIR}/ done ###
#!/bin/bash # ### variables SGE HOMEDIR=/home/votrelogin/testpourscratch ### shell du job #$ -S /bin/bash ### nom du job (a changer) #$ -N test1 ### file d'attente (a changer) #$ -q monointelbig ### 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 ${HOMEDIR} ### configurer l'environnement source /usr/share/modules/init/bash module use /applis/PSMN/Modules module load Base/psmn module load intel/14.0.1 ### definition SCRATCHDIR SCRATCHDIR=/scratch/votrelogin/testpourscratch ### verif SCRATCHDIR echo "SCRATCHDIR=${SCRATCHDIR}" ### creation du repertoire de travail dans le /scratch if [[ ! -d "${SCRATCHDIR}" ]] then /bin/mkdir -p ${SCRATCHDIR} else if [[ "${SCRATCHDIR}" =~ scratch ]] then # cette commande est DANGEREUSE ! # /bin/rm -rf ${SCRATCHDIR}/ /bin/mkdir -p ${SCRATCHDIR} fi fi ### copie des fichiers sources dans le /scratch /bin/cp ${HOMEDIR}/* ${SCRATCHDIR}/ ### se placer dans le repertoire d'execution AVANT le lancement du programme cd ${SCRATCHDIR} ### execution du programme ##EXECDIR=${HOME}/Formations/Sequentiel ##${EXECDIR}/aggregate_infinite.exe < Monfichierdedata > monfichierresultat ./test1.exe ### recuperation des resultats à la fin du calcul /bin/cp ${SCRATCHDIR}/* ${HOMEDIR}/ ### delete le dossier sur /scratch if [[ "${SCRATCHDIR}" =~ scratch ]] then /bin/rm -rf ${SCRATCHDIR} fi ### # fin
#!/bin/bash ### SGE #$ -q E5-2670deb64A,E5-2670deb64B,E5-2670deb64C,E5-2670deb64D,E5-2670deb64E #$ -pe mpi16_debian 32 #[...]
#!/bin/bash ### SGE #$ -q dl165_debian,sl390_debian,x41zlin32gb #$ -pe openmp8 8 #[...]
#!/bin/bash ### SGE #$ -q dl165_debian #$ -pe openmp8 8 ## node HS : #$ -l h=!dl165lin2 #[...]
/scratch
#!/bin/bash #[...] # Copy input from home to scratch (pick bash or tcsh version) cd $SGE_O_WORKDIR # for bash: SCRATCHDIR=${SGE_O_WORKDIR/home/scratch} # for tcsh/csh: #set SCRATCHDIR = `echo $SGE_O_WORKDIR | awk -F "/" '{$2="scratch"; for(j=2;j<=NF;j++) {printf("/%s",$j);} print ""} ' ` /bin/mkdir -p $SCRATCHDIR /bin/cp -rf $INPUT $SCRATCHDIR/ # go to scratch (instead of workdir) before running binary cd ${SCRATCHDIR} # run whatever binary whatever < $INPUT > $OUTPUT # copy results from scratch to home /bin/cp -r $SCRATCHDIR/$OUTPUT $SGE_O_WORKDIR/
/scratch
(bash only)#!/bin/bash #[...] cd $SGE_O_WORKDIR # for bash: SCRATCHDIR=${SGE_O_WORKDIR/home/scratch} if [[ -d "/scratch" ]] then mkdir -p ${SCRATCHDIR} else echo "/scratch not found, cannot create ${SCRATCHDIR}" exit 1 fi /bin/cp -rf $INPUT $SCRATCHDIR/ # go to scratch (instead of workdir) before running binary cd ${SCRATCHDIR}
/scratch
global (bash only)### creation avec verification scratch global if [[ -d "/scratch" ]] then # pour scratch X5 / queues X5* if [[ -e "/scratch/x5570-gfs-scratch" ]] # pour scratch E5 / queues E5* # if [[ -e "/scratch/e5-2670-gfs-scratch" ]] then mkdir -p ${SCRATCHDIR} else echo "/scratch not found, cannot create ${SCRATCHDIR}" exit 1 fi else echo "/scratch not found, cannot create ${SCRATCHDIR}" exit 1 fi
#!/bin/bash ### SGE #$ -q x41zlin32gb #$ -pe gaussian8 8 #[...]
#!/bin/bash ### SGE #$ -q sl390lin48 #$ -pe gaussian8 4 #[...]
/scratch
#!/bin/bash #[...] cd ${SCRATCHDIR} export GAUSS_SCRDIR=${SCRATCHDIR} #[...]
#!/bin/bash ### SGE #$ -q sl390lin48 #$ -pe gaussian8 4 #$ -cwd #$ -V # NPERSOCKET="4" # ${MPIRUN} -prefix ${PREFIX} -mca btl sm,openib,self -npersocket ${NPERSOCKET} -bycore -bind-to-core -report-bindings -np ${NSLOTS} ${EXECDIR}/MonProgrammeOpenmpi
#!/bin/bash ### variables SGE HOMEDIR=$SGE_O_WORKDIR ### shell du job: #$ -S /bin/bash ### nom du job: #$ -N testbash ### file d'attente: #$ -q monoamddeb25 ### parallel environnement & nslots #$ -pe openmp8 8 ### charger l'environnement utilisateur pour SGE #$ -cwd ### exporte les variables d'environnement sur tous les noeuds d'exécution #$ -V #[...] # Variables pour OPENMP #export OMP_NUM_THREADS=$NSLOTS export OMP_NUM_THREADS=8 ${EXEC_DIR}/run_RSEM.pl --transcripts ${TRINITY} --name_sorted_bam ${file} --paired --group_by_component
#!/bin/bash #[...] ### modeles: #source /usr/local/modeles/set_debian7-clean.sh #source /usr/local/modeles/sge.sh #source /usr/local/modeles/openmpi-1.4.1-intel-11.1.069.sh source /usr/share/modules/init/bash module use /applis/PSMN/Modules module load Base/psmn module load openmpi/1.4.1-intel-11.1.069 #[...]