error during ../code_saturne-7.0.5/install_saturne.py

All questions about installation
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

Hello,
I am trying to install code_saturne according to https://www.youtube.com/watch?v=iwke0YRpMrE
but the installation fails.


Installation of Code_Saturne
____________________________

The process will take several minutes.
You can have a look at the log file meanwhile.

Check the setup file and some utilities presence.

o Checking for cc... /usr/bin/cc
o Checking for f95... /usr/bin/f95
o Checking for python3... /usr/bin/python3
Python version is 3.8
o Checking for make... /usr/bin/make

Download of HDF5
(https://support.hdfgroup.org/ftp/HDF5/r ... 0.6.tar.gz)
Download of CGNS
(https://github.com/CGNS/CGNS/archive/v4.1.2.tar.gz)
Download of MED
(http://files.salome-platform.org/Salome ... 1.0.tar.gz)
Download of scotch
(https://gitlab.inria.fr/scotch/scotch/- ... 1.0.tar.gz)
Download of parmetis
(http://glaros.dtc.umn.edu/gkhome/fetch/ ... 0.3.tar.gz)
Traceback (most recent call last):
File "/usr/lib/python3.8/urllib/request.py", line 1354, in do_open
h.request(req.get_method(), req.selector, req.data, headers,
File "/usr/lib/python3.8/http/client.py", line 1256, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1302, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1251, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "/usr/lib/python3.8/http/client.py", line 1011, in _send_output
self.send(msg)
File "/usr/lib/python3.8/http/client.py", line 951, in send
self.connect()
File "/usr/lib/python3.8/http/client.py", line 922, in connect
self.sock = self._create_connection(
File "/usr/lib/python3.8/socket.py", line 808, in create_connection
raise err
File "/usr/lib/python3.8/socket.py", line 796, in create_connection
sock.connect(sa)
TimeoutError: [Errno 110] Connection timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "../code_saturne-7.0.5/install_saturne.py", line 1354, in <module>
setup.install()
File "../code_saturne-7.0.5/install_saturne.py", line 1092, in install
p.download()
File "../code_saturne-7.0.5/install_saturne.py", line 246, in download
urllib.request.urlretrieve(self.url, self.archive)
File "/usr/lib/python3.8/urllib/request.py", line 247, in urlretrieve
with contextlib.closing(urlopen(url, data)) as fp:
File "/usr/lib/python3.8/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python3.8/urllib/request.py", line 525, in open
response = self._open(req, data)
File "/usr/lib/python3.8/urllib/request.py", line 542, in _open
result = self._call_chain(self.handle_open, protocol, protocol +
File "/usr/lib/python3.8/urllib/request.py", line 502, in _call_chain
result = func(*args)
File "/usr/lib/python3.8/urllib/request.py", line 1383, in http_open
return self.do_open(http.client.HTTPConnection, req)
File "/usr/lib/python3.8/urllib/request.py", line 1357, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [Errno 110] Connection timed out>

I would appreciate any help.
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

I tried replacing

self.packages['parmetis'] = \
Package(name="parmetis",
description="ParMETIS",
package="parmetis",
version="4.0.3",
archive="parmetis_4.0.3.orig.tar.gz",
url="https://launchpad.net/ubuntu/+archive/p ... 4.0.3-4/%s")

in install_saturne.py but now I got this error


Installation of Code_Saturne
____________________________

The process will take several minutes.
You can have a look at the log file meanwhile.

Check the setup file and some utilities presence.

o Checking for cc... /usr/bin/cc
o Checking for f95... /usr/bin/f95
o Checking for python3... /usr/bin/python3
Python version is 3.8
o Checking for make... /usr/bin/make

Download of HDF5
(https://support.hdfgroup.org/ftp/HDF5/r ... 0.6.tar.gz)
Download of CGNS
(https://github.com/CGNS/CGNS/archive/v4.1.2.tar.gz)
Download of MED
(http://files.salome-platform.org/Salome ... 1.0.tar.gz)
Download of scotch
(https://gitlab.inria.fr/scotch/scotch/- ... 1.0.tar.gz)
Download of parmetis
(https://launchpad.net/ubuntu/+archive/p ... rig.tar.gz)


HDF5 (Hierarchical Data Format)
version: 1.10.6
url: https://support.hdfgroup.org/ftp/HDF5/r ... 0.6.tar.gz
package: hdf5
source_dir: None
install_dir: /home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64
config_opts: --enable-build-mode=production

Extract of HDF5
Installation of HDF5

HDF5 (Hierarchical Data Format)
version: 1.10.6
url: https://support.hdfgroup.org/ftp/HDF5/r ... 0.6.tar.gz
package: hdf5
source_dir: /home/vojta/Code_Saturne/code_saturne.build/hdf5-1.10.6
install_dir: /home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64
config_opts: --enable-build-mode=production

o Configure...
o Compile...
o Install...
o Clean...


CGNS (CFD General Notation System)
version: 4.1.2
url: https://github.com/CGNS/CGNS/archive/v4.1.2.tar.gz
package: cgns
source_dir: None
install_dir: /home/vojta/Code_Saturne/7.0.5/cgns-4.1.2/arch/Linux_x86_64
config_opts: -DCGNS_ENABLE_64BIT=ON -DCGNS_ENABLE_SCOPING=ON -DCGNS_ENABLE_HDF5=ON -DCMAKE_PREFIX_PATH=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64 -DHDF5_INCLUDE_PATH=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64/include

Extract of CGNS
Installation of CGNS

CGNS (CFD General Notation System)
version: 4.1.2
url: https://github.com/CGNS/CGNS/archive/v4.1.2.tar.gz
package: cgns
source_dir: /home/vojta/Code_Saturne/code_saturne.build/CGNS-4.1.2
install_dir: /home/vojta/Code_Saturne/7.0.5/cgns-4.1.2/arch/Linux_x86_64
config_opts: -DCGNS_ENABLE_64BIT=ON -DCGNS_ENABLE_SCOPING=ON -DCGNS_ENABLE_HDF5=ON -DCMAKE_PREFIX_PATH=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64 -DHDF5_INCLUDE_PATH=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64/include

o Configure...
o Compile...
o Install...
o Clean...


MED (Model for Exchange of Data)
version: 4.1.0
url: http://files.salome-platform.org/Salome ... 1.0.tar.gz
package: med
source_dir: None
install_dir: /home/vojta/Code_Saturne/7.0.5/med-4.1.0/arch/Linux_x86_64
config_opts: --with-med_int=long --disable-fortran --disable-python --with-hdf5=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64

Extract of MED
Installation of MED

MED (Model for Exchange of Data)
version: 4.1.0
url: http://files.salome-platform.org/Salome ... 1.0.tar.gz
package: med
source_dir: /home/vojta/Code_Saturne/code_saturne.build/med-4.1.0
install_dir: /home/vojta/Code_Saturne/7.0.5/med-4.1.0/arch/Linux_x86_64
config_opts: --with-med_int=long --disable-fortran --disable-python --with-hdf5=/home/vojta/Code_Saturne/7.0.5/hdf5-1.10.6/arch/Linux_x86_64

o Configure...
Error during configure stage of MED.
See install_saturne.log for more information.
Yvan Fournier
Posts: 3814
Joined: Mon Feb 20, 2012 3:25 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by Yvan Fournier »

Hello,

The error seems to be in MED installation. Could you post the full install_saturne.log file so I can check what is wrong ?
We might simply need to adjust some build options for MED depending on your type of Linu distribution.

What Linux distribution are you running on ?

Regards,

Yvan
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

Hello, thanks for reply.

doing sudo apt-get install libhdf5-serial-dev


solved the problem, but I had to do

hdf5 yes yes None
cgns yes yes None
med yes yes None
scotch no no None
parmetis no no None

but someone should check the parmetis tar, because it does not work. That caused the first problem.
Download of parmetis
(http://glaros.dtc.umn.edu/gkhome/fetch/ ... 0.3.tar.gz

when installing scotch error occurred too

My whole installation process on wsl2

sudo apt-get update

sudo apt-get install build-essential

sudo apt-get install gfortran

sudo apt-get install gcc

sudo apt-get install g++

sudo apt-get install make
sudo apt-get install cmake

sudo apt-get install python

sudo apt-get install python3

sudo apt install python3-pyqt5
sudo apt install pyqt5-dev-tools pyqt5-dev
sudo apt-get install libhdf5-serial-dev

mkdir Code_Saturne
cd Code_Saturne

wget https://www.code-saturne.org/releases/c ... 0.5.tar.gz

sudo tar -xvzf code_saturne-7.0.5.tar.gz

mkdir code_saturne.build

cd code_saturne.build

../code_saturne-7.0.5/install_saturne.py

#edit setup

../code_saturne-7.0.5/install_saturne.py


Do I need scotch and parmetis? Code saturne gui runs fine so far.
Last edited by jacob on Sun Sep 04, 2022 10:05 am, edited 1 time in total.
Yvan Fournier
Posts: 3814
Joined: Mon Feb 20, 2012 3:25 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by Yvan Fournier »

Hello,

Both PT-SCOTCH and ParMetis are optional, as code_saturne allso has a build-in (space-filling curve based) partitioner. On a cluster, they often (not always) allow improved performance through better partitioning quality, but on a workstation, they probably do not make much difference, so you'll be fine without them.

Best regards,

Yvan
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

Okay, thank you.

Nevertheless, some developer should check the parmetis link because it does not work.
Yvan Fournier
Posts: 3814
Joined: Mon Feb 20, 2012 3:25 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by Yvan Fournier »

Hello,

Yes, the link does not work anymore, ParMetis is now hosted on GitHub, but does not have any tags/releases yet, and its license is still restrictive (limited to academia, evaluation, or requires explicit permission), so I simply removed it from the installer, since the default choices led to it barely ever being used.

It is still supported by code_saturne, for those that install it on their own.

Thanks for the feedback.

Best regards,

Yvan
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

Hello, so I tried running my first study but got error


/home/vojta/Code_Saturne/7.0.5/code_saturne-7.0.5/arch/Linux_x86_64/libexec/code_saturne/cs_solver: error while loading shared libraries: libhdf5.so.103: cannot open shared object file: No such file or directory
Post-calculation operations
---------------------------

solver script exited with status 127.

Error running the calculation.

Check code_saturne log (listing) and error* files for details.

Error in calculation stage.


How to get this libhdf5.so.103 ?
jacob
Posts: 16
Joined: Fri Sep 02, 2022 5:29 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by jacob »

solved by running

export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"

before code_saturne gui
Yvan Fournier
Posts: 3814
Joined: Mon Feb 20, 2012 3:25 pm

Re: error during ../code_saturne-7.0.5/install_saturne.py

Post by Yvan Fournier »

Hello,

Thanks for the feedfack. I have found where that issue comes from, and fixed it on the main development branch. I'll wait for a bit of feedback before merging in to v7.0.

And in any case other users can use LD_LIBRARY_PATH as you did in the meantime.

Best regards,

Yvan
Post Reply