idaholab / moose

Multiphysics Object Oriented Simulation Environment
https://www.mooseframework.org
GNU Lesser General Public License v2.1
1.71k stars 1.04k forks source link

mooseError in OPT often end up in seg fault on Linux #22127

Open GiudGiud opened 2 years ago

GiudGiud commented 2 years ago

Bug Description

This error because of an unused parameter becomes a seg fault

(moose) GIUDGL@FN428853:~/projects/virtual_test_bed/msr/msfr/steady$ ~/projects/moose_v1/modules/navier_stokes/navier_stokes-opt -i run_ns_initial.i 
hwloc/linux: Ignoring PCI device with non-16bit domain.
Pass --enable-32bits-pci-domain to configure to support such devices
(warning: it would break the library ABI, don't enable unless really needed).
Framework Information:
MOOSE Version:           git commit fef1799fe0 on 2022-09-15
LibMesh Version:         
PETSc Version:           3.16.6
SLEPc Version:           3.16.2
Current Time:            Fri Sep 16 19:43:19 2022
Executable Timestamp:    Thu Sep 15 22:42:59 2022

Parallelism:
  Num Processors:          1
  Num Threads:             1

Mesh: 
  Parallel Type:           replicated
  Mesh Dimension:          2
  Spatial Dimension:       2
  Nodes:                   8536
  Elems:                   8272
  Num Subdomains:          3

Nonlinear System:
  Num DOFs:                24816
  Num Local DOFs:          24816
  Variables:               { "vel_x" "vel_y" "pressure" } 
  Finite Element Types:    "MONOMIAL" 
  Approximation Orders:    "CONSTANT" 

Auxiliary System:
  Num DOFs:                33088
  Num Local DOFs:          33088
  Variables:               { "geometric0" "algebraic0" "pressure_total" "density" } 
  Finite Element Types:    "MONOMIAL" 
  Approximation Orders:    "CONSTANT" 

Execution Information:
  Executioner:             Transient
  TimeStepper:             IterationAdaptiveDT
  Solver Mode:             NEWTON
  MOOSE Preconditioner:    SMP (auto)

Segmentation fault (core dumped)
(moose) GIUDGL@FN428853:~/projects/virtual_test_bed/msr/msfr/steady$ ~/projects/moose_v1/modules/navier_stokes/navier_stokes-devel -i run_ns_initial.i 
hwloc/linux: Ignoring PCI device with non-16bit domain.
Pass --enable-32bits-pci-domain to configure to support such devices
(warning: it would break the library ABI, don't enable unless really needed).
Framework Information:
MOOSE Version:           git commit a8fb19b177 on 2022-09-13
LibMesh Version:         
PETSc Version:           3.16.6
SLEPc Version:           3.16.2
Current Time:            Fri Sep 16 19:43:27 2022
Executable Timestamp:    Tue Sep 13 18:38:36 2022

Parallelism:
  Num Processors:          1
  Num Threads:             1

Mesh: 
  Parallel Type:           replicated
  Mesh Dimension:          2
  Spatial Dimension:       2
  Nodes:                   8536
  Elems:                   8272
  Num Subdomains:          3

Nonlinear System:
  Num DOFs:                24816
  Num Local DOFs:          24816
  Variables:               { "vel_x" "vel_y" "pressure" } 
  Finite Element Types:    "MONOMIAL" 
  Approximation Orders:    "CONSTANT" 

Auxiliary System:
  Num DOFs:                33088
  Num Local DOFs:          33088
  Variables:               { "geometric0" "algebraic0" "pressure_total" "density" } 
  Finite Element Types:    "MONOMIAL" 
  Approximation Orders:    "CONSTANT" 

Execution Information:
  Executioner:             Transient
  TimeStepper:             IterationAdaptiveDT
  Solver Mode:             NEWTON
  MOOSE Preconditioner:    SMP (auto)

*** ERROR ***
/home/giudgl/projects/virtual_test_bed/msr/msfr/steady/run_ns_initial.i:18: unused parameter 'von_karman_const'

Stack frames: 11
0: libMesh::print_trace(std::ostream&)
1: moose::internal::mooseErrorRaw(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >)
2: void mooseError<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&)
3: Parser::errorCheck(libMesh::Parallel::Communicator const&, bool, bool)
4: MooseApp::errorCheck()
5: MooseApp::executeExecutioner()
6: MooseApp::run()
7: main
8: /lib/x86_64-linux-gnu/libc.so.6(+0x29d90) [0x7f0dfc6d8d90]
9: __libc_start_main
10: /home/giudgl/projects/moose_v1/modules/navier_stokes/navier_stokes-devel(+0x33ff) [0x555e2d4e03ff]
application called MPI_Abort(MPI_COMM_WORLD, 1) - process 0
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1
:
system msg for write_line failure : Bad file descriptor

Steps to Reproduce

any error will do. Might not be on all machines

Impact

looks bad

GiudGiud commented 2 years ago

my hunch is that the printing fails.