GSI Forum
GSI Helmholtzzentrum für Schwerionenforschung

Home » PANDA » PandaRoot » Bugs, Fixes, Releases » Segmentation Violation when simulating events with run_sim1.C
Segmentation Violation when simulating events with run_sim1.C [message #7816] Wed, 04 February 2009 13:59 Go to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi all,

I'm running a slightly modified version of macro/run/run_sim1.C with Pandaroot Revision 4484 for simulation.
Unfortunately, after a few hundred events, I get the following error:

*** Break *** segmentation violation
Toggle Spoiler


Can anybody confirm this or point me at what might be going wrong?

Thanks in advance,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7817 is a reply to message #7816] Wed, 04 February 2009 14:19 Go to previous messageGo to next message
Ralf Kliemt is currently offline  Ralf Kliemt
Messages: 507
Registered: May 2007
Location: GSI, Darmstadt
first-grade participant

From: 141.30.85*
Hi Marius,

What did you change exactly in the macro?
What is the output before the segfault backtrace?

To me it looks like the geometry you use is not well. Maybe a corrupted file or a second TGeoManager?

Regards, Ralf.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7818 is a reply to message #7817] Wed, 04 February 2009 14:37 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
I have run 2000 events without any error.

Could you please send us exactly the macro that you have used?
Re: Segmentation Violation when simulating events with run_sim1.C [message #7819 is a reply to message #7817] Wed, 04 February 2009 14:41 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Ralf,

the only changes in the macro were the use of PndFlatParticleGenerator and taking the number of events to generate and the output file to generate as parameters.

I have included the output before the actual error in the spoiler below, which basically looks that way for a few hundred events before the crash.

Toggle Spoiler


What irritates me a little is that it worked a while ago before I updated my Pandaroot installation.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7820 is a reply to message #7819] Wed, 04 February 2009 14:45 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
You could try with the normal BoxGenerator, and tell us if it works.
You should also attach the first part of the log message, before all the

>>> Event 1
CbmMCApplication::GeneratePrimaries()

Maybe you have a corrupted file that give you problems.
On which system are you running?

Again, please attach your macro. So that we can reproduce your error.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7821 is a reply to message #7818] Wed, 04 February 2009 14:47 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano,

these are the contents of my modified version of the macro.

Toggle Spoiler


If it works for you, it might indeed well be something with the geometry file of the MVD, which is the only really different input parameter I have found until now.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7822 is a reply to message #7816] Wed, 04 February 2009 14:54 Go to previous messageGo to next message
Ralf Kliemt is currently offline  Ralf Kliemt
Messages: 507
Registered: May 2007
Location: GSI, Darmstadt
first-grade participant

From: 141.30.85*
Hi Marius,

Try first the usual Mvd geometry. If that works...

Ralf.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7823 is a reply to message #7821] Wed, 04 February 2009 14:55 Go to previous messageGo to next message
asanchez is currently offline  asanchez
Messages: 350
Registered: March 2006
first-grade participant
From: *gsi.de
Hi Maybe you should change the name of the macro accordently
to run_sim1_PndFlatGen(Int_t numevents, TString basefile).
Anyway the M before run_sim1_PndFlatGen(Int_t numevents, TString basefile) looks suspicious.!!

regards
Alicia.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7824 is a reply to message #7821] Wed, 04 February 2009 14:57 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
Hi,
where have you taken the MVD geometry:

Mvd->SetGeometryFileName("MVD_v1_2addDisks.root");

?

Probably that geometry is not stable, or at least it is not in svn, so it could be the cause of your error (it looks like some geometry error).
try with the standard MVD geometry, and let us now. Unfortunately I do not have that geometry so I cannot cross ckeck.

Re: Segmentation Violation when simulating events with run_sim1.C [message #7825 is a reply to message #7820] Wed, 04 February 2009 15:01 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano,

I also tried with the CbmBoxGenerator, which gives me the same results.

When I just reran the macro to reproduce the first lines of the output (they were not included in the history buffer of the previous run anymore), it unfortunately crashed even earlier.

Actually I have no idea whether this is related, but I'll just post the output I got and retry after a reboot.

Toggle Spoiler


My system is a Suse Linux 10.2 running kernel 2.6.18.8-0.13-default #1 SMP on an Intel Core2 6600.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7826 is a reply to message #7823] Wed, 04 February 2009 15:08 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Alicia,

thanks for your suggestion, the M is actually caused by me copying the standard files to a different name before I make any modifications in order to have the original for comparison just in case anything goes wrong Wink

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7827 is a reply to message #7822] Wed, 04 February 2009 15:13 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Ralf,

changing back to standard geo gives me this:

Toggle Spoiler


However, as it got worse in the meantime and now crashes even earlier than before (without any changes I'm aware of), I'll also try the standard geo once again after a clean boot and see what this gives.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7828 is a reply to message #7827] Wed, 04 February 2009 15:16 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
Error in <TUnixSystem::DynamicPathName>: libG4OpenGL[.so | .sl | .dl | .a | .dll] does not exist

Probably there something screwed up in your environment. Try from a new terminal.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7829 is a reply to message #7824] Wed, 04 February 2009 15:20 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano,

the file is a modified MVD geometry with 2 additional strip discs in forward direction. Tobias made them with his CAD converter and I also used it for some simulations before.

Currently, even the standard geometry crashes Sad I'll let you know if at least this works again after a reboot.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7830 is a reply to message #7828] Wed, 04 February 2009 15:44 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano,

this particular error persists even after reboot. Now I'm a bit puzzled where this suddenly came from and especially what I can do to fix this.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7832 is a reply to message #7830] Wed, 04 February 2009 18:27 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi all,

I managed to get a step further now:

The second (new, immediate) crash which occured later during testing was fixed by deleting the file testparams.root. It might have been corrupted from a previous crash.

The first (initial, appearing after a few 100 events) error which is the actual reason for my post, still persists when running with the parameters below. In the meantime, I also updated Pandaroot to Revision 4500.

Mrun_sim1_PndFlatGen.C
Toggle Spoiler


First lines of output
Toggle Spoiler


Last lines of output
Toggle Spoiler


Thanks for your input,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7836 is a reply to message #7832] Thu, 05 February 2009 09:59 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *albacom.net
First suspect point:

Quote:

Loading Geant4 granular libraries ...
Error in <TUnixSystem::DynamicPathName>: libG4OpenGL[.so | .sl | .dl | .a | .dll] does not exist in .:/usr/local/panda/fairroot/fairsoft/tools/root_v5.20.00/lib::/usr/local /panda/fairroot/fairsoft/tools/root_v5.20.00/lib:/usr/lib:/usr/X11R6/lib :/home/mertens/pandaroot/cbuild/lib:/home/mertens/pandaroot/cbuild/lib:/ home/mertens/pandaroot/tools/root/lib:/home/mertens/pandaroot/generators /lib:/home/mertens/pandaroot/generators/lib:/home/mertens/pandaroot/tran sport/geant3/lib/tgt_linux:/home/mertens/pandaroot/transport/geant4/lib/ Linux-g++:/home/mertens/pandaroot/transport/geant4_vmc/lib/tgt_linux:/ho me/mertens/pandaroot/transport/vgm/lib:/home/mertens/pandaroot/cern/clhe p/lib:/usr/local/panda/fairroot/fairsoft/tools/root_v5.20.00/cint/cint/s tl


In your system you do not have openGL and/or motiv libraries. Then your geant4 was not compiled with them and it has not created libG4OpenGL. I think (and hope) this should not affect the analysis.
To solve this, you should install opengl/motif in your computer, than rebuild (first you have to clean it) geant4 and g4vmc.

Second suspect point:

Quote:


Warning in <TClass::TClass>: no dictionary for class RangeValues is available
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fPt" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fPhi" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fEta" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fRapidity" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fP" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fTheta" will not be saved
Warning in <TStreamerInfo::Build:>: PndFlatParticleGenerator: RangeValues has no streamer or dictionary, data member "fCosTheta" will not be saved


This has to be investigated. I think this is not safe.

Third suspect point:

Quote:

Info in <TG4RootNavMgr::ConnectToG4>: ROOT detector construction class connected to G4RunManager
Adding HadronPhysicsList QGSP_BERT_EMV

<<< Geant4 Physics List engine packaging library: PACK 5.4
<<< Geant4 Physics List simulation engine: QGSP_BERT_EMV 1.0

Adding SpecialPhysicsList stepLimiter+specialCuts+specialControls
Debug mode is switched on.


You have "particular" geant4 configurations, "QGSP_BERT_EMV" physics lists and options "stepLimiter+specialCuts+specialControls". Do you really need them? They could be sources of errors.
You could try the standard and tested one in your gconfig/g4Config.C, "QGSP" (or "emStandard" to not use hadronic processes) as physics list, and no options after (no step limiter and so on).

Another test could be done by using geant3, to understand if it is related only to g4 code or even to g3.

In each case, maybe the error could be related to vmc options that were never tested (at least they were never tested by us with our code). Let's try
Re: Segmentation Violation when simulating events with run_sim1.C [message #7837 is a reply to message #7836] Thu, 05 February 2009 10:48 Go to previous messageGo to next message
asanchez is currently offline  asanchez
Messages: 350
Registered: March 2006
first-grade participant
From: *kph.uni-mainz.de
Hi i'm using geant4 configurations
with gsi installation and i have up to now any problems.

Another way to check what is really going wrong
is maybe to come back to the version which has been
working before doing update, and then compare.

good luck
alicia.
Re: Segmentation Violation when simulating events with run_sim1.C [message #7842 is a reply to message #7836] Thu, 05 February 2009 16:37 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano, thanks a lot for your input, I did some more tests throughout the day...

Stefano Spataro wrote on Thu, 05 February 2009 09:59

First suspect point:
...
In your system you do not have openGL and/or motiv libraries. Then your geant4 was not compiled with them and it has not created libG4OpenGL. I think (and hope) this should not affect the analysis.
To solve this, you should install opengl/motif in your computer, than rebuild (first you have to clean it) geant4 and g4vmc.



Unfortunately, I cannot do this independently on my PC. I brought up this issue with our administrator, so he will have to help us there.

Stefano Spataro wrote on Thu, 05 February 2009 09:59

Second suspect point:
...
This has to be investigated. I think this is not safe.



I (think that I) have fixed this locally now. Unfortunately, the symptoms are still the same Sad

Stefano Spataro wrote on Thu, 05 February 2009 09:59

Third suspect point:
...
You have "particular" geant4 configurations, "QGSP_BERT_EMV" physics lists and options "stepLimiter+specialCuts+specialControls". Do you really need them? They could be sources of errors.
You could try the standard and tested one in your gconfig/g4Config.C, "QGSP" (or "emStandard" to not use hadronic processes) as physics list, and no options after (no step limiter and so on).



This one puzzles me a bit. I'm not aware of having set anything special. How can I make sure that only the configuration you mentioned applies and nothing else will interfere with it?

Stefano Spataro wrote on Thu, 05 February 2009 09:59

Another test could be done by using geant3, to understand if it is related only to g4 code or even to g3.



Unfortunately, even with removing the testparams.root before each run, also a Geant3 based simulation crashes after some 100 events.

Toggle Spoiler


Stefano Spataro wrote on Thu, 05 February 2009 09:59


In each case, maybe the error could be related to vmc options that were never tested (at least they were never tested by us with our code). Let's try


Alright, I won't be on site until Monday, but then I'll be ready for running some more tests Wink

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7843 is a reply to message #7837] Thu, 05 February 2009 16:39 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Alicia, yes, reverting to the old revision will probably be something like a last resort solution. Hopefully we'll find the reason for the segmentation violation before going that far Wink

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7863 is a reply to message #7816] Mon, 09 February 2009 17:16 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi all,

I finally narrowed down the reason for the segmentation violation on my machine:
Whenever the PndDchDetector is enabled, I get aforementioned error, regardless of any other settings I have tried.

When I comment out the lines which include the PndDchDetector, the script runs fine without errors.

@Stefano: I have now set my Geant4 options as you have suggested, however in my gconfig/g4Config.C as I got it from SVN the "particular" options were already set that way.

Best regards and thanks for your input,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7864 is a reply to message #7863] Mon, 09 February 2009 17:22 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
Hi,
I have seen that the default g4 options were changed (before they were no options).

Were there special reasons for this? (of course the question is not to Marius).

About the dch, are you using in parallel mdt and dch? Because they are overlapping somehow, and this could introduce the famous error.

[Updated on: Mon, 09 February 2009 17:31]

Report message to a moderator

Re: Segmentation Violation when simulating events with run_sim1.C [message #7865 is a reply to message #7864] Mon, 09 February 2009 17:30 Go to previous messageGo to next message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Hi Stefano,

Stefano Spataro wrote on Mon, 09 February 2009 17:22


About the dch, are you using in parallel mdt and dch? Because they are overlapping somehow, and this could introduce the famous error.



No, DCH has always been commented out since I got the script from SVN. I don't even remember whether I ever enabled it at any time. But maybe there is another overlap somewhere else? I'll start a run with only the PndDchDetector enabled and see what happens...

When just these detectors are enabled, everything runs fine:
PndTpcDetector
PndMvdDetector
PndEmc
PndTof
PndDrc

As soon as I add PndDchDetector, I get the segmentation violation.

Best regards,

Marius
Re: Segmentation Violation when simulating events with run_sim1.C [message #7866 is a reply to message #7865] Mon, 09 February 2009 17:33 Go to previous messageGo to next message
StefanoSpataro is currently offline  StefanoSpataro
Messages: 2736
Registered: June 2005
Location: Torino
first-grade participant

From: *physik.uni-giessen.de
It can be that the dch are overlapping with the solenoid.
I supose you are using the "old" FullSolenoid, maybe PandaSolenoidV833 would help (I am not sure).
Re: Segmentation Violation when simulating events with run_sim1.C [message #7867 is a reply to message #7866] Mon, 09 February 2009 17:44 Go to previous message
Marius Mertens is currently offline  Marius Mertens
Messages: 55
Registered: January 2009
continuous participant
From: *ikp.kfa-juelich.de
Stefano Spataro wrote on Mon, 09 February 2009 17:33

It can be that the dch are overlapping with the solenoid.
I supose you are using the "old" FullSolenoid, maybe PandaSolenoidV833 would help (I am not sure).


Indeed, FullSolenoid.root is the version I am using. However, PndDchDetector "alone" (i.e. with only Cave, Magnet, Dipole and Pipe) runs fine.
Together with PndDrc it gives me the segmentation violation again.
After some more testing, these two detectors seem to be the critical combination: Everything else with either PndDrc or PndDchDetector runs without errors, both of them together result in the known crash.

Best regards,

Marius

[Updated on: Mon, 09 February 2009 20:43]

Report message to a moderator

Previous Topic: Error in the PndFastSim
Next Topic: external packages on Ubuntu
Goto Forum:
  


Current Time: Sat Nov 23 11:33:14 CET 2024

Total time taken to generate the page: 0.00753 seconds