Root on /cvmfs/

Hello, I can access by ssh to Geant4 on /cvmfs/ by this code

source /cvmfs/geant4.cern.ch/geant4/10.6.p02/x86_64-centos7-gcc8-optdeb-MT/bin/geant4.sh

is there something like this for ROOT?

Thank you


Please read tips for efficient and successful posting and posting code

ROOT Version: Not Provided
Platform: Not Provided
Compiler: Not Provided


Hi,

There is: you can run for instance

source /cvmfs/sft.cern.ch/lcg/views/LCG_97/x86_64-centos7-gcc8-opt/setup.sh
root

Cheers,
Jakob

Thank @jblomer I tried it but I got error

I also found this one

but you see…I tried so much command but the didn’t work…what should I write?

Moreover, Do I’ve to upload the macro here

/cvmfs/sft.cern.ch/lcg/app/releases/ROOT/6.22.00/x86_64-centos7-gcc48-opt/macros

?

Thank you

EDIT Looking on the ROOT forum I found this message of @Axel

so I tried it and it works (even if it’s an old version of ROOT)

but when I try to upload my macro on

/cvmfs/sft.cern.ch/lcg/app/releases/ROOT/6.09.02/x86_64-centos7-gcc48-opt/root/macros

I can’t do it…so where should I upload my macro?

You are using Windows, do you expect to be able to run CentOS7 binaries?

If not, consider downloading and installing a Windows binary release of ROOT, see https://root.cern/releases/release-62200/#binary-distributions

Hi @Axel I’ve ROOT on my computer (windows distribution). What I mean is:

  1. I’m making Geant4 simulation by ssh connection. I’m able to use this Geant
    source /cvmfs/geant4.cern.ch/geant4/10.6.p02/x86_64-centos7-gcc8-optdeb-MT/bin/geant4.sh
  2. Unfortunately I get a 3GB root file, so it need time to download the ROOT file on my computer to analyse it by my own ROOT on my computer, then I would like to use on-line ROOT (as I do for Geant)!
  3. I found your message and I was able to open on line ROOT as you can see by this image

