Crash when created files are so big

Hello, I notice that when the simulation has many events and the nohup file, or the ROOT file are higher than 3GB, the simulation crash. For example this is the log of a crash due to a big ROOT file.

nohup.out.txt (36.0 KB)

Is it a problem of the cvmf or of the machine hosted in my laboratory?

Do you get this error with smaller ROOT files?

What are the specs of the machine you are running on, how much RAM does it have?

Hi @php1ic [quote=“php1ic, post:2, topic:3029, full:true”]
Do you get this error with smaller ROOT files?[/quote]
No…just if the Root file or the nohup file is higher than 3GB!
[/quote]

I don’t know it because I’m not running on my computer…I’m running on the computer hosted in the laboratory (ssh connection)

If you run the command free -m after sshing in it will return the total RAM on that system.

e.g. a machine I have access to has 32GB of RAM

$ free -m
              total        used        free      shared  buff/cache   available
Mem:          32071        2598       16155          52       13316       28974
Swap:         38592           0       38592

Thank you @php1ic I didn’t know this command line!

By looking the numbers…I guess I can access only 12GB…true?
I don’t know if I can ask to improve my RAM…

The -m flag sets the output to MB so looks like you have 128GB. I was wondering if you only had 4GB so were running out reading a 3GB file. I’m going to assume this is not the case if you have 128GB :wink:

I don’t use ROOT, but google suggests something is being free’d twice. Can you run the code with gdb or valgrind?

Yes @php1ic sorry…I read bad the number!

How should I do?

Basic usage is as below (output is from I system I have access to)

$ gdb ./exampleB1 
GNU gdb (Debian 8.2.1-2+b3) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./exampleB1...done.
(gdb) 

Then type run to actually execute the simulation. Once it crashes, type where to get details about what was happening when the crash occured. Hopefully this will give you the line number causing the issue.

Hi @php1ic, I get this error using the gdb

Looks like your gdb is calling a python process. Can you please post the output of the following 2 commands

which gdb
gdb --version

Also you don’t need to run the command in the background, i.e. with a & on the end.

Hello @php1ic
Here the screen of the command

which gdb
gdb --version

and here the run whithout & (same problem got using the & )

I don’t know why python is getting involved in this process on your system. I think if you give a second argument to gdb it tries to read it as a core dump file which may be causing the issue.

Can you please running as below

$ gdb ./exampleB1 
GNU gdb (Debian 8.2.1-2+b3) 8.2.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./exampleB1...done.
(gdb) run ./run1.mac
Starting program: /home/php1ic/tmp/B1/build/exampleB1 ./run1.mac

This will likely make your simulation run a lot slower.

I notice that

  1. If I compile the file and I give the command
    gdb ./exampleB1
    I get the error that you can see in my previous printscreen

  2. If I close the terminal, I open it again and I give the command
    gdb ./exampleB1
    without compile the file again I get this (similiar to what you get too)

but whe I give the command

(gdb) run ./run1.mac

I get the errors

here the full log
log.txt (19.5 KB)

I wonder if the fact that your versions are mismatched on the major number is an issue?

Looks like your gcc is 8.?, but gdb is 7.6.1

Are there any other versions on gdb installed on that system? I think rpm will be the simplest way to check on centos

rpm -qa | grep gdb

As suggested by @anna in this topi Errors during compilation using old Geant4 versions
I’m using this gcc
source /cvmfs/sft.cern.ch/lcg/contrib/gcc/8.3.0/x86_64-centos7-gcc8-opt/setup.sh
because on the machine hosted in the laboratory there wasn’t a cmake compatible with geant4 10.6.1

Here the command
rpm -qa | grep gdb

Hi @faca87, I don’t know anything about the system you are working on, looking at the post you referenced /cvmfs/sft.cern.ch/lcg/contrib appears to be the place for newer packages. Is there a gdb in there?

Otherwise from the stackoverflow post, via google, you could try running your code via valgrind

valgrind ./exampleB1 ./run1.mac

to look for errors

Hi @php1ic I don’t know if at cvmf there is a gdb…maybe @anna knows it, because she suggested me it!

I tried to use valgrind, but you see…the command isnt’ found

Yeah, sounds like you need someone with knowledge of that system to help.

Can you not

ls /cvmfs/sft.cern.ch/lcg/contrib

to see what exists?

I agree, you should consult your supervisor to get information on how to access the necessary software (I also have no clue where do you work).

I pointed you to the gcc version you could use since you said you have access to cvmfs. For more software on cvmfs, if you cannot find it yourself following what Ian suggests, you can have a look at the LCG releases that provide a large stack of different software packages:
http://lcgdocs.web.cern.ch/lcgdocs/lcgreleases/introduction/

Thank you the both @php1ic and @anna

yes

Obviously, I wrote to my supervisor showing him this problem…but he still didn’t reply…then I guess he didn’t understand the reason because of too…