The official CMS
tutorial. 
[Most of the stuff below is obsolete. I'll update it again, should I need to run CMS code again.]
CMS at Imperial
Gordon's CMS tutorial. 
Most of the tutorial wrt CMSSW_4_1_5 still applies. 
CMS code
Which
release to use. 
CMSSW CVS.
Shorthand
[The currently (Sept 13) working version of the code is in /home/hep/dbauer/cms/CMSSW_5_3_11_patch6 on the lx machines.]
To make a new release area do: 
source /vols/cms/grid/setup.sh 
At this point I can list all the available releases *depending on the SCRAM_ARCH that is setup*: scram list 
To see other SCRAM_ARCH available do: ls /vols/sl5_exp_software/cms/ 
To get the 5_3_N releases I need: export SCRAM_ARCH=slc5_amd64_gcc462 
scram project CMSSW CMSSW_5_3_11_patch6 (do this only once) 
cd CMSSW_5_3_11_patch6 
cmsenv
All code goes in the src directory. To run use the test directory under src. 
[copy code from previous release and compile: cd src; cp -r /home/hep/dbauer/cms/CMSSW_4_4_5_patch5/src/Tutorial . ; cd .. ; scram b] 
To compile use 'scram b'. 
To run locally use: cmsRun config_cfg.py 
To use crab: 
 . /vols/cms/grid/CRAB/current/crab.sh
crab -create -cfg crab.cfg (ignore "crab:  error detecting glite version") error 
crab -submit (will submit latest set of created jobs) 
or 
crab -submit -c [name of creab directory it just made, e.g. crab_0_130912_120647] 
to submit a specific project. 
crab -status -c crab_0_120420_162053 
and when finished: crab -getoutput -c crab_0_120420_162053 
CRAB exit codes.
To check if results are on storage element: 
lcg-ls srm://gfe02.grid.hep.ph.ic.ac.uk/pnfs/hep.ph.ic.ac.uk/data/cms/store/user/dbauer/[user_remote_dir] 
To locate a dataset use DAS.
A valid query is e.g. dataset dataset=/DoubleMu/*2012*/AOD
Here is an explanation between the difference between AOD and RECO. 
A random snapshot of the working code is here.