Project

General

Profile

Tagging and using the Operations Test Release

Purpose

The Operations Test Release is used to provide elements of DAQOperationsTools that need to be called outside the full NOvA DAQ environment. This includes setup scripts and application start/stop scripts.

Tags

Convention

Tags should follow the convention <Det>Ops_<Date><var> with

  • <Det> = FD, ND, NDOS, etc., or per expert preference in consultation with the DAQ group and the Run Coordinator
  • <Date> = yyyymmdd
  • <var> = variant id, i.e., a, b, c etc.

The will be used in a test release named testRel_<tagname>

Tagging

Use script NovaDAQUtilities/script/make_ops_tag.sh in a working area that has the desired version of DAQOperationsTools.

Under DAQOperationsTools directory, do:
../NovaDAQUtilities/script/make_ops_tag.sh -d NearDet -t NDOps_20171025a
../NovaDAQUtilities/script/make_ops_tag.sh -d FarDet -t FDOps_20171025a

This will tag
  • all of DAQOperationsTools/script,
  • the setup scripts appropriate for the detector you select,
  • and the enough GNUmakefiles to keep the build system happy.

Deployment

Installation

Create a test release testRelName=testRel_<tagname> and populate it with the correct version of DAQOperationsTools

  • cd /home/novadaq
  • <set up current P0 base release> (really doesn't matter which base release is used, but make sure to not use --opt or --xcompile, since the start/stop scripts are run in the unopt/x86 environment)
  • newrel -t <baserel> <testRelName>
    • This creates a new test release <testRelName> based on <baserel> -- Mostly this just gets you the default makefile rules.
  • cd <testRelName>
  • srt_setup -a
    • Tells SRT that this is the directory for my test release.
  • addpkg DAQOperationsTools <tagname>
    • Checks out DAQOperationsTools version tagged with <tagname> ?Maybe use -d :/cvs/nova/ so files can be checked in without specifying it?
  • make DAQOperationsTools.all
    • This copies the files in the script directory to the bin directory. It should be possible to tell if files are up to date with something like make -q DAQOperationsTools.all ; notuptodate=$?

Links

In order for this release to be used, change the operations links in /home/novadaq/DAQOperationsTools. Use detname=FarDet, NDOS, NearDet, etc. as appropriate.

The best way to prepare for this by setting the new directory and backup of the current one:

  • cd /home/novadaq
  • cp -pr DAQOperationsTools DAQOperationsTools_<old_tag> where <old_tag> is the tag name for the current Ops release. This is now your backup.
  • cp -pr DAQOperationsTools DAQOperationsTools_<new_tag> where <new_tag> is the new tag...
  • cd DAQOperationsTools_<new_tag>
  • use moveSetupLinks.sh to change the links to point to the new test release <testRelName>@
    • e.g.
      ./moveSetupLinks.sh /home/novadaq/testRel_NDOps_20171025a NearDet
      

      At this point, if you check ~/DAQOperationsTools, you should still see links to the <old_tag>, because you have not renamed DAQOperationsTools_<new_tag> to DAQOperationsTools.

When that is done, you can throw the switch:

  • Obtain approval from Run Coordinator
  • Double check that you have the backup of the current directory.
  • Stop any runs, shut down partitions
  • rm DAQOperationsTools; mv DAQOperationsTools_<new_tag> DAQOperationsTools - move the new directory into place
    This is when you roll out your new DAQOperationsTools.
  • Restart
If you need to roll back
  • Stop any runs, shut down partitions
  • mv DAQOperationsTools_<old_tag> DAQOperationsTools - move the backup directory into place
  • Restart

Development

Always communicate the planned changes to DAQ group, via DAQ meetings, slack, email, or all of the above, in case it could conflict with other activities

If you need to modify scripts in the DAQOperationsTools package the workflow should look like this:
  • Check that the scripts directory is up to date.
    cd /home/novadaq/DAQOperationsTools/
    ls -al
  • cd to the DAQOperationsTools test release e.g. cd /home/novadaq/testRel_NDOps_20190829a/DAQOperationsTools/
  • Check that package is up to date:
    cvs diff -r <opstag> --Where <opstag> is something like NDOps_20190829a from above example
  • If the above commands shows differences, there are untagged changes in the directory that will have to be fixed first ugh Let's assume there are no differences.
    cvs diff -r HEAD
  • If the above commands shows differences, there are changes in CVS that have not been picked up yet. Hopefully they were tested. Look at commit logs to find out who committed and find out if they were tested.

Prepare Test Release for modification

Create a test release testRelName=testRel_<tagname> and populate it with the correct version of DAQOperationsTools

  • cd /home/novadaq
  • <set up current P0 base release> (really doesn't matter which base release is used, but make sure to not use --opt or --xcompile, since the start/stop scripts are run in the unopt/x86 environment)
    setup_online -z 0 ?? Is this what is meant by above line?? LMM
  • newrel -t <baserel> <testRelName>
    • This creates a new test release <testRelName> based on <baserel> -- Mostly this just gets you the default makefile rules.
  • cd <testRelName>
  • srt_setup -a
    • Tells SRT that this is the directory for my test release.
  • addpkg -d novacvs@cdcvs.fnal.gov:/cvs/nova/ DAQOperationsTools <tagname> -- <tagname> can be HEAD or the old tag if you don't want to pull in new changes.
    • Checks out DAQOperationsTools version tagged with <tagname> ?Maybe use -d :/cvs/nova/ so files can be checked in without specifying it?
    • Seems like nova addpkg doesn't like -d option it gives too many arguments warning.

Modify and test scripts in the scripts directory

Commit Changes
  • cvs -d novacvs@cdcvs.fnal.gov:/cvs/nova/ commit -- or cvs add file first if a new file

Install modified files in bin directory
  • make DAQOperationsTools.all
    • This copies the files in the script directory to the bin directory. It should be possible to tell if files are up to date with something like make -q DAQOperationsTools.all ; notuptodate=$?
    • It seems like make -q doesn't really tell you if it needs updating or not. Bummer.

Deployment

  • Follow instructions in the Links section above.

Alternative: Trivial changes could be modified in the current DAQOperationsTools directory, committed, and tag moved to point to the new file version.
  • Any plans for something like this should be clearly communicated before, and logged in the ECL, before, during, and after.