CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   CentFOAM & openfoam2.2.x (troubles with runApplication ...) (https://www.cfd-online.com/Forums/openfoam-installation/121720-centfoam-openfoam2-2-x-troubles-runapplication.html)

paul18 August 4, 2013 06:28

CentFOAM & openfoam2.2.x (troubles with runApplication ...)
 
Dear All

I'm in charge of a numerical server (under CentOS 6.2 with 8 processors) in order to perform numerical calculations (I'm a Mechanical engineer using Finite Elements solvers and numerical tools).

For colleagues performing CFD calculations, I've been installing:
- openfoam 2.2.x using centfoam script
- engrid, paraview and gmsh tools were installed separatly first without difficulty
- no error when launching OF22 alias

In order to validate that openfoam works (fine), I tried to launch an example such as motorbike one using Allrun script; nevertheless I've met some troubles I do not understand:
- runApplication is missing
- runParallel is missing
- getApplication is missing

Any reason ?

Thanks for any support

Paul

linnemann August 4, 2013 10:19

Hi

Did you run OF22 in the terminal before running Allrun script?

If you did not the terminal environment has no idea about the OF stuff.

paul18 August 4, 2013 10:55

Quote:

Originally Posted by linnemann (Post 443735)
Did you run OF22 in the terminal before running Allrun script?

Thanks for your support ...
yes I did it (type OFF22 then ./Allrun)

NB: when I make a "find -P -name "*runApplications*" at the /, nothing is found (same result for the other libraries)

was there a trouble during Openfoam2.2.x.tar.gz file installation ??????

Paul

linnemann August 4, 2013 11:22

Are you sure there are any files in the install directory?

paul18 August 4, 2013 13:04

In the following link, you'll find all the files included in the /openFOAM repertory using "ls -lsR"

Note there's something strange : 2 user names appear in the list while I installed centFOAM under my user name (the names have been changed of course)

http://dl.free.fr/uckrbyeqY

Paul

linnemann August 4, 2013 13:35

That link is not any good. please use something that does not look like spam eg. google drive, dropbox, skydrive etc.

linnemann August 4, 2013 14:11

Just went through the file and the problem is in the bashrc file of OpenFOAM.

I've done some updating and a mistake has slipped in whilst doing that.

If you download the new centFoam.py script it should work and if you change this line in the OF bashrc file it should also work for you

Code:

foamInstall=/home/centfoam/$WM_PROJECT
so instead of /home/centfoam/ replace accordingly to fit your system.

paul18 August 4, 2013 14:19

I've made the requested changes in the bashrc and chsrc files (openfoam repertories) after tarball file decompression

In order to install cenFOAM in the root /, I needed to type

python script_name --OF22 --path=

I had troubles using --path=/ or something else ; my bashrc file plus the 2 previous files were updated afterward

Let me testing the new script ....

Paul

paul18 August 4, 2013 17:30

last remark ... when I do ./Allwmake, I've an error message telling me the environment variables are inconsistent ... enough for today

Paul

paul18 August 5, 2013 17:59

Hi

I naively tried to compile Openfoam using the devtoolset for gcc ... bad idea

Centfoam appears to be the best solution ; ounce again I installed it (/opt that time) :
- eveything seems ok
- the use of Allwmake shows everything has ever been done correctly
- the use of "icoFoam -help" seems to work

But when I launch a tutorial with "./Allrun" :
- runApplication
- runParallel
- and so on are missing ... what's going wrong ?

is it possible that the tarball is corrupted or something missing in ? I would like to understand ....

Paul

linnemann August 6, 2013 01:17

Hi

can you please post the output from the terminal here?

It is really difficult to help when we cant see the errors you get.

paul18 August 6, 2013 02:36

here are :

Quote:

