Author Topic: [SOLVED] Random crashes in successive runs  (Read 1466 times)

marcelo

  • Newbie
  • *
  • Posts: 8
[SOLVED] Random crashes in successive runs
« on: June 07, 2016, 05:20:57 PM »
Hello,

I prepared a small test case using GID 13. When I launch it with runkratos, most of the time (e.g. five successive times) it finishes correctly, but suddenly it stops with one of two possible error messages:

(correct):
...
::[Mechanical Solver]:: Model reading finished.
::[Mechanical Solver]:: DOF's ADDED
::[Mechanical Solver]:: -START-
::[Mechanical Solver]:: -END-
 
::[KSM Simulation]:: Analysis -START-
::[KSM Simulation]:: Analysis -END-
 
::[KSM Simulation]:: [ Computing Time = (0.93  seconds process time) ( 0.17  seconds wall time) ]
Tue Jun  7 16:43:33 2016
KRATOS TERMINATED CORRECTLY

(segfault):
...
::[Mechanical Solver]:: Model reading finished.
::[Mechanical Solver]:: DOF's ADDED
::[Mechanical Solver]:: -START-
::[Mechanical Solver]:: -END-
 
::[KSM Simulation]:: Analysis -START-
::[KSM Simulation]:: Analysis -END-
 
::[KSM Simulation]:: [ Computing Time = (0.83  seconds process time) ( 0.16  seconds wall time) ]
Tue Jun  7 16:48:26 2016
Segmentation fault (core dumped)

(abort):
...
::[Mechanical Solver]:: Model reading finished.
::[Mechanical Solver]:: DOF's ADDED
::[Mechanical Solver]:: -START-
::[Mechanical Solver]:: -END-
 
