Bug #21969
run_demo.sh partitioning issue again
Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
02/22/2019
Due date:
% Done:
0%
Estimated time:
Experiment:
-
Co-Assignees:
Description
John and I have discovered an issue with the now two different PARTITION_NUMBER env vars. (ARTDAQ_PARTITION_NUMBER and DAQINTRFACE_PARTITION_NUMBER.
This could be considered an extension of issue 20889, but since the associated branch has been merged into develop, it may
be better to create a new issue.
History
#1 Updated by Ron Rechenmacher almost 2 years ago
At this point changes to both artdaq_demo's run_demo.sh and daqinterface's daqinterface_functions.sh need to happen.
Also, at this point, the changes to run_demo.sh could/should happen first.
#2 Updated by John Freeman almost 2 years ago
To add to what Ron said: we discovered that in run_demo.sh, there's the following snippet in the get_dispatcher_port() function:
export DAQINTERFACE_PARTITION_NUMBER=$ARTDAQ_PARTITION_NUMBER
where ARTDAQ_PARTITION_NUMBER is set via the "--partition" option to run_demo, but if this option isn't passed, the script will run - but in the line above, the DAQINTERFACE_PARTITION_NUMBER ends up not being an integer anymore. Things can still work given Ron's fix to the internal DAQInterface utility script, artdaq-utilities-daqinterface/bin/daqinterface_functions.sh, in which if DAQINTERFACE_PARTITION_NUMBER has wound up set to "nothing" it defaults to zero:
export DAQINTERFACE_PORT=$(( $ARTDAQ_BASE_PORT + ${DAQINTERFACE_PARTITION_NUMBER:-0} * $ARTDAQ_PORTS_PER_PARTITION ))
...but it would be preferable to not execute "
export DAQINTERFACE_PARTITION_NUMBER=
" in run_demo.sh in the first place.