Page 1 of 1

[SOLVED] Probable bugs 6.12.3 with SLURM and GSL

Posted: Mon Nov 12, 2012 12:59 am
by yurtesen
I am not sure if the following are bugs or not but, but they look like it. Feel free to comment :D

SLURM problem:

We are using mvapich2 with slurm and there is no 'mpirun/mpiexec' due to this (srun
is used). It appears the configure script thinks MPI is broken due to this.

I had to use CC, FC, CXX env variables and hydra process manager (which includes mpirun) to
fool the installer.



MATH includes problem:

(configured with
--with-math-flavor="gsl" --with-math-incs="-I/export/modules/devel/gsl/1.15/gnu/include"
--with-math-libs="-L/export/modules/devel/gsl/1.15/gnu/lib -lgsl -lgslcblas" \


It appears the math includes which was set in Makefile is not passed to compilation. In
Makefile:

lib_math_incs = -I/export/modules/devel/gsl/1.15/gnu/include
with_math_incs = -I/export/modules/devel/gsl/1.15/gnu/include

Error (the /export/modules/devel/gsl/1.15/gnu/include/gsl/gsl_sf_bessel.h exists):

make[3]: Entering directory `/home/eyurtese/temp/abinit-6.12.3/src/01_gsl_ext'
mpicc -DHAVE_CONFIG_H -I. -I../.. -I../../src/incs -I../../src/incs -I/home/eyurtese/temp/abinit-6.12.3/fallbacks/exports/include -O3 -march=native -mtune=native -O3 -march=native -mtune=native -MT gsl_f90_sf_bessel_j0.o -MD -MP -MF .deps/gsl_f90_sf_bessel_j0.Tpo -c -o gsl_f90_sf_bessel_j0.o gsl_f90_sf_bessel_j0.c
gsl_f90_sf_bessel_j0.c:5:31: fatal error: gsl/gsl_sf_bessel.h: No such file or directory
compilation terminated.
make[3]: *** [gsl_f90_sf_bessel_j0.o] Error 1
make[3]: Leaving directory `/home/eyurtese/temp/abinit-6.12.3/src/01_gsl_ext'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/eyurtese/temp/abinit-6.12.3/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/eyurtese/temp/abinit-6.12.3'
make: *** [all] Error 2

I added $(with_math_incs) to /home/eyurtese/temp/abinit-6.12.3/src/01_gsl_ext/Makefile
at DEFAULT_INCLUDES and compilation continued, obviously a real fix is required:

DEFAULT_INCLUDES = -I. -I$(top_builddir)
vs
DEFAULT_INCLUDES = -I. $(with_math_incs) -I$(top_builddir)




make: *** [all] Error 2

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Tue Nov 13, 2012 4:53 pm
by jbeuken
hi,

SLURM problem:

We are using mvapich2 with slurm and there is no 'mpirun/mpiexec' due to this (srun
is used). It appears the configure script thinks MPI is broken due to this.


on our testfarm, we have a bot with slurm and, as workaround, we create a symbolic in mpich2/bin

Code: Select all

[buildbot@max2 bin]$ ll
total 52
-rwxr-xr-x. 1 root root  9078 Nov  1  2011 mpicc
-rwxr-xr-x. 1 root root  9376 Nov  1  2011 mpich2version
lrwxrwxrwx. 1 root root    25 Nov  1  2011 mpiexec -> /usr/local/bin/mpiexec.pl
-rwxr-xr-x. 1 root root 10720 Nov  1  2011 mpif77
-rwxr-xr-x. 1 root root 12676 Nov  1  2011 mpif90


the mpiexec.pl on http://pastie.org/5372203


we have also a bot to test gsl 1.15 with gcc4.5.3

this is my build.ac :

Code: Select all

enable_mpi="yes"
with_mpi_prefix="/usr/local/openmpi_gcc45"
with_linalg_flavor="none"

with_math_flavor="gsl"
with_math_incs="-I/usr/local/gsl/include"
with_math_libs="-L/usr/local/gsl/lib -lgsl -lgslcblas"
CFLAGS_EXTRA="-I/usr/local/gsl/include"
enable_clib="yes"
enable_gw_dpc="yes"


and it works ( tail of stdout of ./configure --with-config-file=./build.ac )

Code: Select all

Summary of important options:

  * C compiler      : gnu version 4.5
  * Fortran compiler: gnu version 4.5
  * architecture    : intel xeon (64 bits)

  * debugging       : basic
  * optimizations   : standard

  * MPI    enabled  : yes
  * MPI-IO enabled  : yes
  * GPU    enabled  : no (none)

  * TRIO   flavor = netcdf-fallback+etsf_io-fallback
  * TIMER  flavor = abinit (libs: ignored)
  * LINALG flavor = netlib-fallback (libs: internal)
  * ALGO   flavor = none (libs: ignored)
  * FFT    flavor = none (libs: ignored)
  * MATH   flavor = gsl (libs: user-defined)
  * DFT    flavor = libxc-fallback+atompaw-fallback+bigdft-fallback+wannier90-fallback


and the compilation succeeds !

my 5ยข

jmb

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Tue Nov 13, 2012 6:11 pm
by yurtesen
About slurm, thanks for the script, your script does not seem to be running (I fixed the srun path) and I didnt try to debug it since we just taught people to use srun :)

My point was that it is premature to decide that the MPI support is broken because mpiexec is missing. Missing mpiexec "will not" stop people from compiling (or even running) mpi programs. Why check it at all? is it even necessary?

