cp2k invalid memory reference in SCF wavefunction optimization

214 views
Skip to first unread message
Assigned to raine...@googlemail.com by me

Rainer Rutka

unread,
Sep 15, 2020, 2:49:38 AM9/15/20
to cp2k
Hi.
My name is Rainer. I am a cluster admin at the
University of Konstanz/Germany.

Last week i got the order to build cp2k for our
Chemical Cluster Justus. Compillation was fine,
I got no errors in the build process.

Unfortunately the tests are not running. I get


These are the modules i load:

# Load required modules for build process
module load compiler/intel/19.1
module load compiler/gnu/system
module load mpi/openmpi
module load numlib/mkl
module load devel/cmake

Toolchain options i used:

# ./install_cp2k_toolchain.sh \
  --math-mode=openblas \
  --with-sirius=no \
  --mpi-mode=openmpi \
  --with-cmake=system \
  --with-mpich=no \
  --with-libxc=install \
  --libint-lmax=6 \
  --with-fftw=install \
  --with-openblas=install \
  --with-scalapack=install \
  --with-reflapack=no \
  --with-mkl=no \
  --with-libxsmm=install \
  --with-elpa=no \
  --with-superlu=install \
  --with-quip=install \
  --with-plumed=install \
  --with-gsl=install \
  --with-libvdwxc=install \
  --with-spglib=install \
  --with-hdf5=install
#

cp2k.out with error (excerpt):

Total Electron Density at R=0:
0.000068
 Re-scaling the density matrix to get the right number of electrons
                  # Electrons              Trace(P)
Scaling factor
                           32                31.944
   1.002


 SCF WAVEFUNCTION OPTIMIZATION

  Step     Update method      Time    Convergence         Total energy
  Change

------------------------------------------------------------------------------

Program received signal SIGSEGV: Segmentation fault - invalid memory
reference.

Backtrace for this error:

Program received signal SIGSEGV: Segmentation fault - invalid memory
reference.

[...]

Slurm parameter in submit-script:

#SBATCH --nodes=8
#SBATCH --tasks-per-node=32
#SBATCH --mem-per-cpu=2000M

echo "### Set some cp2k envs ..."
export HWLOC_HIDE_ERRORS=1 #
https://www.open-mpi.org/projects/hwloc/doc/v2.0.2/a00326.php
export COSMA_CPU_MAX_MEMORY=64000
# HWLOC_COMPONENTS=x86

echo "### Running application ..."
srun cp2k.psmp -i ${TMP_WORK_DIR}/${INPUT} > cp2k7_1.out 2>&1

[...]

Attachments:

cp2k7_1.out : CP2K Output with error
bwforcluster-cp2k-example.sbatch : Slurm submit script
argon-vdW-DF-optPBE.inp


I would appreciate help very much!

Thanx in advance.

Rainer

-- Rainer Rutka Universität Konstanz Kommunikations-, Informations-, Medienzentrum (KIM) * Abteilung IT-Dienste Forschung und Lehre * Wissenschaftliches Rechnen/bwHPC-S5 * KIM Ausbildung 78457 Konstanz +49 7531 88 54 13, Raum: B 803
argon-vdW-DF-optPBE.inp
bwforcluster-cp2k-example.sbatch
cp2k7_1.out

Krack Matthias (PSI)

unread,
Sep 15, 2020, 3:04:50 AM9/15/20
to cp...@googlegroups.com

Hi Rainer

 

a reason for such segmentation faults is often a too small stack size. Check your stack size limit with (e,g. for bash with “ulimit –s”). It should be a large value or “unlimited”. I am using the latter setting.

 

HTH

 

Matthias

--
You received this message because you are subscribed to the Google Groups "cp2k" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cp2k/ed18673d-7faf-4940-a7f7-b0301a8f1602o%40googlegroups.com.

Rainer Rutka

unread,
Sep 15, 2020, 3:20:22 AM9/15/20
to cp2k
Hi Matthias.
Thank you for your fast answer.
See the attached file with my ulimit-setups (and more). It's unlimited (IMO).
cp2k_mpi_justus.436878.out

Krack Matthias (PSI)

unread,
Sep 15, 2020, 3:27:35 AM9/15/20
to cp...@googlegroups.com

Hi Rainer

 

Your stack size is 200000 which is most likely not large enough. Try unlimited or millions.

 

HTH

 

Matthias

 

From: cp...@googlegroups.com <cp...@googlegroups.com> On Behalf Of Rainer Rutka


Sent: Dienstag, 15. September 2020 09:20
To: cp2k <cp...@googlegroups.com>

--

You received this message because you are subscribed to the Google Groups "cp2k" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+uns...@googlegroups.com.

Rainer Rutka

unread,
Sep 15, 2020, 3:55:58 AM9/15/20
to cp2k
Hi Matthias.
I changed the value from 200000 to unlimited.
Unfortunately no change. I still get the same error.
:-(

Krack Matthias (PSI)

unread,
Sep 15, 2020, 3:59:40 AM9/15/20
to cp...@googlegroups.com

Hi Rainer

 

Can you run the test input interactively?

Rainer Rutka

unread,
Sep 15, 2020, 6:23:46 AM9/15/20
to cp2k
Hi.

I did.

Same crash.... .-(

To unsubscribe from this group and stop receiving emails from it, send an email to cp...@googlegroups.com.

Krack Matthias (PSI)

unread,
Sep 15, 2020, 7:07:55 AM9/15/20
to cp...@googlegroups.com

Well, bad luck then. So you have most likely a miscompiled CP2K binary.

 

You are using the Intel compiler with MKL available, but you request a toolchain installation of ScaLAPACK and openmpi instead of using the mpich based Intel MPI and the ScaLAPACK/LAPACK/BLAS and FFTW libraries coming with MKL. Did you try to compile first using the minimal Intel arch file Linux-x86-64-intel-minimal.psmp?

 

make –j 16 ARCH=Linux-x86-64-intel-minimal VERSION=psmp

 

Moreover, I suggest the Intel 18.4 compiler version.

Krack Matthias (PSI)

unread,
Sep 15, 2020, 7:14:18 AM9/15/20
to cp...@googlegroups.com

PS: The argon test input, you are using, should run on a single core. So, using 256 cores is certainly an overkill which might also trouble.

 

Matthias

Reply all
Reply to author
Forward
0 new messages