CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   SBATCH decomposePar error (https://www.cfd-online.com/Forums/openfoam-solving/239578-sbatch-decomposepar-error.html)

saidc. November 12, 2021 14:34

SBATCH decomposePar error
 
1 Attachment(s)
Hi,

This is my first run with server. I've a good looking test slurm file down below. Meshing goes well but I can't decompose the case. Other than that, all other lines work fine. I mean, if I decompose the case on my PC and upload to the server everything runs smoothly.

Code:

decomposePar: error while loading shared libraries: libmetis.so: cannot open shared object file: No such file or directory
Also I found metis source/export in the main directory of openfoam. I searched for the issue but couldn't find anything so this is probably not a bug, it could be due to my lack of knowledge.

I'm open to any suggestions. Files are attached.

Kind regards,
Said.

s1291 November 12, 2021 15:24

What is the output of:
Code:

module spider openfoam

saidc. November 12, 2021 15:52

Hi s1291,

Output is:

Code:

cmdTrace.c(713):ERROR:104: 'spider' is an unrecognized subcommand
cmdModule.c(411):ERROR:104: 'spider' is an unrecognized subcommand

Kind regards,
Said.

s1291 November 12, 2021 16:05

My guess is that you're using Tcl modules instead of Lmod. nevertheless, what is the output of:

Code:

module avail 2>&1 | grep -i openfoam
and
Code:

module avail 2>&1 | grep -i metis

saidc. November 12, 2021 16:13

openfoam exist on the list "module avail" but metis not on the list. Also there is no output for both lines, just returns nothing. If I type "module avail" I can see the "centos7.3/app/openfoam/v1912" module.

Edit:

Code:

-bash-4.2$ module avail 2>&1 | grep -i openfoam
centos7.3/app/openfoam/8
centos7.3/app/openfoam/v1912
-bash-4.2$ module avail 2>&1 | grep -i metis
-bash-4.2$


s1291 November 12, 2021 16:18

Another question:
  • Why you are sourcing OpenFOAM etc/bashrc before loading it using module load ... ?

saidc. November 12, 2021 16:33

I copied that part from server's example slurm file, now I tried to run with switch them but nothing changed. I'm still getting the same error.

saidc. November 13, 2021 04:55

Hi,

I solved the previous problem with sourcing everything in the slurm file but now I can't use restore0Dir command. It is not working.

Code:

/tmp/slurmd/job7894762/slurm_script: line 235: restore0Dir: command not found
What is the reason of this?

Kind regards,
Said.

s1291 November 13, 2021 06:55

That command is not necessary. But you can use it after sourcing the RunFunctions script:

Code:

source ${WM_PROJECT_DIR}/bin/tools/RunFunctions
Now, the command restore0Dir (in fact it is a shell function) should be available.

saidc. November 13, 2021 07:51

Quote:

Originally Posted by s1291 (Post 816451)
That command is not necessary. But you can use it after sourcing the RunFunctions script:

Code:

source ${WM_PROJECT_DIR}/bin/tools/RunFunctions
Now, the command restore0Dir (in fact it is a shell function) should be available.

As you said that line solved the problem:

Code:

source /truba/sw/centos7.3/app/openfoam/OpenFOAM-v1912/bin/tools/RunFunctions
Thanks a lot but I wonder how to construct 0 directories in the processor files without restore0Dir command?

Kind regards,
Said.

saidc. November 13, 2021 15:07

1 Attachment(s)
Hi again,

I thought the problem was solved but changeDictionary can not import boundary conditions to processor files correctly. I searched for the reason for this but couldn't find a solution.

Code:

[4] --> FOAM FATAL ERROR:
[4] cannot be called for a calculatedFvPatchField
    on patch H_spheres1 of field U in file "/truba/home/tbag100/openfoam_run/simulation_1/processor4/0/U"
    You are probably trying to solve for a field with a default boundary condition.
[4]
[4]    From function Foam::tmp<Foam::Field<Type> > Foam::calculatedFvPatchField<Type>::gradientInternalCoeffs() const [with Type = Foam::Vector<double>]
[4]    in file fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C at line 188.
[4]
FOAM parallel run aborting

SLURM
Code:

ideasUnvToFoam Mesh_Simulation_1.unv > log.ideasUnvToFoam 2>&1

transformPoints -scale "(0.001)" > log.transformPoints 2>&1

createPatch -overwrite > log.createPatch 2>&1

decomposePar > log.decomposePar 2>&1

source /truba/sw/centos7.3/app/openfoam/OpenFOAM-v1912/bin/tools/RunFunctions
restore0Dir -processor

mpirun changeDictionary -parallel > log.changeDictionary 2>&1

mpirun buoyantPimpleFoam -parallel > log.buoyantPimpleFoam 2>&1

reconstructPar > log.reconstructPar 2>&1

processor0/0 and log files are attached. Any help would be much appreciated.

Edit:
I figured it out how to fix it. I just used restore0Dir and changeDictionary (serial) before the decomposition. Right now everythings works fine for me.


Kind regards,
Said.


All times are GMT -4. The time now is 15:44.