About GSL, you seem to be using
CFLAGS_EXTRA="-I/usr/local/gsl/include"
I have already gave
with_math_incs="-I/usr/local/gsl/include"
and expected that this would be enough. As long as you use CFLAGS_EXTRA (which as I understand is a general extra flags variable) why bother with with_math_incs at all... (this is not intuitive)

Are you able to compile with gsl support, without giving the include path with CFLAGS_EXTRA ?

Thanks,
Evren

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Tue Nov 13, 2012 9:15 pm
by jbeuken
Evren,

About GSL, you seem to be using
CFLAGS_EXTRA="-I/usr/local/gsl/include"
I have already gave
with_math_incs="-I/usr/local/gsl/include"
and expected that this would be enough. As long as you use CFLAGS_EXTRA (which as I understand is a general extra flags variable) why bother with with_math_incs at all... (this is not intuitive)


It seems that this is the trick for the version 6.12.3... ( without CFLAGS_EXTRA, I have the same error )
but , good news, the problem is solved in version 7.0.3 ( this version will be released in 2 weeks )

jmb

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Tue Nov 13, 2012 9:42 pm
by yurtesen
jbeuken wrote:It seems that this is the trick for the version 6.12.3... ( without CFLAGS_EXTRA, I have the same error )
but , good news, the problem is solved in version 7.0.3 ( this version will be released in 2 weeks )


Hi,

Thats great news. I am trying to make packages which will be used in HPC clusters, I just thought it would be nice to report these probllems. I hope someday the configure script would also stop looking for mpiexec which is not necessary for building programs :)

Thanks,
Evren

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Wed Nov 28, 2012 3:25 pm
by yurtesen
The problem continues with 7.0.3 release! I am sorry to say that this is a bug and it should be fixed.

Code: Select all

Making all in 01_gsl_ext
make[5]: Entering directory `/home/eyurtese/tmp/abinit-7.0.3/src/01_gsl_ext'
mpicc -DHAVE_CONFIG_H -I. -I../.. -I../../src/incs -I../../src/incs -I/home/eyurtese/tmp/abinit-7.0.3/fallbacks/exports/include    -g -O3 -mtune=native -march=native   -MT gsl_f90_sf_bessel_j0.o -MD -MP -MF .deps/gsl_f90_sf_bessel_j0.Tpo -c -o gsl_f90_sf_bessel_j0.o gsl_f90_sf_bessel_j0.c
mpicc -DHAVE_CONFIG_H -I. -I../.. -I../../src/incs -I../../src/incs -I/home/eyurtese/tmp/abinit-7.0.3/fallbacks/exports/include    -g -O3 -mtune=native -march=native   -MT gsl_f90_sf_bessel_jl.o -MD -MP -MF .deps/gsl_f90_sf_bessel_jl.Tpo -c -o gsl_f90_sf_bessel_jl.o gsl_f90_sf_bessel_jl.c
mpicc -DHAVE_CONFIG_H -I. -I../.. -I../../src/incs -I../../src/incs -I/home/eyurtese/tmp/abinit-7.0.3/fallbacks/exports/include    -g -O3 -mtune=native -march=native   -MT gsl_f90_sf_gamma.o -MD -MP -MF .deps/gsl_f90_sf_gamma.Tpo -c -o gsl_f90_sf_gamma.o gsl_f90_sf_gamma.c
mpif90 -DHAVE_CONFIG_H -I. -I../.. -I../../src/incs -I../../src/incs -I/home/eyurtese/tmp/abinit-7.0.3/fallbacks/exports/include   -ffree-form -J/home/eyurtese/tmp/abinit-7.0.3/src/mods -O3 -mtune=native -march=native -g -ffree-line-length-none   -c -o interfaces_01_gsl_ext.o interfaces_01_gsl_ext.F90
gsl_f90_sf_bessel_jl.c:5:31: fatal error: gsl/gsl_sf_bessel.h: No such file or directory
compilation terminated.
gsl_f90_sf_bessel_j0.c:5:31: fatal error: gsl/gsl_sf_bessel.h: No such file or directory
gsl_f90_sf_gamma.c:5:30: fatal error: gsl/gsl_sf_gamma.h: No such file or directory
compilation terminated.
compilation terminated.
make[5]: *** [gsl_f90_sf_bessel_jl.o] Error 1
make[5]: *** Waiting for unfinished jobs....
make[5]: *** [gsl_f90_sf_bessel_j0.o] Error 1
make[5]: *** [gsl_f90_sf_gamma.o] Error 1
make[5]: Leaving directory `/home/eyurtese/tmp/abinit-7.0.3/src/01_gsl_ext'
make[4]: *** [all-recursive] Error 1
make[4]: Leaving directory `/home/eyurtese/tmp/abinit-7.0.3/src'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/eyurtese/tmp/abinit-7.0.3'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/eyurtese/tmp/abinit-7.0.3'
make[1]: *** [multi] Error 2
make[1]: Leaving directory `/home/eyurtese/tmp/abinit-7.0.3'
make: *** [mj4] Error 2
-bash-4.1$

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Mon Jan 28, 2013 11:50 am
by yurtesen
Problem still continues with 7.0.5 release. I still have been using the same workaround of changing DEFAULT_INCLUDES in src/01_gsl_ext/Makefile
DEFAULT_INCLUDES = -I. -I$(top_builddir) -I$(GSL_INCLUDE)

Since configure finds GSL correctly, I still say this is a bug. Please fix the configure system. Thanks!

Re: Probable bugs 6.12.3 with SLURM and GSL

Posted: Thu Feb 07, 2013 6:48 pm
by pouillon
I finally found the bug. It was a very well hidden one!

Will be fixed in Abinit 7.2.