diff --git a/MAC/Services/TBB/TBBServer/lib/tbbservice_config.py b/MAC/Services/TBB/TBBServer/lib/tbbservice_config.py index dcf363c4025f843150a5882f466a3ba288f69658..30e5ff782568eb9421c485f10a6a1f39286f8329 100644 --- a/MAC/Services/TBB/TBBServer/lib/tbbservice_config.py +++ b/MAC/Services/TBB/TBBServer/lib/tbbservice_config.py @@ -3,4 +3,4 @@ DEFAULT_CONSTANT_TIME_BETWEEN_SUBBAND_DUMPS = 0 # constant time in seco DEFAULT_DURATION_FACTOR_BETWEEN_SUBBAND_DUMPS = 0.00012 # linear scaling factor to increase time between dumps with duration DATAWRITER_DOCKER_IMAGE_NAME = 'lofar-outputproc' -DATAWRITER_DOCKER_IMAGE_TAG = 'SW-488-Epic_TBB_ALERT' +DATAWRITER_DOCKER_IMAGE_TAG = 'latest' diff --git a/MAC/TBB/lib/tbb_restart_recording.py b/MAC/TBB/lib/tbb_restart_recording.py index b794b7ef094e621a5e561e0e746edb2e7ce2ddcf..1e56e958c732fb9285d8cc62ca7dfeefbf8dff2d 100755 --- a/MAC/TBB/lib/tbb_restart_recording.py +++ b/MAC/TBB/lib/tbb_restart_recording.py @@ -16,11 +16,11 @@ from lofar.common.lcu_utils import translate_user_station_string_into_station_li def restart_tbb_recording(stations): - logging.info("Restarting TBB recording") - stations = translate_user_station_string_into_station_list(stations) station_hostname_csv_string = ','.join(stationname2hostname(s) for s in stations) + logging.info("Restarting TBB recording on stations %s", stations) + relay = lcurun_command + [station_hostname_csv_string] cmd = relay + [tbb_command, "--record"] logging.info("Executing %s" % " ".join(cmd)) @@ -35,3 +35,7 @@ def parse_args(): def main(): args = parse_args() restart_tbb_recording(args.stations) + +if __name__ == '__main__': + logging.basicConfig(format='%(asctime)s %(levelname)s %(message)s', level=logging.INFO) + main() \ No newline at end of file diff --git a/RTCP/Cobalt/OutputProc/src/TBB_Dipole.cc b/RTCP/Cobalt/OutputProc/src/TBB_Dipole.cc index cfe774789c2fad7700eedea4a88b7f752553b762..7ad78e692b6e446ad9ebe2971987b8ef6c3ad5c1 100644 --- a/RTCP/Cobalt/OutputProc/src/TBB_Dipole.cc +++ b/RTCP/Cobalt/OutputProc/src/TBB_Dipole.cc @@ -58,7 +58,7 @@ namespace LOFAR static void pwrite(int fd, const void *ptr, size_t size, off64_t offset) { - LOG_INFO_STR("TBB pwrite fd=" << fd << \ + LOG_DEBUG_STR("TBB pwrite fd=" << fd << \ " ptr=" << ptr << \ " size=" << size << \ " offset=" << offset); @@ -657,7 +657,7 @@ namespace LOFAR + " crc32: " + boost::lexical_cast<string>(crc32)); } - LOG_INFO_STR("TBB: offset in samples calculated for the HDF5 data set " + LOG_DEBUG_STR("TBB: offset in samples calculated for the HDF5 data set " "= " << offset << " for sub-band #" diff --git a/RTCP/Cobalt/OutputProc/src/TBB_Frame.cc b/RTCP/Cobalt/OutputProc/src/TBB_Frame.cc index 49b1190b898dfb1625dc48dcdc6cf56b47a1f2fa..3bf17156fadfe19eca5fde3d7c09415e9c92f120 100644 --- a/RTCP/Cobalt/OutputProc/src/TBB_Frame.cc +++ b/RTCP/Cobalt/OutputProc/src/TBB_Frame.cc @@ -56,7 +56,7 @@ namespace LOFAR { //TODO: implement like https://github.com/liamconnor/tbb-tools/blob/master/read_tbb_data.py#L157 //for now, just return 0 to test the signal path - LOG_INFO("TBB_Header::getFirstBandSelNr returning band=0 for testing"); + LOG_DEBUG("TBB_Header::getFirstBandSelNr returning band=0 for testing"); return 0; // 64 bit scans would be ~8x faster, but require fixes for band order (and endian) diff --git a/RTCP/Cobalt/OutputProc/src/TBB_Station.cc b/RTCP/Cobalt/OutputProc/src/TBB_Station.cc index 64f89e52dd78fbbf205f1d8c9276d534fe64fcce..fb5b2398a96c0a161369c5a9073edd0229d598b1 100644 --- a/RTCP/Cobalt/OutputProc/src/TBB_Station.cc +++ b/RTCP/Cobalt/OutputProc/src/TBB_Station.cc @@ -83,7 +83,7 @@ namespace LOFAR void TBB_Station::processPayload(const TBB_Frame& frame) { - LOG_INFO_STR("TBB_Station::processPayload for station " + LOG_DEBUG_STR("TBB_Station::processPayload for station " << static_cast< uint32_t >(frame.header.stationID)); // Guard against bogus incoming rsp/rcu IDs with at(). @@ -91,7 +91,7 @@ namespace LOFAR // Each dipole stream is sent to a single port (thread), so no need to grab a mutex here to avoid double init. if (!dipole.isInitialized()) { - LOG_INFO_STR("TBB_Station::processPayload for station " + LOG_DEBUG_STR("TBB_Station::processPayload for station " << static_cast< uint32_t >(frame.header.stationID) << " dipole init"); // Do pass a ref to the h5 mutex for when writing into the HDF5 file. @@ -103,7 +103,7 @@ namespace LOFAR if (doTransient()) { dipole.processTransientFrameData(frame); } else { // spectral mode - LOG_INFO_STR("TBB_Station::processPayload in spectral mode for station " + LOG_DEBUG_STR("TBB_Station::processPayload in spectral mode for station " << static_cast< uint32_t >(frame.header.stationID)); dipole.processSpectralFrameData(frame); diff --git a/RTCP/Cobalt/OutputProc/src/TBB_StreamWriter.cc b/RTCP/Cobalt/OutputProc/src/TBB_StreamWriter.cc index d8660c2f05cf75ebae940a7956608306d8375609..d5465a73f55508ca641130a92d33dd4670edcbfe 100644 --- a/RTCP/Cobalt/OutputProc/src/TBB_StreamWriter.cc +++ b/RTCP/Cobalt/OutputProc/src/TBB_StreamWriter.cc @@ -246,7 +246,7 @@ namespace LOFAR LOG_WARN(itsLogPrefix + exc.text()); return; } - LOG_INFO(itsLogPrefix + "reading incoming data from " + itsInputStreamName); + LOG_DEBUG(itsLogPrefix + "reading incoming data from " + itsInputStreamName); const unsigned expectedFrameSize = doTransient() ? TBB_Frame::transientFrameSize : TBB_Frame::spectralFrameSize; while (true) { @@ -313,7 +313,7 @@ namespace LOFAR break; } - LOG_INFO_STR("mainOutputLoop: we have a frame: " << frame->header.to_string()); + LOG_DEBUG_STR("mainOutputLoop: we have a frame: " << frame->header.to_string()); #ifdef TBB_PRINT_QUEUE_LEN LOG_INFO(itsLogPrefix + "recvqsz=" + boost::lexical_cast<string>(itsReceiveQueue.size())); diff --git a/RTCP/Cobalt/OutputProc/src/TBB_Writer.cc b/RTCP/Cobalt/OutputProc/src/TBB_Writer.cc index 625330701d722d814cc86d4a0771d1507966ca1e..8b80c112fc8d329b9e6d18a55c3640e04dc39171 100644 --- a/RTCP/Cobalt/OutputProc/src/TBB_Writer.cc +++ b/RTCP/Cobalt/OutputProc/src/TBB_Writer.cc @@ -110,7 +110,7 @@ namespace LOFAR ScopedLock sl(itsStationsMutex); // protect against insert below map<unsigned, SmartPtr<TBB_Station> >::iterator stIt(itsStations.find(header.stationID)); if (stIt != itsStations.end()) { - LOG_INFO_STR("TBB_Writer::getStation: found known station for id " + LOG_DEBUG_STR("TBB_Writer::getStation: found known station for id " << static_cast< uint32_t >(header.stationID)); return stIt->second.get(); // common case @@ -130,7 +130,7 @@ namespace LOFAR itsAllSubbandCentralFreqs, stMetaData, h5Filename, subbandSize); } - LOG_INFO_STR("TBB_Writer::getStation: returning new station for id " + LOG_DEBUG_STR("TBB_Writer::getStation: returning new station for id " << static_cast< uint32_t >(header.stationID)); return itsStations.insert(make_pair(header.stationID, station)).first->second.get(); }