Project

General

Profile

Actions

Bug #628

closed

loglevel and loglevel-only filtering are indistinguishable from the console

Added by Daniel U. Thibault over 10 years ago. Updated about 10 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
09/06/2013
Due date:
% Done:

100%

Estimated time:

Description

Currently (lttng-tools-2.3.0-rc3-1-3e618c7), the lttng enable-event --loglevel and lttng enable-event --loglevel-only commands return the same confirmation message, and the lttng list session_name command displays both filtering schemes in exactly the same way. For example:

$ lttng create abcd
Session abcd created.
Traces will be written in /home/daniel/lttng-traces/abcd-20130906-104317
$ lttng enable-event -u -a --loglevel wArNiNg
All UST events are enabled in channel channel0 for loglevel wArNiNg
$ lttng start
Tracing started for session abcd
$ lttng list abcd
Tracing session abcd: [active]
    Trace path: /home/daniel/lttng-traces/abcd-20130906-104317

=== Domain: UST global ===

Buffer type: per UID

Channels:
-------------
- channel0: [enabled]

    Attributes:
      overwrite mode: 0
      subbufers size: 131072
      number of subbufers: 4
      switch timer interval: 0
      read timer interval: 0
      output: mmap()

    Events:
      * (loglevel: TRACE_WARNING (4)) (type: tracepoint) [enabled]

$ lttng destroy
Session abcd destroyed

$ lttng create abcde
Session abcde created.
Traces will be written in /home/daniel/lttng-traces/abcde-20130906-104720
$ lttng enable-event -u -a --loglevel-only NotiCE
All UST events are enabled in channel channel0 for loglevel NotiCE
$ lttng start
Tracing started for session abcde
$ lttng list abcde
Tracing session abcde: [active]
    Trace path: /home/daniel/lttng-traces/abcde-20130906-104720

=== Domain: UST global ===

Buffer type: per UID

Channels:
-------------
- channel0: [enabled]

    Attributes:
      overwrite mode: 0
      subbufers size: 131072
      number of subbufers: 4
      switch timer interval: 0
      read timer interval: 0
      output: mmap()

    Events:
      * (loglevel: TRACE_NOTICE (5)) (type: tracepoint) [enabled]

$ lttng destroy
Session abcde destroyed

The user should be able to tell the two cases apart. This can be achieved by changing the lttng enable-event --loglevel feedback slightly to something like:

$ lttng enable-event -u -a --loglevel wArNiNg
All UST events are enabled in channel channel0 for loglevels up to wArNiNg

(It would also be nice if the message used the actual recognised loglevel constant name instead of the user's input: [...] for loglevels up to TRACE_WARNING (4))

Second, lttng list should make the distinction clear:

$ lttng list abcd
Tracing session abcd: [active]
[...]
    Events:
      * (loglevel <= TRACE_WARNING (4)) (type: tracepoint) [enabled]

$ lttng list abcde
Tracing session abcde: [active]
[...]
    Events:
      * (loglevel == TRACE_NOTICE (5)) (type: tracepoint) [enabled]


Related issues 1 (0 open1 closed)

Related to LTTng-UST - Feature #711: Add loglevel type to data structure lttng_ust_tracepoint_iterInvalid01/09/2014

Actions
Actions

Also available in: Atom PDF