Project

General

Profile

hdf5 library undefined when installing with apt vs building from source

Added by Stanley Glidden 3 months ago

I would like install CDO running on Linux Ubuntu 22.04, using apt-get because it is easier then building it from source. However I am concerned with what it reports about HDF when I install it with apt vs building from source.

Should I be concerned that it reports: hdf5 library version : library undefined when installed with apt.

Also I see that it reports that it is threadsafe when installed from source, but does not when installed with apt.

I assume that also means that it is not threadsafe when installed with apt.

Thanks.

Using Apt
---------
cdo -VClimate Data Operators version 2.0.4 (https://mpimet.mpg.de/cdo)
System: x86_64-pc-linux-gnu
CXX Compiler: g++ -std=gnu++14 -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security -fopenmp -pthread
CXX version : g++ (Ubuntu 11.2.0-16ubuntu1) 11.2.0
C Compiler: gcc -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security -Wall -pedantic -fPIC -fopenmp -pthread -pthread
C version : gcc (Ubuntu 11.2.0-16ubuntu1) 11.2.0
F77 Compiler: f77 -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong
F77 version : GNU Fortran (Ubuntu 11.2.0-16ubuntu1) 11.2.0
Features: 251GB 32threads C++14 OpenMP45 Fortran PTHREADS HDF5 NC4/HDF5/threadsafe OPeNDAP SZ UDUNITS2 PROJ MAGICS CURL FFTW3 SSE2
Libraries: HDF5/1.10.7 proj/8.2.1 curl/7.81.0 magics/4.10.1
CDI data types: SizeType=size_t DateType=int64_t
CDI file types: srv ext ieg grb1 grb2 nc1 nc2 nc4 nc4c nc5
CDI library version : 2.0.4
ecCodes library version : 2.24.2
NetCDF library version : 4.8.1 of Sep 29 2021 09:36:14 $
hdf5 library version : library undefined
exse library version : 1.4.2
FILE library version : 1.9.1

Building from source
--------------------
cdo -V
Climate Data Operators version 2.0.2 (https://mpimet.mpg.de/cdo)
System: x86_64-pc-linux-gnu
CXX Compiler: g++ -std=gnu++14 -g -O2 -fopenmp -pthread
CXX version : g++ (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
C Compiler: gcc -g -O2 -fopenmp -pthread -pthread
C version : gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
F77 Compiler:
Features: 251GB 32threads C++14 OpenMP45 PTHREADS HDF5 NC4/HDF5/threadsafe OPeNDAP SSE2
Libraries: HDF5/1.10.7
CDI data types: SizeType=size_t DateType=int64_t
CDI file types: srv ext ieg grb1 nc1 nc2 nc4 nc4c nc5
CDI library version : 2.0.2
cgribex library version : 2.0.0
NetCDF library version : 4.8.1 of Sep 29 2021 09:36:14 $
hdf5 library version : 1.10.7 threadsafe
exse library version : 1.4.2
FILE library version : 1.9.1


Replies (9)

RE: hdf5 library undefined when installing with apt vs building from source - Added by Ralf Mueller 3 months ago

hi!

the installation/building procedure of debian which is the basis of ubuntu are complex. If the threadsafe feature is not correctly reported, you can still check the version used by the system binary with

ldd /usr/bin/cdo
The output will tell u the shared object loaded by CDO.

I personally would not worry too much. In case u run into strange errors, you can add -L as a command line options. CDO will serialize the relevant IO internally so that normal operations are possible with a non-threadsafe installation of hdf5. if in doubt, please check the package database of ubuntu regarding CDO and its dependenies.

have a nice weekend
ralf

RE: hdf5 library undefined when installing with apt vs building from source - Added by Estanislao Gavilan 3 months ago

Hi,

I got that type of error before with the curl library. You probably have two hdf5 versions installed in your computer. That is why cdo cannot find the version.

Estanislao

RE: hdf5 library undefined when installing with apt vs building from source - Added by Stanley Glidden 3 months ago

I checked with ldd and the version seems the same in both installs, so perhaps everything is fine. I will still check if I have multiple versions of hdf5 installed. Thanks for the suggestons.

RE: hdf5 library undefined when installing with apt vs building from source - Added by Estanislao Gavilan 3 months ago

Hi Stanley,

try to type

apt list --installed hdf*

it should appear the apt hdf installations

RE: hdf5 library undefined when installing with apt vs building from source - Added by Stanley Glidden 3 months ago

sure here is what I got:
apt list --installed hdf*
Listing... Done
hdf5-helpers/focal,now 1.10.4+repack-11ubuntu1 amd64 [installed,automatic]
hdf5-tools/focal,now 1.10.4+repack-11ubuntu1 amd64 [installed]

The only hdf install I believe I did was:
apt-get install -y libhdf5-dev

RE: hdf5 library undefined when installing with apt vs building from source - Added by Stanley Glidden 3 months ago

Sorry, disregard that, I looked at the wrong system:

For the install that shows hdf5 library version : library undefined

I get:
apt list --installed hdf*
Listing... Done
hdf5-helpers/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]

RE: hdf5 library undefined when installing with apt vs building from source - Added by Stanley Glidden 3 months ago

Went back and confirmed:
The hdf library was installed before cdo as a result of:

apt-get install -y libhdf5-dev

... Setting up libhdf5-103-1:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-cpp-103-1:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-hl-100:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-hl-cpp-100:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-fortran-102:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-hl-fortran-100:amd64 (1.10.7+repack-4ubuntu2) ...
Setting up libhdf5-dev (1.10.7+repack-4ubuntu2) ...
update-alternatives: using /usr/lib/x86_64-linux-gnu/pkgconfig/hdf5-serial.pc to provide /usr/lib/x86_64-linux-gnu/pkgconfig/hdf5.pc (hdf5.pc) in auto mode
Processing triggers for libc-bin (2.35-0ubuntu3.6) ...

Singularity> apt list --installed libhdf*
Listing... Done
libhdf5-103-1/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-cpp-103-1/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-dev/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed]
libhdf5-fortran-102/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-hl-100/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-hl-cpp-100/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-hl-fortran-100/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]

