From 7c9e95f1876ca0d209509358e6d4e58c910dd71e Mon Sep 17 00:00:00 2001 From: Atin Mukherjee Date: Wed, 12 Nov 2014 12:15:11 +0530 Subject: cli : Maintain separate cli log file per cli instance for cluster regression tests Change-Id: I7f49f4999d997b99c103fd67d13f972937e3aa92 BUG: 1162987 Signed-off-by: Atin Mukherjee Reviewed-on: http://review.gluster.org/9100 Reviewed-by: Kaushal M Tested-by: Gluster Build System Reviewed-by: Krishnan Parthasarathi Tested-by: Krishnan Parthasarathi --- tests/cluster.rc | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'tests/cluster.rc') diff --git a/tests/cluster.rc b/tests/cluster.rc index 5c821776156..b734f9d4501 100755 --- a/tests/cluster.rc +++ b/tests/cluster.rc @@ -121,8 +121,17 @@ function define_clis() { for i in `seq 1 $count`; do b="B$i"; - eval "CLI_$i='$CLI --glusterd-sock=${!b}/glusterd/gd.sock'"; - eval "CLI$i='$CLI --glusterd-sock=${!b}/glusterd/gd.sock'"; + #get the logdir + logdir=`gluster --print-logdir` + #Fetch the testcases name and prefix the cli log with it + logfile=`echo ${0##*/}`_cli$i.log + lopt="--log-file=$logdir/$logfile" + logfile1=`echo ${0##*/}`_cli_$i.log + lopt1="--log-file=$logdir/$logfile1" + + + eval "CLI_$i='$CLI --glusterd-sock=${!b}/glusterd/gd.sock $lopt'"; + eval "CLI$i='$CLI --glusterd-sock=${!b}/glusterd/gd.sock $lopt1'"; done } -- cgit