Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: hannes.weisbach@mailbox.tu-dresden.de (Hannes Weisbach)
Subject: [lttng-dev] [BUG] lttng-sessiond
Date: Sat, 25 Apr 2015 16:13:11 +0200	[thread overview]
Message-ID: <4DCF299D-B929-42DB-B514-5219DAF3105F@mailbox.tu-dresden.de> (raw)
In-Reply-To: <480136718.35882.1429900335415.JavaMail.zimbra@efficios.com>

>> However, loading multiple probes with
>> either --kmod-probes or --extra-kmod-probes still does not work:
>> $ sudo lttng-sessiond -vvv --extra-kmod-probes=sched,napi
>> [...]
>> DEBUG1 - 11:42:18.492870 [5358/5358]: Modprobe successfully lttng-probe-napi
>> (in modprobe_lttng() at modprobe.c:285)
>> sh: 1: Syntax error: "(" unexpected
>> DEBUG1 - 11:42:18.495037 [5358/5358]: Unable to load optional module (null);
>> continuing (in modprobe_lttng() at modprobe.c:281)
>> [...]
> 
> Why do you need to load those explicitly ? They should be
> already loaded by default. I don't get those errors here.
I don't need them.  They're just examples.  Albeit they are loaded by
default, using --kmod-probes or --extra-kmod-probes should work, no?

> Which shell are you using (sh symlink) ? Can you reproduce
> using bash ?
I added a bit of debug output, namely the string that gets passed to
system(): DBG("system(%s)", modprobe);

Result:
$ sudo lttng-sessiond -vvv --kmod-probes="sched,napi"
[?]
DEBUG1 - 16:02:21.372257 [4227/4227]: system(/sbin/modprobe -q lttng-probe-napi) (in modprobe_lttng() at modprobe.c:263)
DEBUG1 - 16:02:21.381980 [4227/4227]: Modprobe successfully lttng-probe-napi (in modprobe_lttng() at modprobe.c:286)
DEBUG1 - 16:02:21.382306 [4227/4227]: system(/sbin/modprobe -q (null)) (in modprobe_lttng() at modprobe.c:263)
sh: 1: Syntax error: "(" unexpected
DEBUG1 - 16:02:21.384942 [4227/4227]: Unable to load optional module (null); continuing (in modprobe_lttng() at modprobe.c:282)

The problem is not with sh.  It is that a NULL pointer is passed to
snprintf in modprobe.c:254.  My guess is, that splitting the argument
of --kmod-probes and --extra-kmod-probes (probably using strtok) is
somehow broken.  If you can tell where in the source of lttng-sessiond
argument parsing happens I can step through the code to see what
is going on.

Best regards,
Hannes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 203 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.lttng.org/pipermail/lttng-dev/attachments/20150425/6d8a7685/attachment.sig>


  reply	other threads:[~2015-04-25 14:13 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-23 10:04 Hannes Weisbach
2015-04-23 19:26 ` Mathieu Desnoyers
2015-04-23 20:13   ` Mathieu Desnoyers
2015-04-24  9:52     ` Hannes Weisbach
2015-04-24 18:32       ` Mathieu Desnoyers
2015-04-25 14:13         ` Hannes Weisbach [this message]
2015-04-25 14:37         ` Hannes Weisbach
2015-04-25 15:37           ` Mathieu Desnoyers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4DCF299D-B929-42DB-B514-5219DAF3105F@mailbox.tu-dresden.de \
    --to=hannes.weisbach@mailbox.tu-dresden.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox