Top Page > Past log > Browsing
installation error openmx 3.9
Date: 2020/05/27 02:50
Name: Altan

Hello,
I am trying to install openmx3.9 with the following environment on ubuntu 20.04 and fedora 32.

MKLROOT = /opt/intel/mkl
CC = mpicc -O3 -xHOST -ip -no-prec-div -qopenmp -I/opt/intel/mkl/include/fftw
FC = mpif90 -O3 -xHOST -ip -no-prec-div -qopenmp
LIB= -L${MKLROOT}/lib/intel64 -lmkl_scalapack_lp64 -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lmkl_blacs_openmpi_lp64 -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_
mpifh -liomp5 -lpthread -lm -ldl

I receive the same error for both of them.
Here is the message:

asa@asa-VirtualBox:~/Documents/openmx/openmx3.9/openmx3.9/source$ make
mpicc -O3 -xHOST -ip -no-prec-div -qopenmp -I/opt/intel/mkl/include/fftw -I./elpa-2018.05.001 -c openmx.c
gcc: error: unrecognized command line option e-ipf; did you mean e-pf?
gcc: error: unrecognized command line option e-no-prec-divf
gcc: error: unrecognized command line option e-qopenmpf; did you mean e-fopenmpf?
make: *** [makefile:193: openmx.o] Error 1


I am not familiar with linux enviroment, so anything could be wrong.
My intention is to calculate jexc parameter, and I have no problem to change linux distributon if it will be done in a few clicks or lines.

Please let me know if you need to know anything else.
Page: [1]

Re: installation error openmx 3.9 ( No.1 )
Date: 2020/05/27 05:20
Name: Naoya Yamaguchi

Hi,

The default setting is for environments using Intel compilers.
The following is one of the simplest settings for Debian, and it may also be available in Ubuntu.

CC = mpicc -O3 -fopenmp -ffast-math
FC = mpif90 -O3 -fopenmp -ffast-math
LIB= -lscalapack-openmpi -llapack -lblas -lfftw3 -lmpi -lmpi_mpifh -lgfortran

You may need to get some packages using apt as follows:
$ sudo apt install build-essential libfftw3-dev libscalapack-mpi-dev liblapack-dev libopenblas-dev
(The above is for Debian, and names of some packages may be different between Ubuntu and Debian.)

Of course, if you make performances of OpenMX better, you can set more appropriate optimization options.

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.2 )
Date: 2020/05/27 08:16
Name: Altan

Dear Naoya Yamaguchi,
Thank you for your reply.

I run this commad:
sudo apt install build-essential libfftw3-dev libscalapack-mpi-dev liblapack-dev libopenblas-dev


change enviroment with the following


CC = mpicc -O3 -fopenmp -ffast-math
FC = mpif90 -O3 -fopenmp -ffast-math
LIB= -lscalapack-openmpi -llapack -lblas -lfftw3 -lmpi -lmpi_mpifh -lgfortran


and then make

but an error message is poped up.

the last part of the output is pasted below. (There is character limit)
You can find the error message at the end.


LAST PART OF THE OUTPUT OF MAKE
================================

mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/elpa2_determine_workload.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_redist_band_real.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_redist_band_complex.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_pack_unpack_cpu_real.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_pack_unpack_cpu_complex.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/real.F90
./elpa-2018.05.001/real_template.F90:117:37:

117 | & (q(i,1),hh, nb, ldq, ldh, s)
| 1
Warning: Type mismatch in argument eqf at (1); passed REAL(8) to COMPLEX(8) [-Wargument-mismatch]
./elpa-2018.05.001/real_template.F90:133:37:

133 | & (q(i,1),hh, nb, ldq, ldh, s)
| 1
Warning: Type mismatch in argument eqf at (1); passed REAL(8) to COMPLEX(8) [-Wargument-mismatch]
./elpa-2018.05.001/real_template.F90:145:37:

145 | & (q(i,1),hh, nb, ldq, ldh, s)
| 1
Warning: Type mismatch in argument eqf at (1); passed REAL(8) to COMPLEX(8) [-Wargument-mismatch]
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/complex.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_single_hh_trafo_real.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_compute_hh_trafo_real.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/mod_compute_hh_trafo_complex.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/elpa2_compute_real.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/elpa2_compute_complex.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/elpa_solve_evp_real_2stage_double_impl.F90
mpif90 -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 -c ./elpa-2018.05.001/elpa_solve_evp_complex_2stage_double_impl.F90
mpicc -O3 -fopenmp -ffast-math -I./elpa-2018.05.001 openmx.o openmx_common.o Input_std.o Inputtools.o init.o LU_inverse.o ReLU_inverse.o truncation.o readfile.o FT_PAO.o FT_NLP.o FT_ProExpn_VNA.o FT_VNA.o FT_ProductPAO.o Hamiltonian_Cluster.o Hamiltonian_Cluster_Hs.o Hamiltonian_Cluster_NC_Hs2.o Hamiltonian_Band_NC_Hs2.o Overlap_Cluster_NC_Ss2.o Overlap_Band_NC_Ss2.o Overlap_Cluster.o Overlap_Cluster_Ss.o Set_ContMat_Cluster_LNO.o Hamiltonian_Band.o Matrix_Band_LNO.o Overlap_Band.o Hamiltonian_Cluster_NC.o Hamiltonian_Band_NC.o Hamiltonian_Cluster_SO.o Get_OneD_HS_Col.o SetPara_DFT.o XC_Ceperly_Alder.o XC_CA_LSDA.o XC_PW92C.o XC_PBE.o XC_EX.o DFT.o Mixing_DM.o Mixing_H.o Mixing_V.o Force.o Stress.o Poisson.o Poisson_ESM.o Cluster_DFT_Col.o Cluster_DFT_NonCol.o Cluster_DFT_Dosout.o Cluster_DFT_ON2.o Cluster_DFT_LNO.o Band_DFT_Col.o Band_DFT_NonCol.o Band_DFT_NonCol_GB.o Band_DFT_kpath.o Band_DFT_kpath_LNO.o Band_DFT_MO.o Unfolding_Bands.o Band_DFT_Dosout.o Set_Density_Grid.o Set_Orbitals_Grid.o Set_Aden_Grid.o Gauss_Legendre.o zero_cfrac.o xyz2spherical.o AngularF.o RadialF.o Dr_RadialF.o PhiF.o VNAF.o Dr_VNAF.o VH_AtomF.o Dr_VH_AtomF.o RF_BesselF.o QuickSort.o Nonlocal_RadialF.o KumoF.o Dr_KumoF.o Mulliken_Charge.o Occupation_Number_LDA_U.o Eff_Hub_Pot.o Coulomb_Interaction.o EulerAngle_Spin.o Smoothing_Func.o Orbital_Moment.o Pot_NeutralAtom.o Simple_Mixing_DM.o DIIS_Mixing_DM.o ADIIS_Mixing_DM.o GR_Pulay_DM.o Kerker_Mixing_Rhok.o DIIS_Mixing_Rhok.o Total_Energy.o Contract_Hamiltonian.o Contract_iHNL.o Cont_Matrix0.o Cont_Matrix1.o Cont_Matrix2.o Cont_Matrix3.o Cont_Matrix4.o Opt_Contraction.o Initial_CntCoes.o Initial_CntCoes2.o Set_XC_Grid.o Get_Orbitals.o Get_dOrbitals.o Get_Cnt_Orbitals.o Get_Cnt_dOrbitals.o Gaunt.o Find_CGrids.o MD_pac.o RestartFileDFT.o Output_CompTime.o Merge_LogFile.o Make_FracCoord.o Make_InputFile_with_FinalCoord.o Output_Energy_Decomposition.o Divide_Conquer.o Divide_Conquer_LNO.o Krylov.o Divide_Conquer_Dosout.o EGAC_DFT.o LNO.o Eigen_lapack.o Eigen_lapack2.o Eigen_lapack3.o EigenBand_lapack.o Eigen_PReHH.o BroadCast_ReMatrix.o Eigen_PHH.o BroadCast_ComplexMatrix.o lapack_dstedc1.o lapack_dstedc2.o lapack_dstedc3.o lapack_dstegr1.o lapack_dstegr2.o lapack_dstegr3.o lapack_dstevx1.o lapack_dstevx2.o lapack_dstevx3.o lapack_dstevx4.o lapack_dstevx5.o lapack_dsteqr1.o Nonlocal_Basis.o Set_OLP_Kin.o Set_Nonlocal.o Set_ProExpn_VNA.o Set_CoreHoleMatrix.o Set_OLP_p.o Set_Hamiltonian.o Set_Vpot.o Voronoi_Charge.o Voronoi_Orbital_Moment.o Fuzzy_Weight.o dampingF.o deri_dampingF.o Spherical_Bessel.o iterout.o iterout_md.o Allocate_Arrays.o Free_Arrays.o Init_List_YOUSO.o outputfile1.o malloc_multidimarray.o PrintMemory.o PrintMemory_Fix.o dtime.o OutData.o OutData_Binary.o init_alloc_first.o File_CntCoes.o SCF2File.o mimic_sse.o Make_Comm_Worlds.o Set_Allocate_Atom2CPU.o Cutoff.o Generating_MP_Special_Kpt.o Maketest.o Runtest.o Memory_Leak_test.o Force_test.o Stress_test.o Show_DFT_DATA.o Generate_Wannier.o TRAN_Allocate.o TRAN_DFT.o TRAN_DFT_Dosout.o TRAN_Apply_Bias2e.o TRAN_Deallocate_Electrode_Grid.o TRAN_Deallocate_RestartFile.o TRAN_RestartFile.o TRAN_Calc_CentGreen.o TRAN_Input_std.o TRAN_Set_CentOverlap.o TRAN_Calc_CentGreenLesser.o TRAN_Input_std_Atoms.o TRAN_Set_Electrode_Grid.o TRAN_Calc_GridBound.o TRAN_Set_IntegPath.o TRAN_Output_HKS.o TRAN_Set_MP.o TRAN_Calc_SelfEnergy.o TRAN_Output_Trans_HS.o TRAN_Calc_Hopping_G.o TRAN_Calc_SurfGreen.o TRAN_Set_SurfOverlap.o TRAN_Add_Density_Lead.o TRAN_Add_ADensity_Lead.o TRAN_Set_Value.o TRAN_Poisson.o TRAN_adjust_Ngrid.o TRAN_Print.o TRAN_Print_Grid.o Lapack_LU_inverse.o TRAN_Distribute_Node.o TRAN_Output_HKS_Write_Grid.o TRAN_Credit.o TRAN_Check_Region_Lead.o TRAN_Check_Region.o TRAN_Check_Input.o DFTDvdW_init.o DFTD3vdW_init.o neb.o neb_run.o neb_check.o TRAN_Allocate_NC.o TRAN_DFT_NC.o TRAN_Set_CentOverlap_NC.o TRAN_Set_SurfOverlap_NC.o TRAN_Calc_OneTransmission.o TRAN_Main_Analysis.o TRAN_Main_Analysis_NC.o MTRAN_EigenChannel.o TRAN_Channel_Functions.o TRAN_Channel_Output.o TRAN_Calc_CurrentDensity.o TRAN_CDen_Main.o elpa1.o solve_evp_real.o solve_evp_complex.o NBO_Cluster.o NBO_Krylov.o Population_Analysis_Wannier.o Population_Analysis_Wannier2.o NabraMatrixElements.o Set_dOrbitals_Grid.o Calc_optical.o Band_DFT_NonCol_Optical.o Cluster_DFT_Optical.o Band_DFT_Col_Optical_ScaLAPACK.o Cluster_DFT_Optical_ScaLAPACK.o mod_precision.o elpa_utilities.o elpa1_compute_real.o elpa1_compute_complex.o aligned_mem.o elpa2_determine_workload.o mod_redist_band_real.o mod_redist_band_complex.o mod_pack_unpack_cpu_real.o mod_pack_unpack_cpu_complex.o real.o complex.o mod_single_hh_trafo_real.o mod_compute_hh_trafo_real.o mod_compute_hh_trafo_complex.o elpa2_compute_real.o elpa2_compute_complex.o elpa_solve_evp_real_2stage_double_impl.o elpa_solve_evp_complex_2stage_double_impl.o -lscalapack-openmpi -llapack -lblas -lfftw3 -lmpi -lmpi_mpifh -lgfortran -lm -o openmx
/usr/bin/ld: cannot find -lmpi
collect2: error: ld returned 1 exit status
make: *** [makefile:191: openmx] Error 1

Re: installation error openmx 3.9 ( No.3 )
Date: 2020/05/27 15:03
Name: Naoya Yamaguchi

Dear Altan,

For some reasons, a shared object "libmpi.so" cannot be found automatically.
Please try the following:

CC = mpicc -O3 -fopenmp -ffast-math
FC = mpif90 -O3 -fopenmp -ffast-math
LIB= -lscalapack-openmpi -llapack -lblas -lfftw3 -L/usr/lib/x86_64-linux-gnu/openmpi/lib/ -lmpi -lmpi_mpifh -lgfortran

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.4 )
Date: 2020/05/27 20:40
Name: Altan

Dear Naoya,
It seems nothing changed. I still see the same error.
Regards,
Altan
Re: installation error openmx 3.9 ( No.5 )
Date: 2020/05/27 23:26
Name: Naoya Yamaguchi

Dear Altan,

Have you installed all the dependent packages?
According to https://packages.ubuntu.com/en/focal/libscalapack-mpi-dev
, "libscalapack-mpi-dev" depends on "libopenmpi-dev" through "mpi-default-dev", and "libopenmpi-dev" includes "libmpi.so".
And usually, dependent packages are installed automatically if you allow it.

What is output for the following command?
$ apt list --installed | grep mpi

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.6 )
Date: 2020/05/28 01:08
Name: Altan