but I don’t know where to upload my macro (I can’t upload it on /cvmfs/sft.cern.ch/lcg/app/releases/ROOT/6.09.02/x86_64-centos7-gcc48-opt/root/macros

Use scp, see e.g. https://serverspace.io/support/help/copy-files-and-run-commands-through-ssh/

Try this:

$ /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/startprefix

Note that you should run the script rather than source it. Inside that environment you will have Geant 10.6.2 and ROOT 6.22, 6.20 and 6.18 with no extra setup required. Cheers,

Thank you the both @axel and @amadio

I runned in gentoo ROOT by the command

root -l

I read there is Geant too. What is the command to lunch Geant here?
Thank you

I am not sure I understand the question. You probably have your own code that uses Geant4. There is no setup required, if you just rebuild your own simulation code, it should use the Geant4 from that environment already. If the code you are using is provided by your institute, then you can use the Gentoo environment just to use ROOT.

@amadio, how does that allow @faca87 to run his script (that sits on his Windows computer) on lxplus? I don’t think your gentoo-prefix is solving anything here - i.e. I believe it’s just adding to @faca87’s confusion :slight_smile: ?

@faca87 wants to use ROOT where he/she is logged in via SSH, not on Windows.

I mean this:

  1. On my own computer, I compile by this code

cmake -DGeant4_DIR="C:\Program Files\geant4_10_06-install\lib\Geant4-10.6.1" "C:\B1"

  1. By ssh connection, I’m currently compiling by this code
    source /cvmfs/sft.cern.ch/lcg/contrib/gcc/8.3.0/x86_64-centos7-gcc8-opt/setup.sh
    source /cvmfs/geant4.cern.ch/geant4/10.6.p02/x86_64-centos7-gcc8-optdeb-MT/bin/geant4.sh
    /cvmfs/sft.cern.ch/lcg/contrib/CMake/3.14.2/Linux-x86_64/bin/cmake ../

  2. You wrote

I understand that in gentoo there are both ROOT 6.xx and Geant 10.6.2 and then I asked you the code to compile Geant4 simulation by using this enviroment. Or did I understand wrong?

Exactly @amadio! @Axel I’ve Geant4 and ROOT on my computer but

  1. I need to use Geant4 by ssh connection connecting to the computer hosted in the laboratory because I need to simulate many events, then I can’t simulate by using my own computer (it need so much time!)

  2. Given that I simulate many events, I get a big file ROOT, so I want to analyse them by ssh connection using on line ROOT so that I don’t have first to download the file!

I understand now what you mean. Here’s how I compiled example B1 from Geant4 on lxplus:

lxplus B1 $ /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/startprefix
Entering Gentoo Prefix /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64
id: cannot find name for user ID 75748
 * Error: Who are you?  id -un doesn't know...
lxplus ~ $ mkdir B1
lxplus ~ $ cd B1
lxplus ~ $ ls /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/share/geant4/examples/basic/B1/
CMakeLists.txt  exampleB1.in    GNUmakefile     include/        README          run1.mac        src/            
exampleB1.cc    exampleB1.out   History         init_vis.mac    .README.txt     run2.mac        vis.mac         
lxplus B1 $ cmake /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/share/geant4/examples/basic/B1
-- The C compiler identification is GNU 8.4.0
-- The CXX compiler identification is GNU 8.4.0
-- Check for working C compiler: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/bin/cc
-- Check for working C compiler: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/bin/cc - works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/bin/c++
-- Check for working CXX compiler: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/bin/c++ - works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found EXPAT: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libexpat.so (found suitable version "2.2.9", minimum required is "2.2.9") 
-- Found ZLIB: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libz.so (found suitable version "1.2.11", minimum required is "1.2.11") 
-- Found XercesC: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libxerces-c.so (found suitable version "3.2.2", minimum required is "3.2.2") 
-- Found Freetype: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libfreetype.so (found suitable version "2.10.2", minimum required is "2.10.2") 
-- HDF5: Using hdf5 compiler wrapper to determine C configuration
-- Found HDF5: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib64/libhdf5.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib64/libpthread.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib64/libz.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib64/libdl.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib64/libm.so (found suitable version "1.10.5", minimum required is "1.10.5")  
-- Looking for H5_HAVE_THREADSAFE
-- Looking for H5_HAVE_THREADSAFE - found
-- Found X11: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/include   
-- Looking for XOpenDisplay in /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libX11.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libXext.so
-- Looking for XOpenDisplay in /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libX11.so;/cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found OpenGL: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libOpenGL.so   
-- Found Motif: /cvmfs/sft.cern.ch/lcg/contrib/gentoo/linux/x86_64/usr/lib/libXm.so  
-- Configuring done
-- Generating done
-- Build files have been written to: /afs/cern.ch/user/a/amadio/B1
lxplus B1 $ make
Scanning dependencies of target exampleB1
[ 12%] Building CXX object CMakeFiles/exampleB1.dir/exampleB1.cc.o
[ 25%] Building CXX object CMakeFiles/exampleB1.dir/src/B1ActionInitialization.cc.o
[ 37%] Building CXX object CMakeFiles/exampleB1.dir/src/B1DetectorConstruction.cc.o
[ 50%] Building CXX object CMakeFiles/exampleB1.dir/src/B1EventAction.cc.o
[ 62%] Building CXX object CMakeFiles/exampleB1.dir/src/B1PrimaryGeneratorAction.cc.o
[ 75%] Building CXX object CMakeFiles/exampleB1.dir/src/B1RunAction.cc.o
[ 87%] Building CXX object CMakeFiles/exampleB1.dir/src/B1SteppingAction.cc.o
[100%] Linking CXX executable exampleB1
[100%] Built target exampleB1

You can probably compile in a similar way on your institute’s computer.

Thank you @amadio!

1 Like

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