Segmentation Fault

Various technical topics such as parallelism and efficiency, netCDF problems, the Yambo code structure itself, are posted here.

Moderators: Davide Sangalli, andrea.ferretti, myrta gruning, andrea marini, Daniele Varsano, Conor Hogan, Nicola Spallanzani

Post Reply
Bruno
Posts: 72
Joined: Tue Dec 08, 2020 11:16 am

Segmentation Fault

Post by Bruno » Tue Jan 05, 2021 11:19 am

Hello!

I've recently compiled the yambo 5.0 as suggested by Claudio and I'm facing the following problem. When I run the yambo with "yambo -F gw.in " directly on the terminal the code seems to run fine, but when I try to run it using the bash script from my cluster using 64 cores I get a segmentation fault and the code does not run, at least I don't receive neither the r- files or the LOG folder. It seems that some of the parallelization flags are now different on the 5.0, at least the "X_and_IO_CPU" with the IO options was not generated for me on the previous version when using -V par, so I'm not sure what is the actual problem. I used the very same bash script to run the previous version of yambo and it worked fine. I'm attaching the gw.in and r_setup files as a reference.
r_setup.txt
gw.in.txt
Thank you very much,
You do not have the required permissions to view the files attached to this post.
MSc. Bruno Cucco
PhD Candidate
CNRS Institut des Sciences Chimiques de Rennes, France
Université de Rennes 1
https://iscr.univ-rennes1.fr

User avatar
claudio
Posts: 448
Joined: Tue Mar 31, 2009 11:33 pm
Contact:

Re: Segmentation Fault

Post by claudio » Tue Jan 05, 2021 11:43 am

Dear Bruno

I don't know where your problem come from,but you can make some tests:

1) set X_and_IO_nCPU_LinAlg_INV=1

2) generate the input with yambo -g n -p p -V RL
and try to reduce the number of plane waves

3) try to use automatic parallelization

4) compile with the flag --enable-hdf5-par-io

