SMOKE v5.2.1 Segmentation fault (core dumped) error

I am processing 2022v2 inventory and have finished most of the sectors. However, when I run ‘nonpt’ and ‘nonroad’ script, I met the following error. Based on the log files (attached), the SMOKE runs stopped at reading the inventory, but the log files look fine (no critical errors found). I tried to re-start the SMOKE several times and re-download the input csv file to make sure the files are ok. I also read similar posts in this forum, but didn’t find a method to fix it.

Any suggestions on how to debug the problem? Thanks!

Hao

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

Backtrace for this error:
#0 0x148b9f235171 in ???
#1 0x148b9f234313 in ???
#2 0x148b9e8eb5af in ???
#3 0x148b9e955bd8 in ???
#4 0x4237c9 in ???
#5 0x40322e in ???
#6 0x426f9e in ???
#7 0x46e462 in ???
#8 0x4030fc in ???
#9 0x148b9e8d77e4 in ???
#10 0x40313d in ???
#11 0xffffffffffffffff in ???
Segmentation fault (core dumped)

smkinven_nonroad_jan_2022he_cb6_22m.txt (15.0 KB)

smkinven_nonpt_2022he_cb6_22m.txt (11.4 KB)

Did you build SMOKE locally or download pre-compiled files?

If you are able to build SMOKE locally can you please try to compile SMOKE with debugging?

Can you please clarify what version of SMOKE you are using?

Also, what type of system you are running on and which version of compiled executables you are using?

Yes, I built SMOKE v5.2.1 locally with GNU compiler. I only found a very old instruction for SMOKE debug at 12.4. Compiling SMOKE for UNIX, which using intel compiler. could you please suggest the debug flags for SMOKE v5.2.1?

Hao

I am using SMOKE v5.2.1, compiled locally with GNU on a Redhat Linux server. The default 2022v2 platform has SMOKE v5.2, should I roll back to this version?

Hao

Hao,

To compile SMOKE debug with GNU compiler, please refer to our SMOKE compilation instruction. You would need to modify src/Makeinclude to use this EFLAG settings

EFLAG = -g -Og -ffixed-line-length-132 -fbacktrace -fno-backslash -fcheck=all -Wall -Wsurprising -fbounds-check -finit-real=snan -m64 #  GNU   Fortran with debug; BIN = Linux2_x86_64dbg

I would suggest you to stay with SMOKE v5.2.1, don’t reverse to SMOKE 5.2

Huy

Hi Huy,

Thanks for your suggestion. I have re-compiled SMOKE v5.2.1 with the debug option and got the following error before crash. The crash is caused by the input data mixing of monthly and annual data. Any suggestion on how to fix it? Thanks!

Hao

Removing the many ‘Monthly inventory is missing’ warnings from the Smkinven log for mixed annual/monthly sectors.
This warning appears millions of times and basically crashes the log analyzer.

############################################################################

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

Backtrace for this error:
#0 0x146908752171 in ???
#1 0x146908751313 in ???
#2 0x146907e085af in ???
#3 0x146907e72bd8 in ???
#4 0x4237c9 in ???
#5 0x40322e in ???
#6 0x426f9e in ???
#7 0x46e462 in ???
#8 0x4030fc in ???
#9 0x146907df47e4 in ???
#10 0x40313d in ???
#11 0xffffffffffffffff in ???
Segmentation fault (core dumped)
383.062u 4.316s 6:39.22 97.0% 0+0k 6906040+128792io 48pf+0w

now checking log file /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs/smkinven_nonroad_jan_2022he_cb6_22m.log


  • ERROR detected in logfile:
  • /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs/smkinven_nonroad_jan_2022he_cb6_22m.log

ERROR: detected in Smkinven
ERROR: Running smk_run for part 1 in jan_2022
inlog = /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs/smkinven_nonroad_jan_2022he_cb6_22m.log
Removing the many ‘Monthly inventory is missing’ warnings from the Smkinven log for mixed annual/monthly sectors.
This warning appears millions of times and basically crashes the log analyzer.

log analyzer
Getting message data (might take some time)…
grep: /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs: Is a directory
grep: /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs: Is a directory
Finished getting data
Classifying message types…
Total number of known messages: 32
Total number of unknown messages: 0
Level 3 analysis…
Finished classifying message types
log analyzer
Getting message data (might take some time)…
grep: /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs: Is a directory
grep: /data/chemstg99/haohe/2022v2/2022he_cb6_22m/intermed/nonroad/logs: Is a directory
Finished getting data
Classifying message types…
Total number of known messages: 32
Total number of unknown messages: 0
Level 1 analysis…
Finished classifying message types
Testing for exit priority <= 1
All message priorities > 1

Hao,

The error message from your run with SMOKE v5.2.1 debug does not give the full traceback to which subroutine in smkinven where this issue occur. Please verify that you did point to SMOKE executables in the v5.2.1 debug that you’ve just compiled in directory_definitions.csh

I could not replicate your issue as my test run with nonroad sector in the EMP 2022he was successful. I wonder if there were some change that you made to your run configuration or input file that may have caused this issue.

Here are my suggestions:

  • Please try also recompile I/O API with debug option and then recompile SMOKE with debug option. You could refer to our instruction for compiling I/O API. Hopefully that would give us more info on where the issue occurred

  • Please share your run script and your modified input files (if any) so we can look more into the issue

Huy