uscms.org  www 

User Software and Computing

Computing Environment Setup : Software Setup

General CMS Software Environment

The CMS software environment for csh and tcsh users is set by sourcing the environment setup script.

In tcsh, csh:

source /cvmfs/cms.cern.ch/cmsset_default.csh

In bash, sh:

source /cvmfs/cms.cern.ch/cmsset_default.sh

This will set general CMS software environment variables, extend the user's $PATH to include CMS specific utilities and tools, and define aliases used in the CMS software projects.

Note:, if you wish to change your default login shell, open a Service Now Request: click on "Create a New Scientific Computing Request using SCD Catalog", and then on "Distributed Computing", and "Submit a request to service providers". Explain your request to change your default login shell.

Platform specific environment

SCRAM automatically sets the correct architecture based on the version of Scientific Linux installed on a node. The default (which may change) is slc6_amd64_gcc472. You only need to redefine the architecture if you want to change the default. For a more detailed example, see the CMS WorkBook. For example, to access newer releases do the following:

In tcsh:

setenv SCRAM_ARCH slc6_amd64_gcc493

Or in bash:

export SCRAM_ARCH=slc6_amd64_gcc493

cmsenv and the application runtime environment

Runtime environment for applications is generated by the scramv1 runtime -[c]sh command, executed in the area associated with a particular version of product. It may be the development area created by a user, or a public release area.

The output of that command differs between versions, and the runtime environment itself is not set automatically. To set it, the user need to evaluate the result of the command above using the shell eval, this has been conveniently aliased to cmsenv, which is available after sourcing /cvmfs/cms.cern.ch/cmsset_default.[c]sh.

Show me how [β] (may use an older version of SCRAM_ARCH and CMSSW)


CMSSW and version control is handled by GitHub. This link describes how to setup and access the CMSSW github.

Additionally, there is the Github HATS at the LPC from 2017.

Login shell

The default login shell at the cmslpc cluster is tcsh.

To find out what your current shell is, use the command:

[username@cmslpc37 ~]$ echo $0

To permanently change your default login shell, open a ServiceNow General request, being sure to:
  • Put in your experiment as E-892/919 (CMS)
  • Explain what shell you want changed to (bash for instance)
  • Specify that this is for the cmslpc cluster

Note that changing one's shell manually may not process default EOS aliases.

LCG software and standalone ROOT

There is a lot of additional software available through the LHC Computing Grid (LCG). For more information on what is available, consult: LCG list of packages for release 89, and PersistencyReleaseNotes#LCG_89 twiki. To setup the software from cvmfs, do the following (tcsh):

[username@cmslpc37 ~]$ source /cvmfs/sft.cern.ch/lcg/views/LCG_89/x86_64-slc6-gcc62-opt/setup.csh


[username@cmslpc37 ~]$ source /cvmfs/sft.cern.ch/lcg/views/LCG_89/x86_64-slc6-gcc62-opt/setup.sh

Note that this may set different versions of python and root than your typical CMSSW, so you may wish to not use this command in the same shell as a CMSSW software environment. You can then configure a standalone ROOT (not in CMSSW) - be sure your gcc compiler is a similar version (note the LCG environment above will pickup a standalone ROOT): tcsh:

[username@cmslpc37 ~]$ source  /cvmfs/sft.cern.ch/lcg/releases/ROOT/6.10.02-19565/x86_64-slc6-gcc62-opt/bin/thisroot.csh


[username@cmslpc37 ~]$ source  /cvmfs/sft.cern.ch/lcg/releases/ROOT/6.10.02-19565/x86_64-slc6-gcc62-opt/bin/thisroot.sh


For further references about using scram commands please consult the CMS WorkBook SetComputerNode. For questions concerning this page and CMS software environment at FNAL consult the LPC Computing Get Help list of resources.

Webmaster | Last modified: Thursday, 12-Oct-2017 10:17:52 CDT