Run Info Logging

From GlueXWiki
Jump to: navigation, search

There are a couple of systems that record various run conditions while data taking.


EPICS info Log

The system described here is NOT the primary system for archiving EPICS values. For info on that, please go to the "Archiver for EPICS variables" page.

This system is used to create a a small log file in the output directory at the beginning of a run that contains some key EPICS values. The file can then be parsed for information which is then entered into a database making it easy to apply selection criteria when trying to identify runs having certain conditions. This is not necessarily a long term solution, but can serve as a stop-gap for now.

The system is implemented in the following way while running the DAQ system from the hdops account:

When the user hits the "Go" button on the Run Control GUI, the script ${DAQ_HOME}/scripts/run_go is run. This, in turn, runs a couple of other scripts including the ${DAQ_HOME}/scripts/ script. That is kept in the subversion repository here:

The script gets passed an argument "-RXXX" where XXX is the run number (non-zero padded) when run from the run_go script. Note that you can run the script without the -R argument and it will create an output file in the local directory. Thus, it is safe to run in that way for testing since it will not write any files into the RAID disk directories that will end up on tape.

During normal data taking, this script is run once at program start and creates a file named something like:


An example of the file contents can be seen below. Additional EPICS variables can be added by editing the script.

# File generated by
# $Id: 16153 2014-10-28 18:53:37Z davidl $
# $HeadURL: $
# Tue Oct 28 14:54:00 2014
# USER: hdops

RUN    = 670
TIME   = Tue Oct 28 14:54:00 2014
YEAR   = 2014
MONTH  = 10
DAY    = 28
HOUR   = 14

HallD-PXI:Data:I_Shunt    = 300.262898716        # Solenoid field current in Amps
HallD-PXI:Data:B_Field    = 0.316696936326       # Solenoid field in Tesla
IBCAD00CRCUR6             = 0.0                  # electron beam current in nA
hd:radiator:motor.RBV     = 135.944445532        # Tagger radiator motor position in mm
DAQ:availableRAID         = 48.0121022202        # Available diskspace on RAID in TB