Problem with libple.so.2

Hello,

Sorry I moved my post to the right section.

I have an error when I try to compute Mesh processing or solver with CS 7.2, I use Ubuntu 22.04 via a Virtual machine
The Mesh is done with Salome 9.9 export in Med format.

I have the following message in the console:
/home/julien/code_saturne/7.2.0/code_saturne-7.2.0/arch/Linux_x86_64/libexec/code_saturne/cs_solver: error while loading shared libraries: libple.so.2: cannot open shared object file: No such file or directory
solver script exited with status 127.

Thank you for your help

Best regards

Julien
compile.log (2.17 KB)
preprocessor.log (5.41 KB)

Hello,

The recommended info also includes the installation logs (at least config.log), and a short description of your system if possible.

Also, was this an initial install in a clean (empty) build and install directory, or a re-install ?

Best regards,

Yvan

Hello,

Thank you for your answer.
It is a fresh installation. I use VMware machine on a Windows 10 OS. Host is Ubuntu 22.04.
Code Saturne is 7.2 and Salome version is 9.9.

Below is my config.log file from this code saturne 7.2 build folder

Julien
config.log (197 KB)

Hi there,

I have the same problem. CS-7.2.0 in Ubuntu 22.04 native, hdf5/med/medcoupling from SALOME installation.
Besides libple, CS claims medcoupling library not found either. Now I am using it by

LD_LIBRARY_PATH=..... code_saturne ...

Best regards,
niuniuaba

Hello,

I’m not sure why there is this behavior on Ubuntu. I have noticed over the years that Ubuntu seems to have specific low-level linker settings, which make everything more difficult (i.e. more users have issues on Ubuntu than on any other Linux distribution, as you can see if you search this Forum’s posts for Ubuntu).

One related factor may be that PLE was switched from using libtool to simpler Makefile rules in code_saturne 7.1, and this was done for the main part of code_saturne itself only after v7.2, and some “implicit” expectations may not work on Ubuntu.
Depending on the library used, some “rpath” settings were or were not given. This should be more systematic in code_saturne v7.3, and can probably further be improved/automated.

I’ll run tests at least for code_saturne v7.3 on Ubuntu in the future.
In the meantime, the suggested workaround is a good solution.

Best regards,

Yvan

Hello,

Could you be more precise niuniuaba?
I have to modify the bashrc file in adding a path towards what?
Sorry I am not an experienced user of Linux.
Could you write a clear example of what you mean? Thank you

Best regards

Julien

Hello,

In your $HOME directory (/home/julien) there is a shell script named ‘.bashrc’. Add a line

alias code_saturne='LD_LIBRARY_PATH=/home/julien/code_saturne/7.2.0/code_saturne-7.2.0/arch/Linux_x86_64/lib:$LD_LIBRARY_PATH /home/julien/code_saturne/7.2.0/code_saturne-7.2.0/arch/Linux_x86_64/bin/code_saturne'

to this file, logout and login again, then you can use code_saturne command as usual.

Good luck.

Hello,

Thank you, it works now for single processor.

If I try with several processor I have the following message

"
Starting calculation

./cs_solver was built without MPI support,
so option “–mpi” may not be used.
solver script exited with status 1.

Error running the calculation.

Check run_solver.log and error* files for details.

Domain None (code_saturne):
run_solver.log, error*.

Post-calculation operations

Run failed in calculation stage.
"
Here is the run solver log file.
How can I resolve that?
I don’t have install Scotch and Parametis because I have some errors

Best regards

Julien
run_solver.log (557 Bytes)

Hello,

I see in a previous post of Yvan that Scotch and Parametis are not really important for a basic use.

https://discourse.simvia-app.fr/t/error-during-code-saturne-7-0-5-install-saturne-py/2196/1

I will try to switch to Debian OS

Best regards

Julien

Hello,

MPI should work on Ubuntu also. You need to make sure some MPI library is installed, then help the “configure” script either with the ‘–with-mpi’ option (to provide a path), or use “CC=mpixx CXX=mpicxx” (no need to change to use an MPI wrapper for Fortran, which does not directly call MPI).

On a relatively recent Debian system with OpenMPI packages installed, I need to add ‘–with-mpi=/usr/lib/x86_64-linux-gnu/openmpi’ for MPI to be detected. The path is probably similar on Ubuntu.

Regards,

Yvan

Hello Yvan,

I have the folder of OpenMPI installed in the same path than you : /usr/lib/x86_64-linux-gnu/openmpi

I try the command line:

Code_Saturne configure --with-mpi=/usr/lib/x86_64-linux-gnu/openmpi

