NAME | SYNOPSIS | DESCRIPTION | OPTIONS | EXAMPLES | ENVIRONMENT VARIABLES | FILES | EXIT STATUS | BUGS | RESOURCES | AUTHORS | COPYRIGHT | SEE ALSO | COLOPHON |
|
BABELTRACE-QUERY(1) Babeltrace manual BABELTRACE-QUERY(1)
babeltrace-query - Query object from a component class
babeltrace query [GENERAL OPTIONS] [--omit-home-plugin-path] [--omit-system-plugin-path] [--plugin-path=PATH[:PATH]...] [--params=PARAMS] TYPE.PLUGIN.COMPCLS OBJECT
The query command queries the object named OBJECT from the component class COMPCLS of the type TYPE found in the Babeltrace plugin PLUGIN and prints the results. See babeltrace-intro(7) to learn more about the Babeltrace project and its core concepts. The available values for TYPE are: source, src Source component class. filter, flt Filter component class. sink Sink component class. The exact object names and the parameters that a given component class expects are described in its documentation. babeltrace-help(1) can generally provide this information. You can use the --params=PARAMS option to pass parameters to the component class’s query function. See Parameters format for the exact format of PARAMS. The output of the query command looks like YAML, although it is not guaranteed that it is YAML-compliant. See EXAMPLES for usage examples. Parameters format The format of the PARAMS option’s argument is a comma-separated list of NAME=VALUE assignments: NAME=VALUE[,NAME=VALUE]... NAME Parameter name (C identifier plus the :, ., and - characters). VALUE One of: · null, nul, NULL: null value. · true, TRUE, yes, YES: true boolean value. · false, FALSE, no, NO: false boolean value. · Binary (0b prefix), octal (0 prefix), decimal, or hexadecimal (0x prefix) signed 64-bit integer. · Double precision floating point number (scientific notation is accepted). · Unquoted string with no special characters, and not matching any of the null and boolean value symbols above. · Double-quoted string (accepts escape characters). You may put whitespaces around the individual = (assignment) and , (separator) characters. Example: babeltrace ... --params='many=null, fresh=yes, condition=false, squirrel=-782329, observe=3.14, simple=beef, needs-quotes="some string", escape.chars-are:allowed="a \" quote"' Important Like in the example above, make sure to single-quote the whole argument when you run this command from a shell. Plugin path This command loads Babeltrace plugins to perform its operation. The search path for Babeltrace plugins is, in this order: 1. The colon-separated list of directories in the BABELTRACE_PLUGIN_PATH environment variable. 2. The colon-separated list of directories in the --plugin-path option. 3. If the --omit-home-plugin-path option is absent: $HOME/.local/lib/babeltrace/plugins 4. If the --omit-system-plugin-path option is absent: /usr/local/lib/babeltrace/plugins You can use the babeltrace-list-plugins(1) command to dynamically list the available plugins.
General options See babeltrace(1) for more details. -d, --debug Turn the debugging mode on. --log-level=LVL Set the log level of all known Babeltrace loggers to LVL. -v, --verbose Turn the verbose mode on. -h, --help Show general help and quit. -V, --version Show version and quit. Query parameters -p PARAMS, --params=PARAMS Set the query parameters to PARAMS. See Parameters format for the exact format of PARAMS. Plugin path --omit-home-plugin-path Do not search for plugins in $HOME/.local/lib/babeltrace/plugins. --omit-system-plugin-path Do not search for plugins in /usr/local/lib/babeltrace/plugins. --plugin-path=PATH[:PATH]... Add PATH to the list of paths in which dynamic plugins can be found. Command information -h, --help Show the command’s help and quit.
Example 1. Query the available sessions of the LTTng live source component class. $ babeltrace query src.ctf.lttng-live sessions \ --params='url="net://RHOST/host/TGTHOST"' Example 2. Query the metadata info (includes the decoded text) of a CTF trace located on the local file system. $ babeltrace query src.ctf.fs metadata-info \ --params='path="/path/to/trace"' Example 3. Query the trace info of CTF traces located on the local file system. $ babeltrace query src.ctf.fs trace-info \ --params='path="/path/to/trace"' Example 4. Query some object from a sink component class without parameters. $ babeltrace query sink.my-plugin.my-sink some-object
Babeltrace library BABELTRACE_COMMON_LOG_LEVEL Common functions’s log level. The available values are the same as for the --log-level option of babeltrace(1). BABELTRACE_COMPAT_LOG_LEVEL Compatibility functions’s log level. The available values are the same as for the --log-level option of babeltrace(1). BABELTRACE_TERM_COLOR Force the terminal color support. The available values are: AUTO Only emit terminal color codes when the standard output and error streams are connected to a color-capable terminal. NEVER Never emit terminal color codes. ALWAYS Always emit terminal color codes. BABELTRACE_DISABLE_PYTHON_PLUGINS Set to 1 to disable the loading of any Babeltrace Python plugin. BABELTRACE_LOGGING_GLOBAL_LEVEL Babeltrace library’s global log level. The available values are the same as for the --log-level option of babeltrace(1) BABELTRACE_NO_DLCLOSE Set to 1 to make the Babeltrace library leave any dynamically loaded modules (plugins and Python plugin provider) open at exit. This can be useful for debugging purposes. BABELTRACE_PLUGIN_PATH Colon-separated list of directories, in order, in which dynamic plugins can be found before other directories are considered. Python plugin provider BABELTRACE_PYTHON_PLUGIN_PROVIDER_LOG_LEVEL Python plugin provider’s log level. The available values are the same as for the --log-level option of babeltrace(1). CLI BABELTRACE_CLI_LOG_LEVEL babeltrace CLI’s log level. The available values are the same as for the --log-level option. BABELTRACE_CLI_WARN_COMMAND_NAME_DIRECTORY_CLASH Set to 0 to disable the warning message which babeltrace prints when you convert a trace with a relative path that’s also the name of a babeltrace command.
$HOME/.local/lib/babeltrace/plugins User plugin directory. /usr/local/lib/babeltrace/plugins System plugin directory.
0 on success, 1 otherwise.
If you encounter any issue or usability problem, please report it on the Babeltrace bug tracker (see <https://bugs.linuxfoundation.org/buglist.cgi?product=Diamon&component=Babeltrace>).
The Babeltrace project shares some communication channels with the LTTng project (see <http://lttng.org/>). · Babeltrace website (see <http://diamon.org/babeltrace>) · Git repository (see <http://git.linuxfoundation.org/?p=diamon/babeltrace.git>) · EfficiOS GitHub organization (see <http://github.com/efficios/>) · Continuous integration (see <https://ci.lttng.org/job/babeltrace_master_build/>) · Mailing list (see <http://lists.lttng.org>) for support and development: lttng-dev@lists.lttng.org · IRC channel (see <irc://irc.oftc.net/lttng>): #lttng on irc.oftc.net
The Babeltrace project is the result of efforts by many regular developers and occasional contributors. The current project maintainer is Jérémie Galarneau <mailto:jeremie.galarneau@efficios.com>.
This command is part of the Babeltrace project. Babeltrace is distributed under the MIT license (see <https://opensource.org/licenses/MIT>).
babeltrace(1), babeltrace-intro(7)
This page is part of the babeltrace (trace read and write libraries
and a trace converter) project. Information about the project can be
found at ⟨http://www.efficios.com/babeltrace⟩. If you have a bug
report for this manual page, send it to lttng-dev@lists.lttng.org.
This page was obtained from the project's upstream Git repository
⟨git://git.efficios.com/babeltrace.git⟩ on 2018-02-02. (At that
time, the date of the most recent commit that was found in the repos‐
itory was 2018-01-30.) If you discover any rendering problems in
this HTML version of the page, or you believe there is a better or
more up-to-date source for the page, or you have corrections or
improvements to the information in this COLOPHON (which is not part
of the original manual page), send a mail to man-pages@man7.org
Babeltrace 2.0.0-pre4 5 October 2017 BABELTRACE-QUERY(1)
Pages that refer to this page: babeltrace(1), babeltrace-intro(7)