DUNE-DAQ / drunc

Dune RUN Control (DRUNC) is the run control for the DUNE experiment
1 stars 1 forks source link

drunc boot does not seem to use a different specified session #203

Closed bieryAtFnal closed 2 months ago

bieryAtFnal commented 3 months ago

I have created a second session in my local OKS database, but when I try to use it from the drunc "boot" command, it does not seem to get used. This second session is named "swtest-session", and the only difference between it and the usual "test-session" is in the value for the operational environment config param (op_env). For the test-session, I have changed the op_env to "test2", and for the swtest-session, I have specified an op_env value of "swtest". One easy way to check which op_env value is being used is to check the prefix for HDF5 files that are created.

Here are steps to demonstrate this behavior:

DATE_PREFIX=`date '+%d%b'`
TIME_SUFFIX=`date '+%H%M'`

source /cvmfs/dunedaq.opensciencegrid.org/setup_dunedaq.sh
setup_dbt latest_v5
dbt-create -n NFDT_DEV_240815_A9 ${DATE_PREFIX}FDv5Test_${TIME_SUFFIX}
cd ${DATE_PREFIX}FDv5Test_${TIME_SUFFIX}/sourcecode

git clone https://github.com/DUNE-DAQ/appmodel.git -b kbiery/second_session_example
git clone https://github.com/DUNE-DAQ/trgdataformats.git -b develop
git clone https://github.com/DUNE-DAQ/trigger.git -b develop
cd ..

dbt-workarea-env
dbt-build -j 12
dbt-workarea-env

mkdir rundir
cd rundir

# Execute the following commands by hand:

drunc-unified-shell ssh-standalone

# within drunc (NB the use of the "swtest-session")

boot test/config/test-session.data.xml swtest-session
fsm conf
fsm start run_number 101
fsm enable_triggers
# wait for a few seconds
fsm disable_triggers
fsm drain_dataflow
fsm stop_trigger_sources
fsm stop
fsm scrap
quit

ls -alF *.hdf5

# note that the HDF5 file prefix is "test2", not "swtest"
plasorak commented 2 months ago

Unfortunately, as things stand now, this is because some environment variables are used to key the configuration: so https://github.com/DUNE-DAQ/appmodel/blob/kbiery/second_session_example/test/config/test-session.data.xml#L431 and https://github.com/DUNE-DAQ/appmodel/blob/kbiery/second_session_example/test/config/test-session.data.xml#L436 would need to be replicated too and hold swtest-session. That's the quick fix for this particular problem. The underlying problem should be fixed differently: https://github.com/DUNE-DAQ/confmodel/issues/44