RE: hdf5 library undefined when installing with apt vs building from source - Added by Stanley Glidden 3 months ago

Went back to clean install of Ubuntu 22.04

Installed cdo with apt-get install cdo

Result after the install of cdo was:

apt list --installed hdf
Listing... Done
libhdf5-103-1/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]
libhdf5-hl-100/jammy,now 1.10.7+repack-4ubuntu2 amd64 [installed,automatic]

Still get undefined for the hdf5 library reported:
cdo -V
Climate Data Operators version 2.0.4 (https://mpimet.mpg.de/cdo)
System: x86_64-pc-linux-gnu
CXX Compiler: g++ -std=gnu++14 -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security -fopenmp -pthread
CXX version : g++ (Ubuntu 11.2.0-16ubuntu1) 11.2.0
C Compiler: gcc -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security -Wall -pedantic -fPIC -fopenmp -pthread -pthread
C version : gcc (Ubuntu 11.2.0-16ubuntu1) 11.2.0
F77 Compiler: f77 -g -O2 -ffile-prefix-map=/build/cdo-hTyRvi/cdo-2.0.4=. -flto=auto -ffat-lto-objects -flto=auto -ffat-lto-objects -fstack-protector-strong
F77 version : GNU Fortran (Ubuntu 11.2.0-16ubuntu1) 11.2.0
Features: 251GB 32threads C++14 OpenMP45 Fortran PTHREADS HDF5 NC4/HDF5/threadsafe OPeNDAP SZ UDUNITS2 PROJ MAGICS CURL FFTW3 SSE2
Libraries: HDF5/1.10.7 proj/8.2.1 curl/7.81.0 magics/4.10.1
CDI data types: SizeType=size_t DateType=int64_t
CDI file types: srv ext ieg grb1 grb2 nc1 nc2 nc4 nc4c nc5
CDI library version : 2.0.4
ecCodes library version : 2.24.2
NetCDF library version : 4.8.1 of Sep 29 2021 09:36:14 $
hdf5 library version : library undefined
exse library version : 1.4.2
FILE library version : 1.9.1

As said earlier, just a library reporting problem I guess, because it shows Libraries: HDF5/1.10.7 proj/8.2.1 curl/7.81.0 magics/4.10.1

RE: hdf5 library undefined when installing with apt vs building from source - Added by Estanislao Gavilan 3 months ago

Hi Stanley,

I have the same output in my virtual machine (ubuntu 22). So do not pay much attention. My cdo 2.0.4 works perfectly fine

    (1-9/9)