Problem with running basic examples

Hi All,

I have problems in running examples, in particular example B1.

I installed Geant4-v.11.0.0. on a virtual machine Centos7 and I think the installation procedure was successful.

However I’m not able to run example B1, category basic examples.
When I try the following message appears: “: Segmentation fault (Address not mapped to object [0x10])
Annullato (core dumped)”

The problem is that, maybe, I don’t produce the executable correctly and/or in the correct folder. May anyone tell me step by step how I should do?

Thanks in advance,
Valeria

1 Like

Hi @valeriacellamare

I Certainly can comment on Address not mapped appears when there is problem with overlapping, or physics not described proper, or run/event action classes are not defined properly.

Re-Run example 1 without any modification. On your screen you find “Cumulated dose per run, in scoring volume : 3.57687 picoGy rms = 1.17765 picoGy” for 100 events.

Ciao,
VRS

Hi @drvijayraj,

Thanks for your reply!
The problem is that I didn’t change anything in any of the files in the folder containing the example.

Could you say if the building procedure to produce the executable has to be done in the folder containing the example (in my case folder B1) or in the folder ‘examples’? And where to run the command 'make -j N B1?

Thanks
Valeria

Ok !

Follow this way in testing an example.
Create work directory anywhere as per your choice. Copy and paste basic B1 example from Geant4 or build directory examples or whatever location you have.

  1. cd basic/B1
  2. create build directory
  3. cd build
  4. cmake …/
  5. make
  6. ./exampleB1

You can find full details here. How to Make an Executable Program — Book For Application Developers 11.0 documentation

:slight_smile:
VRS

Hi, @drvijayraj

I followed your suggestion and the documentation you sent…
The same error message appears.

Maybe is it an error in the installation?
Again, the same error appears.

Thanks

what steps you followed.

btw !

download here.geant4.web.cern.ch

installation guide
http://cern.ch/geant4-userdoc/UsersGuides/InstallationGuide/html/

vrs

Dear Valeria,

There can be many reasons that an installation does not work, most unrelated to Geant4 but having to do with your computer’s setup. It is difficult to diagnose without (probably a lot of) additional information.

Have you tried to compile a very simple C (or C++) program with your virtual machine ?

Although it will take a lot longer to download, it would probably make sense for you to try to use the Geant4 Virtual machine, which is a ready made VM with Geant4 installed. Its most current version can be found at Geant4 Virtual Machine – G4VM with RockyLinux 8.5 Geant4.11.0 patch-02

If you need to use CentOS 8, you can find older versions of the Geant4 VM for Geant4 release 10.7 which use it.

Best regards,
John

Hi,

Thank you for your reply.
In the end I found the same solution you said using VM with Geant already installed.

I tried again to install in on my vm, but without success. The C compiler works fine because I use C and C++ for other things.

I don’t know what the problem could be. I read that sometimes virtual box has problems with geant. Maybe it’s due to this.

Best regards,
Valeria

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.