[ETUDE_OPENFOAM]$ cd motorBike/
[motorBike]$ ls -l
total 20
drwxrwxr-x. 3 x x 4096 4 août 09:43 0.org
-rwxrwxr-x. 1 x x 286 4 août 09:43 Allclean
-rwxrwxr-x. 1 x x 905 5 août 23:34 Allrun
drwxrwxr-x. 4 x x 4096 4 août 09:43 constant
drwxrwxr-x. 2 x x 4096 5 août 23:37 system
[motorBike]$ ./Allclean
Cleaning /home/ETUDE_OPENFOAM/motorBike case
[motorBike]$ OF22
[motorBike]$ ./Allrun
./Allrun: line 9: runApplication : commande introuvable
./Allrun: line 11: runApplication : commande introuvable
./Allrun: line 13: runApplication : commande introuvable
./Allrun: line 14: runParallel : commande introuvable
ls: impossible d'accéder à processor*: Aucun fichier ou dossier de ce type
ls: impossible d'accéder à processor*: Aucun fichier ou dossier de ce type
./Allrun: line 23: runParallel : commande introuvable
./Allrun: line 24: runParallel : commande introuvable
./Allrun: line 25: getApplication : commande introuvable
./Allrun: line 25: runParallel : commande introuvable
./Allrun: line 27: runApplication : commande introuvable
./Allrun: line 28: runApplication : commande introuvable
[motorBike]$ cd ..
[ETUDE_OPENFOAM]$
In french :
"commande introuvable" = missing command
" impossible d'accéder à processor*: Aucun fichier ou dossier de ce type" = no access to processor*: no such file nor directory

In the Allrun file, variables were removed (after trials):
Quote:

