summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-rebalance.c
diff options
context:
space:
mode:
authorN Balachandran <nbalacha@redhat.com>2019-07-25 11:51:32 +0530
committerAmar Tumballi <amarts@redhat.com>2019-08-14 03:21:30 +0000
commit6ef9ffea7fee43ea6f59c8c36fd183f90e9c26f8 (patch)
treec73a7e68188ecf463fc58e5843e2a860909a8675 /xlators/mgmt/glusterd/src/glusterd-rebalance.c
parent089e53c7f1c32644ce2b37830b678b4c0c7071fc (diff)
glusterd: create separate logdirs for cluster.rc instances
Create a separate logdir for each host instance created by cluster.rc. This makes it easier to determine the files belonging to a particular instance. Change-Id: Ic8321f83f98995412b7d5f095b3d3f0391767a8b Fixes: bz#1733042 Signed-off-by: N Balachandran <nbalacha@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-rebalance.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-rebalance.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-rebalance.c b/xlators/mgmt/glusterd/src/glusterd-rebalance.c
index d440a71..4ce20a9 100644
--- a/xlators/mgmt/glusterd/src/glusterd-rebalance.c
+++ b/xlators/mgmt/glusterd/src/glusterd-rebalance.c
@@ -266,13 +266,13 @@ glusterd_handle_defrag_start(glusterd_volinfo_t *volinfo, char *op_errstr,
GLUSTERD_GET_DEFRAG_SOCK_FILE(sockfile, volinfo);
GLUSTERD_GET_DEFRAG_PID_FILE(pidfile, volinfo, priv);
- snprintf(logfile, PATH_MAX, "%s/%s-%s.log", DEFAULT_LOG_FILE_DIRECTORY,
- volinfo->volname, "rebalance");
+ snprintf(logfile, PATH_MAX, "%s/%s-%s.log", priv->logdir, volinfo->volname,
+ "rebalance");
runinit(&runner);
if (this->ctx->cmd_args.valgrind) {
snprintf(valgrind_logfile, PATH_MAX, "%s/valgrind-%s-rebalance.log",
- DEFAULT_LOG_FILE_DIRECTORY, volinfo->volname);
+ priv->logdir, volinfo->volname);
runner_add_args(&runner, "valgrind", "--leak-check=full",
"--trace-children=yes", "--track-origins=yes", NULL);