Moreover I advise you to use mHa or mRy instead of Ha or Ry,
then the code will change it slightly to close the g-shells.
For example
NGsBlkXp= 1000 mRy
Claudio Attaccalite
[CNRS/ Aix-Marseille Université/ CINaM laborarory / TSN department
Campus de Luminy – Case 913
13288 MARSEILLE Cedex 09
web site: http://www.attaccalite.com

Bruno
Posts: 72
Joined: Tue Dec 08, 2020 11:16 am

Re: Segmentation Fault

Post by Bruno » Tue Jan 05, 2021 1:07 pm

Hello Claudio!

Thanks for the fast reply. I tried all of them except the automatic parallelisation since I'm not really sure how to do it, can you give me a tip? (If this is done by letting the fields empty, for example X_and_IO_CPU="", I actually tried it and also no success)

I did tried the suggestions before and after recompiling with the mentioned flag, no luck unfortunately.

Regards,
MSc. Bruno Cucco
PhD Candidate
CNRS Institut des Sciences Chimiques de Rennes, France
Université de Rennes 1
https://iscr.univ-rennes1.fr

User avatar
Daniele Varsano
Posts: 3773
Joined: Tue Mar 17, 2009 2:23 pm
Contact:

Re: Segmentation Fault

Post by Daniele Varsano » Tue Jan 05, 2021 1:13 pm

Dear Bruno,
can you post your submission script and any error message from the system?
Is it possible that the mpi wrapper (mpirun/mpiexec...) you are using is not compatible with the mpi compiler you used to compile the code?
Best,
Daniele
Dr. Daniele Varsano
S3-CNR Institute of Nanoscience and MaX Center, Italy
MaX - Materials design at the Exascale
http://www.nano.cnr.it
http://www.max-centre.eu/

Bruno
Posts: 72
Joined: Tue Dec 08, 2020 11:16 am

Re: Segmentation Fault

Post by Bruno » Wed Jan 06, 2021 11:08 am

Dear Daniele,

I suppose it could be possible. But I'm not really sure since as far as I remember I compiled it in the very same way that I did on the last time(the working one), I even used the very same "./configure + options" to configure yambo. I'm attaching the standard error output from the cluster as requested and also the submission script. Thanks!
std_e.out.txt
script.sh.txt
Regards,
You do not have the required permissions to view the files attached to this post.
MSc. Bruno Cucco
PhD Candidate
CNRS Institut des Sciences Chimiques de Rennes, France
Université de Rennes 1
https://iscr.univ-rennes1.fr

Bruno
Posts: 72
Joined: Tue Dec 08, 2020 11:16 am

Re: Segmentation Fault

Post by Bruno » Wed Jan 06, 2021 3:18 pm

Hello,

Just to complement my last post, I recompiled again the version 4.5.3 to see if it would in fact work and the yambo seems to run fine using the same script that I sent you. I have no idea what the problem might be.

Regards,
MSc. Bruno Cucco
PhD Candidate
CNRS Institut des Sciences Chimiques de Rennes, France
Université de Rennes 1
https://iscr.univ-rennes1.fr

User avatar
Daniele Varsano
Posts: 3773
Joined: Tue Mar 17, 2009 2:23 pm
Contact:

Re: Segmentation Fault

Post by Daniele Varsano » Wed Jan 06, 2021 5:05 pm

Dear Bruno,
thanks for the update, great that it now works fine.
Best,
Daniele
Dr. Daniele Varsano
S3-CNR Institute of Nanoscience and MaX Center, Italy
MaX - Materials design at the Exascale
http://www.nano.cnr.it
http://www.max-centre.eu/

User avatar
claudio
Posts: 448
Joined: Tue Mar 31, 2009 11:33 pm
Contact:

Re: Segmentation Fault

Post by claudio » Thu Jan 07, 2021 12:04 pm

Dear Bruno

find the reason for segmentation fault can be quite difficult
here some advice to see if it solves the problem with yambo 5.0

1) compile with debug options, for example for gfortran
./configure FCFLAGS="-O0 -g -fbounds-check" F77FLAGS="-O0 -g -fbounds-check " CFLAGS="-O1 -g"
and for intel fortran
FCFLAGS="-O0 -debug -g -check all" F77FLAGS="-O0 -debug -g -check all"

2) use all internal libraries
./configure --enable-int-linalg --enable-internal-fftsg

3) try to run with few processors, small jobs and so on

4) try on another parallel machine, your pc and so on

5) check which c compiler you are using and change it for exmaple
./configure CC=gcc CPP=gcc MPICC=mpicc

6) make a run with gdb
https://stackoverflow.com/questions/329 ... pi-program

combine these different advices together

and tell us if you get something good or some more information about your problem

best
Claudio
Claudio Attaccalite
[CNRS/ Aix-Marseille Université/ CINaM laborarory / TSN department
Campus de Luminy – Case 913
13288 MARSEILLE Cedex 09
web site: http://www.attaccalite.com

Bruno
Posts: 72
Joined: Tue Dec 08, 2020 11:16 am

Re: Segmentation Fault

Post by Bruno » Fri Jan 08, 2021 8:34 pm

Dear Claudio,

Thank you for all the support. I've tried to use the internal libraries with --enable-int-linalg --enable-internal-fftsg as suggested but I've got another error related to the netcdf asking me to use LDPATH, I tried to link it with a couple of different way but no success. I've actually sent an e-mail to the cluster team and hopefully they will compile it on the system, which would be way better since they know the system very well. For know I'll stick to the working compilation on another cluster that I've access.

Thank you very much again!

Regards,
MSc. Bruno Cucco
PhD Candidate
CNRS Institut des Sciences Chimiques de Rennes, France
Université de Rennes 1
https://iscr.univ-rennes1.fr

Post Reply