#!/bin/sh
cd ${0%/*} || exit 1 # run from this directory

# Source tutorial run functions
/opt/OpenFOAM/OpenFOAM/OpenFOAM-2.2.x/bin/tools/RunFunctions

# copy motorbike surface from resources folder
cp /opt/OpenFOAM/OpenFOAM/OpenFOAM-2.2.x/tutorials/resources/geometry/motorBike.obj.gz constant/triSurface/
runApplication surfaceFeatureExtract

runApplication blockMesh

runApplication decomposePar
runParallel snappyHexMesh 4 -overwrite

#- For non-parallel running
#cp -r 0.org 0 > /dev/null 2>&1

#- For parallel running
ls -d processor* | xargs -i rm -rf ./{}/0 $1
ls -d processor* | xargs -i cp -r 0.org ./{}/0 $1

runParallel patchSummary 6
runParallel potentialFoam 6 -noFunctionObjects -writep
runParallel $(getApplication) 6

runApplication reconstructParMesh -constant
runApplication reconstructPar -latestTime

# ----------------------------------------------------------------- end-of-file
Paul

linnemann August 6, 2013 02:53

Hi

I have no problems by doing this.

Open a new terminal cd into you case.

Code:

cd OF-cases/Sandbox/motorBike/
Source OpenFOAM by doing

Code:

OF22
run the Allrun script

Code:

./Allrun
watch output

Code:

Running surfaceFeatureExtract on /home/44792/OF-cases/Sandbox/motorBike
Running blockMesh on /home/44792/OF-cases/Sandbox/motorBike
Running decomposePar on /home/44792/OF-cases/Sandbox/motorBike
Running snappyHexMesh in parallel on /home/44792/OF-cases/Sandbox/motorBike using 6 processes

I can see you have edited the Allrun script, please do not do that for the tutorials.

I think your problem is that you are missing a "." to source the RunFunctions

Original Allrun
Code:

# Source tutorial run functions
. $WM_PROJECT_DIR/bin/tools/RunFunctions

your Allrun
Code:

# Source tutorial run functions
/opt/OpenFOAM/OpenFOAM/OpenFOAM-2.2.x/bin/tools/RunFunctions

that small ". " is very important.

paul18 August 6, 2013 03:49

sorry for my incompetence ... and thanks for the support

Now i few seconds I've the following one :
Quote:

[motorBike]$ OF22
[motorBike]$ ./Allrun
Running surfaceFeatureExtract on /home/ETUDE_OPENFOAM/motorBike
Running blockMesh on /home/ETUDE_OPENFOAM/motorBike
Running decomposePar on /home/ETUDE_OPENFOAM/motorBike
Running snappyHexMesh in parallel on /home/ETUDE_OPENFOAM/motorBike using 6 processes
Running patchSummary in parallel on /home/ETUDE_OPENFOAM/motorBike using 6 processes
Running potentialFoam in parallel on /home/ETUDE_OPENFOAM/motorBike using 6 processes
Running simpleFoam in parallel on /home/ETUDE_OPENFOAM/motorBike using 6 processes
Running reconstructParMesh on /home/ETUDE_OPENFOAM/motorBike
Running reconstructPar on /home/ETUDE_OPENFOAM/motorBike
[motorBike]$ ls -l
total 84
drwxrwxr-x. 3 x x 4096 4 août 09:43 0.org
-rwxrwxr-x. 1 x x 286 4 août 09:43 Allclean
-rwxrwxr-x. 1 x x 853 6 août 09:32 Allrun
drwxrwxr-x. 5 x x 4096 6 août 09:33 constant
-rw-rw-r--. 1 x x 2109 6 août 09:33 log.blockMesh
-rw-rw-r--. 1 x x 3540 6 août 09:33 log.decomposePar
-rw-rw-r--. 1 x x 796 6 août 09:33 log.patchSummary
-rw-rw-r--. 1 x x 796 6 août 09:33 log.potentialFoam
-rw-rw-r--. 1 x x 1206 6 août 09:33 log.reconstructPar
-rw-rw-r--. 1 x x 5366 6 août 09:33 log.reconstructParMesh
-rw-rw-r--. 1 x x 796 6 août 09:33 log.simpleFoam
-rw-rw-r--. 1 x x 796 6 août 09:33 log.snappyHexMesh
-rw-rw-r--. 1 x x 3693 6 août 09:33 log.surfaceFeatureExtract
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor0
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor1
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor2
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor3
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor4
drwxrwxr-x. 4 x x 4096 6 août 09:33 processor5
drwxrwxr-x. 2 x x 4096 5 août 23:40 system
[motorBike]$

Just an additional question : is the complete run performed ?

Paul

paul18 August 6, 2013 04:17

bad news ...

When I open some log files, I've the error hereafter ; I need to spend more time in order to find the origin of the trouble ...

Paul

Quote:

--------------------------------------------------------------------------
It looks like opal_init failed for some reason; your parallel process is
likely to abort. There are many reasons that a parallel process can
fail during opal_init; some of which are due to configuration or
environment problems. This failure appears to be an internal failure;
here's some additional information (which may only be relevant to an
Open MPI developer):

opal_shmem_base_select failed
--> Returned value -1 instead of OPAL_SUCCESS
--------------------------------------------------------------------------
[VMware-linux1:26200] [[INVALID],INVALID] ORTE_ERROR_LOG: Error in file runtime/orte_init.c at line 79
[VMware-linux1:26200] [[INVALID],INVALID] ORTE_ERROR_LOG: Error in file orterun.c at line 694

paul18 August 6, 2013 04:37

after a research on the net, I found the following post:

http://www.cfd-online.com/Forums/ope...entos-5-a.html

"which mpi" shows it pointes to the mpi release coming with centFOAM (ThirdParty2.2.x) ;

What means ?

Code:

mpirun -np 4 -x LD_LIBRARY_PATH -x PATH -x WM_PROJECT_DIR -x WM_PROJECT_INST_DIR -x WM_OPTIONS -x FOAM_LIBBIN -x FOAM_APPBIN -x FOAM_USER_APPBIN -x MPI_BUFFER_SIZE interFoam -parallel

paul18 August 6, 2013 09:39

how stupid am I ... the answer is in the post !!!

Quote:

rm -rf $FOAM_EXT_LIBBIN/../../linux64Gcc/openmpi-1.6.3
cd $FOAM_INST_DIR/ThirdParty-2.2.x
./Allwmake

cd $FOAM_SRC/Pstream/dummy
wclean
cd ../mpi
wclean
cd ..
./Allwmake
@linnemann : many thanks for the supports and the great job you've doing with centFOAM

Regards

Paul


All times are GMT -4. The time now is 19:53.