Here is the output.


asa@asa-VirtualBox:~$ apt list --installed | grep mpi

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

compiz-core/focal,now 1:0.9.14.1+20.04.20200211-0ubuntu1 amd64 [installed]
compiz-gnome/focal,now 1:0.9.14.1+20.04.20200211-0ubuntu1 amd64 [installed]
compiz-plugins-default/focal,now 1:0.9.14.1+20.04.20200211-0ubuntu1 amd64 [installed]
compiz/focal,focal,now 1:0.9.14.1+20.04.20200211-0ubuntu1 all [installed]
libboost-mpi-dev/focal,now 1.71.0.0ubuntu2 amd64 [installed,auto-removable]
libboost-mpi1.67.0/focal,now 1.67.0-17ubuntu8 amd64 [installed,auto-removable]
libboost-mpi1.71-dev/focal,now 1.71.0-6ubuntu6 amd64 [installed,auto-removable]
libboost-mpi1.71.0/focal,now 1.71.0-6ubuntu6 amd64 [installed,auto-removable]
libcaf-openmpi-3/focal,now 2.8.0-1 amd64 [installed,automatic]
libcoarrays-openmpi-dev/focal,now 2.8.0-1 amd64 [installed,automatic]
libcompizconfig0/focal,now 1:0.9.14.1+20.04.20200211-0ubuntu1 amd64 [installed]
libexempi8/focal,now 2.5.1-1build1 amd64 [installed,automatic]
libmpich-dev/focal,now 3.3.2-2build1 amd64 [installed,automatic]
libmpich12/focal,now 3.3.2-2build1 amd64 [installed,automatic]
libopenmpi-dev/focal,now 4.0.3-0ubuntu1 amd64 [installed]
libopenmpi3/focal,now 4.0.3-0ubuntu1 amd64 [installed,automatic]
libscalapack-mpi-dev/focal,now 2.1.0-2build1 amd64 [installed]
libscalapack-openmpi-dev/focal,now 2.1.0-2build1 amd64 [installed,automatic]
libscalapack-openmpi2.0/now 2.0.2-7build2 amd64 [installed,local]
libscalapack-openmpi2.1/focal,now 2.1.0-2build1 amd64 [installed,automatic]
mpi-default-bin/focal,now 1.13 amd64 [installed,automatic]
mpi-default-dev/focal,now 1.13 amd64 [installed,automatic]
mpich/focal,now 3.3.2-2build1 amd64 [installed]
openmpi-bin/focal,now 4.0.3-0ubuntu1 amd64 [installed]
openmpi-common/focal,focal,now 4.0.3-0ubuntu1 all [installed,automatic]
openmpi-doc/focal,focal,now 4.0.3-0ubuntu1 all [installed]

