TWiki> TOTEM Web>SoftwareHowto (revision 13)EditAttachPDF

Software HOWTO

How to fetch TOTEM offline code from CVS repository ? (DEPRECATED)

Set up some variables. Keep in mind, that in order to make changes to CVS, your AFS account should be added to appropriate file.

export CVSROOT=""
export CVS_RSH="ssh"

If you want just to fetch and run code, then use export command:

cvs export -r HEAD offline/cmssw

If you want to work as other user, you can replace USERNAME with desired one:

export CVSROOT=""

You can find more info on Totem CVS repository page.

How to set up CMSSW workspace ?

Import some enviromental variables (this will enable you to run scram command for further compilation):

source /afs/

Go to empty directory and fetch local copy of CMS workspace:

scram project CMSSW CMSSW_3_1_1

Now you need to go to newly created CMSSW_3_1_1/src directory, put there you CMSSW modules, and start compilation.

How to compile your code (modules) ?

Import some enviromental variables (this will enable you to run scram):

source /afs/

Go to CMSSW_?_?_?/src or subdirectory of that. Compile everything under current directory

scram b

If you want to compile using parallel threads, you can specify how many of them you want. This will speed up compilation, especially on multicore/multiprocessor machines like pctotem31:

scram b -j 4

How to run your code (configuration file) ?

Import some environmental variables (this will enable you to run scram):

source /afs/

Go to CMSSW_?_?_?/src. Set up runtime enviroment (this will enable you to run cmsRun command):

eval `scram runtime -sh`

Run your config file:

cmsRun path_to_configuration_file.cfg

How to browse output file in ROOT ?

SSH to lxplus

ssh -X lgrzanka@lxplus

Import some environmental variables:

source /afs/

Change current dir to CMSSW workspace:

cd /afs/

Setup runtime:

eval `scram runtime -sh`

Setup root variables (you can use more up to date ROOT version):

export ROOTSYS=/afs/
export PATH=$PATH:$ROOTSYS/bin

Enter root and type:


To browse ROOT file use:

TBrowser t;

to plot some data from tree structure, RightClick on Event and choose StartViewer

To quit from ROOT use:


How to use CASTOR storage ?

  • nsls - list home castor directory
  • nsls /castor....
  • nsls -l - long listing
  • rfcp /castor/ my/local/file . - copy from castor to local disk

How to indent C++ code ?

How to manage jobs on lxbatch ?

  • Submit: bsub
  • Check status: bjobs
  • Kill: bkill

How to correct strange behavior of Backspace key on lxplus ?

If after pressing Backspace key you got something like ^?, then type:

stty sane

and your console will behave well.

-- LeszekGrzanka - 27-Dec-2009

Edit | Attach | Watch | Print version | History: r17 | r15 < r14 < r13 < r12 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r13 - 2010-06-01 - LeszekGrzanka
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    TOTEM All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2021 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
or Ideas, requests, problems regarding TWiki? use Discourse or Send feedback