1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-26 10:04:02 +03:00

Tests - turn of time logging by default

We haven't seen problems related to time jumps for a long time.  Turn
this off by default.

To switch it back on set $CTDB_TEST_TIME_LOGGING to any non-null
value.

Signed-off-by: Martin Schwenke <martin@meltin.net>

(This used to be ctdb commit 2aa9bbf3a52dde0707eb06acd91e57c8da5c717f)
This commit is contained in:
Martin Schwenke 2012-03-29 14:54:22 +11:00
parent 7698a5105e
commit d4785e813a
2 changed files with 3 additions and 2 deletions

View File

@ -116,7 +116,8 @@ ctdb_test_exit ()
echo "*** TEST COMPLETED (RC=$status) AT $(date '+%F %T'), CLEANING UP..."
if [ -n "$CTDB_TEST_REAL_CLUSTER" -a $status -ne 0 ] ; then
if [ -n "$CTDB_TEST_REAL_CLUSTER" -a -n "$CTDB_TEST_TIME_LOGGING" -a \
$status -ne 0 ] ; then
ctdb_check_time_logs
fi

View File

@ -31,7 +31,7 @@ onnode all onnode all true
# We're seeing some weirdness with CTDB controls timing out. We're
# wondering if time is jumping forward, so this creates a time log on
# each node that we can examine later if tests fail weirdly.
if [ -n "$CTDB_TEST_REAL_CLUSTER" ] ; then
if [ -n "$CTDB_TEST_REAL_CLUSTER" -a -n "$CTDB_TEST_TIME_LOGGING" ] ; then
echo "Starting time logging on each node..."
f="/var/log/ctdb.test.time.log"
onnode -p all "[ -f $f ] || while : ; do date '+%s %N' ; sleep 1 ; done >$f 2>&1 </dev/null &" &