From: Jérémie Galarneau Date: Thu, 8 Aug 2019 19:27:51 +0000 (-0400) Subject: Fix: remote kernel stream paths contain too much information X-Git-Tag: v2.12.0-rc1~515 X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=commitdiff_plain;h=a5ba6fdde6d199e37ac6354d296dfacb81428d0e Fix: remote kernel stream paths contain too much information The kernel stream paths, when built with a "net" consumer type, contain the hostname and session name. This is redundant and must not be transmitted to 2.11+ relay daemons. Otherwise, this results in an erronerous path hierarchy on the remote end. Stream paths transmitted to a trace chunk-aware peer are relative to a session's output trace chunk. Signed-off-by: Jérémie Galarneau --- diff --git a/src/bin/lttng-sessiond/kernel-consumer.c b/src/bin/lttng-sessiond/kernel-consumer.c index 236ce0eb6..2d0605e9b 100644 --- a/src/bin/lttng-sessiond/kernel-consumer.c +++ b/src/bin/lttng-sessiond/kernel-consumer.c @@ -42,7 +42,10 @@ static char *create_channel_path(struct consumer_output *consumer) assert(consumer); /* Get the right path name destination */ - if (consumer->type == CONSUMER_DST_LOCAL) { + if (consumer->type == CONSUMER_DST_LOCAL || + (consumer->type == CONSUMER_DST_NET && + consumer->relay_major_version == 2 && + consumer->relay_minor_version >= 11)) { pathname = strdup(consumer->domain_subdir); if (!pathname) { PERROR("Failed to copy domain subdirectory string %s",