TWiki> CMSPublic Web>SWGuide>SWGuideCrab>SWGuideCrab2 (revision 1)EditAttachPDF

CMS Remote Analysis Builder 2 - CRAB2


CRAB is a utility to submit CMSSW jobs to distributed computing resources. By using CRAB you will be able to:

  • Access CMS data and Monte-Carlo which are distributed to CMS aligned centres worldwide.
  • Exploit the CPU and storage resources at CMS aligned centres.
Before starting to learn about CRAB, you may want to get an overview of the Grid model and of a typical analysis workflow. For that purpose read the following chapters of the CMS Offline WorkBook: For detailed documentation about CRAB, see section Advanced CRAB Documentation further down in this page.

CRAB Client and Server


Getting Started

This section describes how to begin using CRAB to perform your analysis on the Grid.


To use CRAB to submit your CMSSW job to the Grid you must meet some prerequisites, which you can find in the CRAB Prerequisites page. There you will also find information on how to setup your environment to use CRAB at CERN and how to do a private installation of CRAB.

Basic Workflows

You can find a guide to the basic functionality of CRAB in the CRAB Basic Workflows page. If you have never used CRAB before, it is a good place to learn how to use the tool.

Latest Tutorial

Regular tutorials are given on using CRAB. The course material for these tutorials is stored online for future reference, although it refers to specific CRAB and CMSSW versions that may no longer be available.

Advanced CRAB Documentation

The advanced user should refer to the following specific documentation as appropriate.

CRAB Online Manual

The CRAB Online Manual provides detailed documentation about CRAB commands and configuration parameters. This is the same documentation you get from the crab -help command.

CRAB Publication to DBS



LPC CAF at FNAL is a local analysis facility only accessible to users with a local account. Like for CERN CAF, data there are not accessible to grid jobs.

To use CRAB on the FNAL LPC CAF, you need to do roughly as you do at CERN: 1) Setup of the gLite UI 2) Setup CMSSW 3) Setup CRAB

For SL4 (cmslpc):

source /uscmst1/prod/grid/gLite_SL4.(c)sh
cmsrel CMSSW_X_Y_Z  (only first time)
source /uscmst1/prod/grid/CRAB/crab.(c)sh

For SL5 (cmslpc-sl5):

source /uscmst1/prod/grid/gLite_SL5.(c)sh
cmsrel CMSSW_X_Y_Z  (only first time)
source /uscmst1/prod/grid/CRAB/crab.(c)sh

If you want to use CRAB to submit to the local condor batch system, please see the additional instructions at CRABonLPCCAF. If you created a .no_glite_setup file during the CRAB 26x/27x transition, you can safely delete that file now as it is no longer used.

Setup on other places

Please be aware that CRAB needs gLite_3_2 on sl5 and gLite_3_1 on SL4 (i.e. works with the official gLite UI version for the two operating systems).


CRAB Developers Documentation

Using CRAB to generate MonteCarlo events

FAQ, Troubleshooting, Getting Support

Frequently asked questions (FAQ)

List of CRAB exit codes

Diagnosing Problems

If a problem is encountered with CRAB you can begin with the following template. This template will help you to identify the nature of the problem and if a solution already exists:

Before contacting the CRAB feedback hypernews, you should consult the Frequently Asked Questions (FAQ) page.

Getting Support

If you have still not found the solution to your problem, you may wish to consult the CRAB feedback hypernews forum.

If you are running locally in LPC, in case of problems please contact:

When contacting crabFeedback, you must

  • write brief description of the problem and of relevant error messages
  • upload all files needed for debug. There is a crab option that provides the upload of your logs:
    • if the problem affects some or all jobs, pick one with the issue (jobid) and do
      • if jobs are in "done" status:
        crab -getoutput <jobid> 
        so the stdout and fjr will be retrieved, then
        crab -uploadLog <jobid> 
        to upload all the necessary files
      • if your jobs are aborted:
        crab -postMortem <jobid>
        so the postMortem file will be generated
        crab -uploadLog <jobid> 
        to upload all the files
  • report the URL provided by the crab -uploadLog command in the email for the support.
  • note: of course if your crab working directory is not the default <username>_0_... you need to add the -c option like for any other crab command

Useful Links

CRAB Releases Notes

  • CRAB client - standalone
    • currently recommended version of the CRAB client, i.e. the one which is default on lxplus, is available at CRAB_current.tgz. Release notes here.
    • Older CRAB versions here
    • Even older CRAB versions here

CRAB references

CRAB presentations, posters, publications and tutorials page

-- AndresTanasijczuk - 07 Oct 2014

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r1 - 2014-10-07 - AndresTanasijczuk
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    CMSPublic All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2020 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