::[KSM Simulation]:: Analysis -START-
*** Error in `runkratos': double free or corruption (out): 0x00000000024292f0 ***
Aborted (core dumped)

The version of Kratos is 5.0.15736. The case files available from https://dl.dropboxusercontent.com/u/4165452/testcase.tar

Thanks,
Marcelo
« Last Edit: June 16, 2016, 03:56:04 PM by marcelo »

Josep Maria

  • Global Moderator
  • Jr. Member
  • *****
  • Posts: 50
Re: Random crashes in successive runs
« Reply #1 on: June 07, 2016, 09:56:57 PM »
Hello Marcelo

    I will take a look to the case and I will try to reproduce this error/s.  Please can you tell me which operation system are you using?

     Thanks to report the error,  we will try to solve it as soon as possible.

J.M.C.

marcelo

  • Newbie
  • *
  • Posts: 8
Re: Random crashes in successive runs
« Reply #2 on: June 08, 2016, 12:12:32 PM »
Hi Josep Maria

Linux 3.19.0-58-generic #64~14.04.1-Ubuntu SMP x86_64 GNU/Linux. I am also pasting the first part of output of cmake below. Let me know if you need more information.

Marcelo
 
-- The C compiler identification is GNU 4.8.4
-- The CXX compiler identification is GNU 4.8.4
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/g++
-- Check for working CXX compiler: /usr/bin/g++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found Subversion: /usr/bin/svn (found version "1.8.8")
additional default options were set for gcc
CMAKE_CXX_FLAGS =  -msse3 -std=c++11 -funroll-loops -ffast-math -Wall -Wno-strict-aliasing
CMAKE_C_FLAGS =  -msse3 -funroll-loops -ffast-math -Wall -Wno-strict-aliasing
KRATOS_EXCLUDE_OPENMP
OpenMP included
-- Try OpenMP C flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Try OpenMP CXX flag = [-fopenmp]
-- Performing Test OpenMP_FLAG_DETECTED
-- Performing Test OpenMP_FLAG_DETECTED - Success
-- Found OpenMP: -fopenmp 
-- Boost version: 1.54.0
-- Found the following Boost libraries:
--   python
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found version "2.7.6")
-- The Fortran compiler identification is GNU
-- Check for working Fortran compiler: /usr/bin/gfortran
-- Check for working Fortran compiler: /usr/bin/gfortran  -- works
-- Detecting Fortran compiler ABI info
-- Detecting Fortran compiler ABI info - done
-- Checking whether /usr/bin/gfortran supports Fortran 90
-- Checking whether /usr/bin/gfortran supports Fortran 90 -- yes
-- Detecting Fortran/C Interface
-- Detecting Fortran/C Interface - Found GLOBAL and MODULE mangling
-- Looking for Fortran sgemm
-- Looking for Fortran sgemm - found
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - found
-- Found Threads: TRUE 
-- A library with BLAS API found.
linker flags with blas =
BLA_VENDOR = All
-- A library with BLAS API found.
-- Looking for Fortran cheev
-- Looking for Fortran cheev - found
-- A library with LAPACK API found.
LAPACK = /usr/lib/liblapack.so/usr/lib/openblas-base/libblas.so.3
LAPACK modified = /usr/lib/lapack/liblapack.so.3.0/usr/lib/openblas-base/libblas.so.3
 
CMAKE_BUILD_TYPE ........ Release
 
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of off64_t
-- Check size of off64_t - done
-- Looking for fseeko
-- Looking for fseeko - found
-- Looking for unistd.h
-- Looking for unistd.h - found
 
INCOMPRESSIBLE_FLUID_APPLICATION ... OFF
MESHING_APPLICATION ................ OFF
EXTERNAL_SOLVERS_APPLICATION........ ON
PFEM_APPLICATION.................... OFF
STRUCTURAL_APPLICATION.............. OFF
STRUCTURAL_MECHANICS_APPLICATION.... ON
CONVECTION_DIFFUSION_APPLICATION.... OFF
SOLID_MECHANICS_APPLICATION......... ON
PFEM_BASE_APPLICATION...............
PFEM_SOLID_MECHANICS_APPLICATION....
FLUID_DYNAMICS_APPLICATION.......... OFF
PFEM_FLUID_DYNAMICS_APPLICATION.....
ALE_APPLICATION..................... OFF
FSI_APPLICATION..................... OFF
EMPIRE_APPLICATION..................
MIXED_ELEMENT_APPLICATION........... ON
DEM_APPLICATION..................... OFF
SWIMMING_DEM_APPLICATION............ OFF
CONSTITUTIVE_LAWS_APPLICATION.......
THERMO_MECHANICAL_APPLICATION.......
OPENCL_APPLICATION.................. OFF
MKL_SOLVERS_APPLICATION............. OFF
MPI_SEARCH_APPLICATION..............
METIS_APPLICATION................... OFF
TRILINOS_APPLICATION................ OFF
TURBULENT_FLOW_APPLICATION..........
BLOOD_FLOW_APPLICATION..............
PURE_DIFFUSION_APPLICATION..........
MESHLESS_APPLICATION................
WIND_TURBINE_APPLICATION ...........
CLICK2CAST_APPLICATION .............
MULTISCALE_APPLICATION .............
PFEM2_APPLICATION...................
FREEZING_SOIL_APPLICATION...........
ADJOINT_FLUID_APPLICATION...........
POROMECHANICS_APPLICATION...........
PARTICLE_MECHANICS_APPLICATION......
FORMING_APPLICATION.................
DAM_APPLICATION.....................
SHAPE_OPTIMIZATION_APPLICATION...... OFF
 
**** configuring KratosExternalSolversApplication ****
**** configuring KratosStructuralMechanicsApplication ****
**** configuring KratosMixedElementApplication ****
**** configuring KratosSolidMechanicsApplication ****
python libraries to be installed are: /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0
--------------------------------  standard install dir /home/mraschi/Projects/kratos
boost python lib used = /usr/lib/x86_64-linux-gnu/libboost_python-py27.so.1.54.0
installed blas = /usr/lib/openblas-base/libblas.so.3
installed lapack = /usr/lib/lapack/liblapack.so.3.0/usr/lib/openblas-base/libblas.so.3
-- Configuring done
-- Generating done
CMake Warning:
  Manually-specified variables were not used by the project:

    MKLSOLVER_INCLUDE_DIR
    MKLSOLVER_LIB_DIR
    PARMETIS_ROOT_DIR
    TRILINOS_ROOT


-- Build files have been written to: /home/mraschi/Projects/kratos/cmake_build
...

Josep Maria

  • Global Moderator
  • Jr. Member
  • *****
  • Posts: 50
Re: Random crashes in successive runs
« Reply #3 on: June 09, 2016, 07:13:58 PM »
Thank you Marcelo.  I will tell you something soon.  Just to discard things.  Set your system to serial (num threads equal to one)  and check if the error appears. 

Josep Maria

  • Global Moderator
  • Jr. Member
  • *****
  • Posts: 50
Re: Random crashes in successive runs
« Reply #4 on: June 14, 2016, 07:18:00 PM »
Hello Marcelo,

   Update and compile the SolidMechanicsApplication and try to run the example several times.

I think the problem is solved. At least a mistake was corrected. The property "THICKNESS" was asked even in a 2D plane strain problem for the computation of the kratos conditions. This variable was not assigned and that was the reason for the random behaviour experienced. This is more relevant when parallelism is active.

B.R.

Josep Maria

marcelo

  • Newbie
  • *
  • Posts: 8
[SOLVED] Random crashes in successive runs
« Reply #5 on: June 16, 2016, 03:55:02 PM »
Hola Josep Maria,

Apparently this fix solved the problem. I tried the test case in serial and parallel and no further issues.

Thank you very much for the fix.
Marcelo