Re: installation error openmx 3.9 ( No.7 )
Date: 2020/05/28 01:45
Name: Naoya Yamaguchi

Dear Altan,

The dependent packages seem to be installed.

Please show output for the following:
$ ls -l /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.8 )
Date: 2020/05/28 03:55
Name: Altan


It seems there is a problem. Please see the following output

asa@asa-VirtualBox:~$ ls -l /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so
ls: cannot access '/usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so': No such file or directory
asa@asa-VirtualBox:~$ ls /usr/lib/x86_64-linux-gnu/openmpi/lib/
libmca_common_monitoring.so.50.10.0 libmpi_java.so.40.20.0 libompitrace.so.40.20.0 mpi_f08_ext.mod mpi.mod
libmca_common_ompio.so.41.19.3 libmpi_mpifh.so.40.20.2 libopen-pal.so.40.20.3 mpi_f08_interfaces_callbacks.mod ompi_monitoring_prof.so
libmca_common_sm.so.40.20.0 libmpi.so.40.20.3 libopen-rte.so.40.20.3 mpi_f08_interfaces.mod openmpi3
libmca_common_verbs.so.40.20.0 libmpi_usempif08.so.40.21.0 mpi_ext.mod mpi_f08.mod pkgconfig
libmpi_cxx.so.40.20.1 libmpi_usempi_ignore_tkr.so.40.20.0 mpi_f08_callbacks.mod mpi_f08_types.mod pmpi_f08_interfaces.mod
asa@asa-VirtualBox:~$ ls -l /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so.40.20.3
-rw-r--r-- 1 root root 1124440 Nis 15 10:36 /usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so.40.20.3
Re: installation error openmx 3.9 ( No.9 )
Date: 2020/05/28 04:40
Name: Naoya Yamaguchi

Dear Altan,

The files such as "/usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so.40.20.3" you showed are part of a dependent package "libopenmpi3" as shown in:
https://packages.ubuntu.com/en/focal/amd64/libopenmpi3/filelist

And, "libopenmpi-dev" gives "libmpi.so". However, you seemed to install it manually as you show:
libopenmpi-dev/focal,now 4.0.3-0ubuntu1 amd64 [installed]

In addtion, you have also installed another MPI package in advance:
mpich/focal,now 3.3.2-2build1 amd64 [installed]

As such, since there might be some problems of conflict, please try to reinstall "libopenmpi-dev" as follows:
$ sudo apt --reinstall install libopenmpi-dev
Or,
$ sudo apt --purge remove libopenmpi-dev; sudo apt install libopenmpi-dev

After that, please check if there is "/usr/lib/x86_64-linux-gnu/openmpi/lib/libmpi.so".

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.10 )
Date: 2020/05/28 05:14
Name: Altan

Dear Naoya Yamaguchi,

GREAT! It seems it is working now.
I am very appreciated for your kind help.

Since I am using this only for openmx purpose, would you suggest to remove any of the followings? If yes, how?

libopenmpi-dev/focal,now 4.0.3-0ubuntu1 amd64 [installed]
mpich/focal,now 3.3.2-2build1 amd64 [installed]

Best regards,
Altan
Re: installation error openmx 3.9 ( No.11 )
Date: 2020/05/28 13:18
Name: Naoya Yamaguchi

Dear Altan,

>Since I am using this only for openmx purpose, would you suggest to remove any of the followings? If yes, how?
In your case, OpenMX requires "libscalapack-mpi-dev" depending on "libopenmpi-dev", so you can't remove "libopenmpi-dev", and you can remove only "mpich" since OpenMX doesn't require it.
If you remove "mpich" and packages that are required by only "mpich",
$ sudo apt remove mpich; sudo apt autoremove

Regards,
Naoya Yamaguchi
Re: installation error openmx 3.9 ( No.12 )
Date: 2020/05/28 20:58
Name: Altan

I have run the following command
sudo apt remove mpich; sudo apt autoremove
and I have no problem.

I am very grateful for your help. I means a lot to me.
Altan

Page: [1]