Error on installation process (MED optional package )

All questions about installation
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
Tsubasa
Posts: 175
Joined: Fri Nov 20, 2020 4:09 am

Error on installation process (MED optional package )

Post by Tsubasa »

Hello,

I hope someone help me and give me tips.

I tried to install Code_saturne6.0.5 on Ubunts18.04 in Virtual Box.
I used an automated installer (install_saturne.py).

I found this problem when importing MED (med3.2, 3.3, 4.0) file into Code_saturne
because some errors happened.

"Preprocessor.log" indicated as following:

Code: Select all

/home/tsubasa/Code_Saturne/6.0.5/code_saturne-6.0.5/arch/Linux_x86_64/libexec/code_saturne/cs_preprocess 
--log --out mesh_input /home/tsubasa/Desktop/test/MESH/cube_med30.med 

  .------------------------------.
  |                              |
  |   Code_Saturne Preprocessor  |
  |                              |
  `------------------------------'

  code_saturne version 6.0.5   (built jeu. 19 nov. 2020 05:08:28 CET)


Error in preprocessor execution
===============================

/home/tsubasa/saturne/code_saturne-6.0.5/preprocessor/pre-post/ecs_pre.c:486: Fatal error.

File format "MED" support not available in this
installation (file "/home/tsubasa/Desktop/test/MESH/cube_med30.med"). 


Call stack 
   1: 0x55dde37d618a <ecs_pre__type_format+0x41a>     (cs_preprocess)
   2: 0x55dde37d1669 <ecs_cmd__lit_arg+0x3c9>         (cs_preprocess)
   3: 0x55dde37ceded <main+0x9d>                      (cs_preprocess)
   4: 0x7f0369d78bf7 <__libc_start_main+0xe7>         (libc.so.6)
   5: 0x55dde37cf76a <_start+0x2a>                    (cs_preprocess)
End of stack
I though this problem comes from the lack of MED package.
Therefore, I tried to install MED package in automatic installation process.
I edit a "setup" file in automatic installation process as following:

Code: Select all

#  Name    Use   Install  Path
#
hdf5       yes   yes       /home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64
cgns       yes   yes       /home/tsubasa/Code_Saturne/6.0.5/cgns-4.1.1/arch/Linux_x86_64
med        yes   yes      /home/tsubasa/Code_Saturne/6.0.5/med-4.0.0/arch/Linux_x86_64
scotch     yes   yes      /home/tsubasa/Code_Saturne/6.0.5/scotch-6.0.9/arch/Linux_x86_64
parmetis   yes   yes      /home/tsubasa/Code_Saturne/6.0.5/parmetis-4.0.3/arch/Linux_x86_64
#
#========================================================
and lunch installation:

Code: Select all

../code_saturne-6.0.5/install_saturne.py
However, terminal showed as following:

Code: Select all

tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build$ ../code_saturne-6.0.5/install_saturne.py 

        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.6
   o Checking for make...  /usr/bin/make


   HDF5 (Hierarchical Data Format)
   version: 1.10.6
   url: https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.10/hdf5-1.10.6/src/hdf5-1.10.6.tar.gz
   package: hdf5
   source_dir: None
   install_dir: /home/tsubasa/Code_Saturne/6.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/releases/hdf5-1.10/hdf5-1.10.6/src/hdf5-1.10.6.tar.gz
   package: hdf5
   source_dir: /home/tsubasa/saturne/code_saturne-6.0.5.build/hdf5-1.10.6
   install_dir: /home/tsubasa/Code_Saturne/6.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.1
   url: https://github.com/CGNS/CGNS/archive/v4.1.1.tar.gz
   package: cgns
   source_dir: None
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/cgns-4.1.1/arch/Linux_x86_64
   config_opts: -DCGNS_ENABLE_64BIT=ON -DCGNS_ENABLE_SCOPING=ON -DCGNS_ENABLE_HDF5=ON -DCMAKE_PREFIX_PATH=/home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64 -DHDF5_INCLUDE_PATH=/home/tsubasa/Code_Saturne/6.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.1
   url: https://github.com/CGNS/CGNS/archive/v4.1.1.tar.gz
   package: cgns
   source_dir: /home/tsubasa/saturne/code_saturne-6.0.5.build/CGNS-4.1.1
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/cgns-4.1.1/arch/Linux_x86_64
   config_opts: -DCGNS_ENABLE_64BIT=ON -DCGNS_ENABLE_SCOPING=ON -DCGNS_ENABLE_HDF5=ON -DCMAKE_PREFIX_PATH=/home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64 -DHDF5_INCLUDE_PATH=/home/tsubasa/Code_Saturne/6.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.0.0
   url: http://files.salome-platform.org/Salome/other/med-4.0.0.tar.gz
   package: med
   source_dir: None
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/med-4.0.0/arch/Linux_x86_64
   config_opts: --with-med_int=long --disable-fortran --disable-python --with-hdf5=/home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64

Extract of MED
Traceback (most recent call last):
  File "../code_saturne-6.0.5/install_saturne.py", line 1357, in <module>
    setup.install()
  File "../code_saturne-6.0.5/install_saturne.py", line 1105, in install
    p.extract()
  File "../code_saturne-6.0.5/install_saturne.py", line 295, in extract
    tar.extractall()
  File "/usr/lib/python2.7/tarfile.py", line 2083, in extractall
    self.extract(tarinfo, path)
  File "/usr/lib/python2.7/tarfile.py", line 2120, in extract
    self._extract_member(tarinfo, os.path.join(path, tarinfo.name))
  File "/usr/lib/python2.7/tarfile.py", line 2196, in _extract_member
    self.makefile(tarinfo, targetpath)
  File "/usr/lib/python2.7/tarfile.py", line 2236, in makefile
    with bltn_open(targetpath, "wb") as target:
IOError: [Errno 13] Permission denied: './med-4.0.0/doc/jpg/xmdump.jpg'
tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build$ 
I tried again after changing permission,

Code: Select all

tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build/med-4.0.0/doc$ chmod 777 -R jpg/
but terminal showed as following:

Code: Select all

tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build$ ../code_saturne-6.0.5/install_saturne.py 

        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.6
   o Checking for make...  /usr/bin/make


   HDF5 (Hierarchical Data Format)
   version: 1.10.6
   url: https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.10/hdf5-1.10.6/src/hdf5-1.10.6.tar.gz
   package: hdf5
   source_dir: None
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64
   config_opts: --enable-build-mode=production


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


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

Extract of MED
Installation of MED

   MED (Model for Exchange of Data)
   version: 4.0.0
   url: http://files.salome-platform.org/Salome/other/med-4.0.0.tar.gz
   package: med
   source_dir: /home/tsubasa/saturne/code_saturne-6.0.5.build/med-4.0.0
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/med-4.0.0/arch/Linux_x86_64
   config_opts: --with-med_int=long --disable-fortran --disable-python --with-hdf5=/home/tsubasa/Code_Saturne/6.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.
tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build$
:install_saturne.log: showed as following

Code: Select all

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether UID '1000' is supported by ustar format... yes
checking whether GID '1000' is supported by ustar format... yes
checking how to create a ustar tar archive... gnutar
configure: Trying /home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64 home path for searching H5pubconf.h file.
checking for a sed that does not truncate output... /bin/sed
checking whether to compile C using MPI... no
checking for style of include used by make... GNU
checking for gcc... /usr/bin/cc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether /usr/bin/cc accepts -g... yes
checking for /usr/bin/cc option to accept ISO C89... none needed
checking whether /usr/bin/cc understands -c and -o together... yes
checking dependency style of /usr/bin/cc... gcc3
checking for /usr/bin/cc option to accept ISO C99... none needed
checking whether to compile FC using MPI... no
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
configure: HDF version is not a parallel one.
checking for grep that handles long lines and -e... /bin/grep
checking how to run the C preprocessor... /usr/bin/cc -E
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking absolute name of <H5public.h>... checking H5public.h usability... yes
checking H5public.h presence... yes
checking for H5public.h... yes
///home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64/include/H5public.h
checking absolute name of <H5Ipublic.h>... checking H5Ipublic.h usability... yes
checking H5Ipublic.h presence... yes
checking for H5Ipublic.h... yes
///home/tsubasa/Code_Saturne/6.0.5/hdf5-1.10.6/arch/Linux_x86_64/include/H5Ipublic.h
checking for H5open in -lhdf5... no
configure: error: Can't find hdf5 library, either use HDF5HOME env. var. , --with-hdf5=<path> or --with-hdf5-lib=<libpath>
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error on installation process (MED optional package )

Post by Yvan Fournier »

Hello,

Is this failure in the MED installation stage ? You may check or post the matching "config.log" in the MED build directory, but a common cause of failure is "missing denpedencies". You can check for recommended/required prerequisites here: https://github.com/code-saturne/code_sa ... n-packages.

For MED and HDF5, you are probably missing the "zlib" development headers (zlib1g-dev under Debian and Ubuntu).

Best regards,

Yvan
Tsubasa
Posts: 175
Joined: Fri Nov 20, 2020 4:09 am

Re: Error on installation process (MED optional package )

Post by Tsubasa »

Thank you for your reply.

As you said, I missed "zlib1g-dev". Thank you.

With "zlib1g-dev", I suceeded the MED installation.
However, another problem happened in "Scotch" installation as following,

Code: Select all

scotch (PT-Scotch)
   version: 6.0.9
   url: https://gforge.inria.fr/frs/download.php/file/38187/scotch_6.0.9.tar.gz
   package: scotch
   source_dir: None
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/scotch-6.0.9/arch/Linux_x86_64
   config_opts: 

Extract of scotch
Installation of scotch

   scotch (PT-Scotch)
   version: 6.0.9
   url: https://gforge.inria.fr/frs/download.php/file/38187/scotch_6.0.9.tar.gz
   package: scotch
   source_dir: /home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9
   install_dir: /home/tsubasa/Code_Saturne/6.0.5/scotch-6.0.9/arch/Linux_x86_64
   config_opts: 

   o Compile...
   o Install...
   o Clean...
   o Compile...
Error during compile stage of scotch.
See install_saturne.log for more information.
tsubasa@tsubasa-VirtualBox:~/saturne/code_saturne-6.0.5.build$ 
Install_saturne.log showed as following

Code: Select all

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables.
.
.
.
.
.
.
make[2]: Entering directory '/home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9.build/src/libscotch'
make[2]: 'scotch.h' is up to date.
make[2]: 'scotchf.h' is up to date.
make[2]: 'libscotch.so' is up to date.
make[2]: 'libscotcherr.so' is up to date.
make[2]: 'libscotcherrexit.so' is up to date.
make[2]: Leaving directory '/home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9.build/src/libscotch'
make 					\
				CC="/usr/bin/cc"					\
				CFLAGS="-O3 -fPIC -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME  -Drestrict=__restrict -DIDXSIZE64 -DINTSIZE64 -DSCOTCH_PTSCOTCH"		\
				CCDFLAGS="-O3 -fPIC -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME  -Drestrict=__restrict -DIDXSIZE64 -DINTSIZE64 -DSCOTCH_PTSCOTCH"	\
				ptscotch.h					\
				ptscotchf.h					\
				libptscotch.so				\
				libptscotcherr.so				\
				libptscotcherrexit.so
make[2]: Entering directory '/home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9.build/src/libscotch'
/usr/bin/cc -O3 -fPIC -DCOMMON_FILE_COMPRESS_GZ -DCOMMON_PTHREAD -DCOMMON_RANDOM_FIXED_SEED -DSCOTCH_RENAME  -Drestrict=__restrict -DIDXSIZE64 -DINTSIZE64 -DSCOTCH_PTSCOTCH -DSCOTCH_VERSION_NUM=6 -DSCOTCH_RELEASE_NUM=0 -DSCOTCH_PATCHLEVEL_NUM=9 dummysizes.c -o ptdummysizes -lz -lm -lrt -pthread -Xlinker --no-as-needed
In file included from dummysizes.c:92:0:
common.h:123:21: fatal error: mpi.h: No such file or directory
 #include            <mpi.h>
                     ^~~~~~~
compilation terminated.
Makefile:3077: recipe for target 'ptdummysizes' failed
make[2]: *** [ptdummysizes] Error 1
make[2]: Leaving directory '/home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9.build/src/libscotch'
Makefile:72: recipe for target 'ptscotch' failed
make[1]: *** [ptscotch] Error 2
make[1]: Leaving directory '/home/tsubasa/saturne/code_saturne-6.0.5.build/scotch_6.0.9.build/src/libscotch'
Makefile:103: recipe for target 'libptscotch' failed
make: *** [libptscotch] Error 2
What cause this problem?

Thank you
Tsubasa
Posts: 175
Joined: Fri Nov 20, 2020 4:09 am

Re: Error on installation process (MED optional package )

Post by Tsubasa »

This error can be solved by an instruction here:

Code: Select all

https://www.youtube.com/watch?v=iwke0YRpMrE
Thank you.
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error on installation process (MED optional package )

Post by Yvan Fournier »

Hello,

Yes, this new tutorial was made by a colleague, also from the dev team. Glad it is useful.

To improve the documentation, was a package missing from the list on GitHub, or was another step missing on your side ?

Best regards,

Yvan
Tsubasa
Posts: 175
Joined: Fri Nov 20, 2020 4:09 am

Re: Error on installation process (MED optional package )

Post by Tsubasa »

Actually, I'm not sure what cause this problem.

I tried again from the beginning (I deleted VM box and tried again.)

First, after installing prerequsite, I followed your video, but completely same error happeded.
So, next I followed another instruction video : https://www.youtube.com/watch?v=PgJUA3MwpOk&t=1289s
but even followed this video, same problem happened.

However, I tried again your video: https://www.youtube.com/watch?v=iwke0YRpMrE&t=3s
I suceeded for whatever reason.

I also want to kwnow what missed and what the important factor is to suceeded installation.
Tsubasa
Posts: 175
Joined: Fri Nov 20, 2020 4:09 am

Re: Error on installation process (MED optional package )

Post by Tsubasa »

Also if I were to say,
I hope you will add information that
""after installation process, you have to runs the code:

Code: Select all

export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"
.
Otherwise, sometimes error occured in preprocessing process.

Please look here: viewtopic.php?f=2&t=2742
Yvan Fournier
Posts: 4070
Joined: Mon Feb 20, 2012 3:25 pm

Re: Error on installation process (MED optional package )

Post by Yvan Fournier »

Hello,

Could you describe the problems you encounter and provide the details listed in the forum recommendations ?

Without sufficient details, it is not easy to help you.

Regards,

Yvan
Post Reply