How to get conditions data from Frontier cache

Complete: 3

Prerequisites

  • CMSSW version : CMSSW_1_0_0 or higher

Job Configuration

check frontier configuration for your local site

Check the calib-data section of ${CMS_PATH}/SITECONF/local/JobConfig/site-local-config.xml
How to config the calib-data section of site-local-config.xml is described here.

set up PoolDBESSource module with the following parameters:

  • string connect = "frontier://frontierdatabase/detectorschema"
    These are the frontier to oracle database name mappings:
    • FrontierProd -> cms_orcoff_prod (offline only)
    • FrontierInt -> cms_orcoff_int (offline only)
    • FrontierPrep -> cms_orcoff_prep (offline and from the online .cms network at LHC Point 5)
    • FrontierArc -> cmsarc (offline only)
    • FrontierOnProd -> cms_orcon_prod (online only)
    • FrontierOnInt -> cmsintr (online only)
      If you need others send email to cms-frontier-support@cernNOSPAMPLEASE.ch.
  • You can add additional frontier parameters in parentheses (parameters detailed here) after the database selector, for example:
         string connect="frontier://FrontierPrep(retrieve-ziplevel=0)/CMS_COND_FRONTIER" 
    Note - you can find the list of available detector schemas here.

Example

Example configuration file ecal_pedestals_frontier_cfg.py for CMSSW_3_1_0 and later:
 import FWCore.ParameterSet.Config as cms

 process = cms.Process("TEST")
 process.PoolDBESSource = cms.ESSource("PoolDBESSource",
     DBParameters = cms.PSet(
         messageLevel = cms.untracked.int32(0)
     ),
     timetype = cms.string('runnumber'),
     toGet = cms.VPSet(cms.PSet(
         record = cms.string('EcalPedestalsRcd'),
         tag = cms.string('EcalPedestals_30x')
     )),
     connect = cms.string('frontier://FrontierInt/CMS_COND_31X_FRONTIER')
 )

 process.source = cms.Source("EmptySource",
     numberEventsInRun = cms.untracked.uint32(1),
     firstRun = cms.untracked.uint32(1)
 )

 process.maxEvents = cms.untracked.PSet(
     input = cms.untracked.int32(5)
 )
 process.get = cms.EDAnalyzer("EventSetupRecordDataGetter",
     verbose = cms.untracked.bool(True),
     toGet = cms.VPSet(cms.PSet(
         record = cms.string('EcalPedestalsRcd'),
         data = cms.vstring('EcalPedestals')
     ))
 )

 process.dump = cms.OutputModule("AsciiOutputModule")

 process.p = cms.Path(process.get)
 process.ep = cms.EndPath(process.dump)
 

Run the example with this:

 cmsRun ecal_pedestals_frontier_cfg.py 

Debugging

If you want to see Frontier debug and logging information, set the following environment variables:
    FRONTIER_LOG_LEVEL=debug 
    FRONTIER_LOG_FILE=frontier_client.log 

Before CMSSW_3_1_0, writing the log file to an AFS file system was very slow and could greatly slow down cmsRun. You may want to direct it to a local disk such as somewhere under /tmp instead.

If there is a problem with a frontier cache server or a central frontier server, it is not likely to hang for long because the client will time out within 10 seconds of no activity and try another server in its list until the list is exhausted. You can enable debugging and tail the log to find out if it is in the middle of an operation.

There is also a script to extract just the SQL queries from the log file. It is frontierqueries in the default path beginning in CMSSW_3_3_0; if you are using an older version it can be found in ~dwd/bin/frontierqueries on lxplus.cern.ch. If a line begins with '*', that means it is a "short-lived" query, and if it begins with "-" that means that it was found in the local client cache and was not sent to any server. At the end of each line is a parenthesized pair of numbers like (MMM/NN%); MMM is the full size of the result of the query in bytes, and NN is the compression percentage (only present if compression is enabled).

Review Status

Reviewer/Editor and date Comments
ZhenXie - 09 Aug 2006 page author
JennyWilliams - 03 Apr 2007 moved page into swguide

Responsible: ZhenXie
Last reviewed by: Reviewer

Edit | Attach | Watch | Print version | History: r29 < r28 < r27 < r26 < r25 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r29 - 2012-01-17 - DaveDykstra



 
    • 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-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback