|
[Sponsors] |
How to configure a job script? Example for another app available as a basis |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
April 14, 2016, 19:06 |
How to configure a job script? Example for another app available as a basis
|
#1 |
Member
Arsalan
Join Date: Jul 2014
Posts: 74
Rep Power: 12 |
Hi Bruno,
After all of this, I got compiled OpenFOAM 2.3.0 and swak4foam 0.3.2 in my home folder at the cluster with your huge help and your support is greatly appreciated. Well, for running my simulations I have to submit a script to the working directory of the cluster,not in my home folder. I don't know that the openFOAM works well by changing the directory or not. By the way, as you now an alias command do not work in a shell script, so I can't run "of230" in my job script in the working directory. Do you have any ideas to fix this problem?! A template of the job script is shown below for fluent simulations, and I am a bit confused with changing this template to that I need for a foam job! Code:
#!/bin/bash #PBS -N FLUENT #PBS -j oe #PBS -l nodes=1:ppn=2 #PBS -l walltime=00:30:00 module add ansys/v150 > /dev/null 2>&1 if [ $? -ne 0 ]; then echo "unable to load module files" exit 1 fi cd $PBS_O_WORKDIR fluent 3d -g -i input > fluent.log 2>&1 Thank you so much again for your time and attention. Best Regards, Arsalan. [ Moderator note: Moved from here: http://www.cfd-online.com/Forums/ope...ot-access.html ] Last edited by wyldckat; April 15, 2016 at 20:14. Reason: see "Moderator note:" |
|
April 15, 2016, 20:21 |
|
#2 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128 |
Hi Arsalan,
I've moved your post from the other thread to a new one, because this is a new topic and it's related to "running", not "installing" Using your example as a basis, the following should do the trick: Code:
#!/bin/bash #PBS -N OpenFOAM #PBS -j oe #PBS -l nodes=1:ppn=2 #PBS -l walltime=00:30:00 module add mpi/openmpi/gcc/1.8 > /dev/null 2>&1 if [ $? -ne 0 ]; then echo "unable to load module files" exit 1 fi #Load up OpenFOAM's environment source $HOME/OpenFOAM/OpenFOAM-2.3.0/etc/bashrc WM_NCOMPPROCS=4 foamCompiler=ThirdParty WM_COMPILER=Gcc48 WM_MPLIB=SYSTEMOPENMPI cd $PBS_O_WORKDIR mpirun -np 2 simpleFoam -parallel > log.simpleFoam 2>&1 Quote:
Nonetheless, keep in mind that not all of OpenFOAM's applications can run in parallel, e.g. blockMesh. Best regards, Bruno
__________________
|
||
April 25, 2016, 16:01 |
|
#3 |
Member
Arsalan
Join Date: Jul 2014
Posts: 74
Rep Power: 12 |
Hi Bruno,
Your modified script worked properly as expected and finally, I could run my simulations in the cluster. At this time,I'm studying the effect of the number of processors in CPU time of the parallel running. I'm grateful to you for your help and attention. King regards, Arsalan. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
mpirun, best parameters | pablodecastillo | Hardware | 18 | November 10, 2016 13:36 |
SGE fluent job submission script | mrji8011 | FLUENT | 2 | May 5, 2011 21:59 |
running OF on local machine with batch script / job scheduler | val46 | OpenFOAM | 13 | November 10, 2010 04:22 |
Can someone PLEASE document the development version installation | bernd | OpenFOAM Installation | 76 | November 14, 2008 22:51 |
cfd job | Dr. Don I anyanwu | Main CFD Forum | 20 | May 17, 1999 16:13 |