but it doesnt do nothing, only the message with all the command associated with the use of CS.

The error when I try to run a case in parallel is stil the same.

Best regards

Julien

Hello,

I try the command line:

Code_Saturne configure --with-mpi=/usr/lib/x86_64-linux-gnu/openmpi

It sounds like you didn’t do it the right way. You have to rebuild code_saturne with mpi support before you can use it.

Step1: be sure you have necessary development packages installed:

sudo apt install libopenmpi-dev openmpi-bin

Step2: configure code_saturne with mpi support (please note the last 3 lines):

configure \
--prefix=/home/julien/code_saturne/7.2.0/code_saturne-7.2.0/arch/Linux_x86_64 \
--with-hdf5=/home/julien/code_saturne/7.2.0/hdf5-1.10.6/arch/Linux_x86_64 \
--with-cgns=/home/julien/code_saturne/7.2.0/cgns-4.3.0/arch/Linux_x86_64 \
--with-med=/home/julien/code_saturne/7.2.0/med-4.1.1/arch/Linux_x86_64 \
--without-metis \
--without-scotch \
PYTHON=/usr/bin/python3 \
--disable-static \
CXX=mpicxx \
CC=mpicc \
--with-mpi=/usr/lib/x86_64-linux-gnu/openmpi

Step3: make and make install as usual.

It should work. If not, give the error message or upload config.log again.

Good luck.

Hello,

Thank you for your help.

I have done

./configure
CXX=mpicxx
CC=mpicc
–with-mpi=/usr/lib/x86_64-linux-gnu/openmpi

make
make install (in admin mode)

But it still complains with the error

/cs_solver was built without MPI support,
so option “–mpi” may not be used.
solver script exited with status 1.
Error running the calculation.
Check run_solver.log and error* files for details.
Domain None (code_saturne):
run_solver.log, error*.

Here is the config.log file

Thank you very much

Julien

With the file
config.log (197 KB)

I have done

./configure
CXX=mpicxx
CC=mpicc
–with-mpi=/usr/lib/x86_64-linux-gnu/openmpi

No, you didn’t. Otherwise you have uploaded a wrong config.log.

make
make install (in admin mode)

Don’t install as root. Not necessary because you install to your own home directory
(-- refix=/home/julien/code_saturne/7.2.0/code_saturne-7.2.0/arch/Linux_x86_64) nor a good idea because there may be some side effects when you launch as ordinary user.

Hello,
I have start a fresh install of CS7.2. I try Debian but I have several freeze so I come back on Ubuntu.

I have follow each steps of this video

I have errors during installation.

See my config.log file.

What I have done wrong?

Best regards

Julien
config.log (16.9 KB)

Hello,

The important part in your config.log is here:

configure:4952: error: in `/home/julien/Code_Saturne/code_saturne-7.2.0.build':
configure:4954: error: C compiler cannot create executables
See `config.log' for more details

With, a few lines earlier:

configure:4883: checking whether the C compiler works
configure:4905: /usr/bin/mpicc    conftest.c  >&5
/usr/bin/ld: cannot find -lmpi: No such file or directory
/usr/bin/ld: cannot find -lopen-rte: No such file or directory
/usr/bin/ld: cannot find -lopen-pal: No such file or directory
/usr/bin/ld: cannot find -lhwloc: No such file or directory
/usr/bin/ld: cannot find -levent_core: No such file or directory
/usr/bin/ld: cannot find -levent_pthreads: No such file or directory

So it seems your “/usr/bin/mpicc” wrapper is not working. You may want to reinstall the Ubuntu MPI wrappers / packages.
Otherwise, try compiling any simple “hello world” C program (MPI or not) with it, and if it fails, this might be an Ubuntu packaging bug…

Best regards,

Yvan

Hello,

Did you try Step1~Step3 in my previous post? It should work for Ubuntu 22.04. But from your latest config.log it seems you didn’t. Without Step1, you won’t have compiler wrappers (/usr/bin/mpicc and /usr/bin/mpicxx) and mpi header files; withou setting ‘–with-mpi=/usr/lib/x86_64-linux-gnu/openmpi’ in Step3 the mpi library and header files won’t be found.

Best regards

Hello,

I have re-install properly CS7.2 on Ubuntu 22.10, everything works well none.

Thank you for your help.

Julien

As a “I have the same” comment, on Ubuntu I see the same problem. While not that big of a deal, if there was a general solution that fit into the install stage, it would be preferred; for now I just run “export LD_LIBRARY_PATH…” each time in a new shell, as I keep multiple versions on my machine, and anyway don’t like messing with bashrc unless necessary. With older code_saturne, it was never an issue.