From 72760c0c2b5b41b465faa0cb33800b5156a979ea Mon Sep 17 00:00:00 2001 From: Michal Nowak Date: Wed, 8 Nov 2023 19:21:30 +0100 Subject: [PATCH] Add support for recording named runtime with rr The traces of the named process are stored in the directory $system_test/nsX/named-Y/. (cherry picked from commit e088e8a992008ba5e0dc1c540f808a03e69cd619) --- bin/tests/system/README | 8 ++++++++ bin/tests/system/start.pl | 3 +++ 2 files changed, 11 insertions(+) diff --git a/bin/tests/system/README b/bin/tests/system/README index 58e6048ae0..cb9f71b237 100644 --- a/bin/tests/system/README +++ b/bin/tests/system/README @@ -710,6 +710,14 @@ or SEQUENTIAL variables. need to edit multiple files to add a test.) +rr +--- + +When running system tests, named can be run under the rr tool. rr records a +trace to the $system_test/nsX/named-Y/ directory, which can be later used to +replay named. To enable this, execute start.pl with the USE_RR environment +variable set. + Developer Notes for pytest runner === diff --git a/bin/tests/system/start.pl b/bin/tests/system/start.pl index c0163a2a23..904aa9b1e0 100755 --- a/bin/tests/system/start.pl +++ b/bin/tests/system/start.pl @@ -232,6 +232,9 @@ sub construct_ns_command { if ($taskset) { $command = "taskset $taskset $NAMED "; + } elsif ($ENV{'USE_RR'}) { + $ENV{'_RR_TRACE_DIR'} = "."; + $command = "rr record --chaos $NAMED "; } else { $command = "$NAMED "; }