CLUBAK(1)

NAME
clubak - format output from clush/pdsh-like output and more

SYNOPSIS

clubak [ OPTIONS ]

DESCRIPTION

clubak formats text from standard input containing lines of the form "node:output". It is fully backward compatible with dshbak(1) but provides additional features. For instance, clubak always displays its results sorted by node/nodeset.

You do not need to use clubak when using clush(1) as all output formatting features are already included in it. It is provided for other usages, like post-processing results of the form "node:output".

Like clush(1), clubak uses the ClusterShell.MsgTree module of the ClusterShell library (see pydoc ClusterShell.MsgTree).

INVOCATION

clubak should be started with connected standard input.

OPTIONS

--version
    show clubak version number and exit

-b, -c, --dshbak
    gather nodes with same output (-c and --dshbak are provided for dshbak(1) compatibility)

-B  same as -b; accepted for compatibility with clush(1), where -B also gathers standard error

-q, --quiet
    be quiet, print essential output only (e.g. suppress the node count displayed next to gathered nodeset headers)

-v, --verbose
    be verbose, print informative messages; also echo each input line to standard output prefixed by INPUT

-d, --debug
    output more messages for debugging purpose

-L  disable header block and order output by nodes

-N  disable labeling of command output

-r, --regroup
    fold nodeset using node groups

--axis=RANGESET
    for nD nodesets, fold the displayed nodeset (e.g. in gathered output headers) along provided axis only. Axes are indexed from 1 to n and can be specified here either using the rangeset syntax, e.g. '1', '1-2', '1,3', or by a single negative number meaning that the index is counted from the end. Because some nodesets may have several different dimensions, axis indices are silently truncated to fall in the allowed range. This is the per-invocation equivalent of the fold_axis library default.

-s GROUPSOURCE, --groupsource=GROUPSOURCE
    optional groups.conf(5) group source to use

--groupsconf=FILE
    use alternate config file for groups.conf(5)

-G, --groupbase
    do not display group source prefix (always @groupname)

-S SEPARATOR, --separator=SEPARATOR
    node / line content separator string (default: :)

-F, --fast
    faster but memory hungry mode (preload all messages per node)

-T, --tree
    message tree trace mode; switch to enable ClusterShell.MsgTree trace mode, all keys/nodes being kept for each message element of the tree, thus allowing special output display

--interpret-keys=INTERPRET_KEYS
    whether to interpret keys (the field before the separator on each input line) as node sets. INTERPRET_KEYS is never, always or auto (the default). With never, each key is kept as a plain string; with always, every key must be a valid node set; with auto, keys are interpreted as node sets, but if any key cannot be parsed, clubak silently switches to treating all keys as plain strings.

--color=WHENCOLOR
    clubak can use NO_COLOR, CLICOLOR and CLICOLOR_FORCE environment variables. --color command line option always takes precedence over environment variables. NO_COLOR takes precedence over CLICOLOR_FORCE which takes precedence over CLICOLOR. --color tells whether to use ANSI colors to surround node or nodeset prefix/header with escape sequences to display them in color on the terminal. WHENCOLOR is never, always or auto (which uses color if standard output refers to a terminal). Color is set to [34m (blue foreground text) and cannot be modified.

--diff
    show diff between gathered outputs

EXIT STATUS

An exit status of zero indicates success of the clubak command.

EXAMPLES

1.  clubak can be used to gather some recorded clush(1) results:

Record clush(1) results in a file:
    # clush -w node[1-7] uname -r >/tmp/clush_output
    # clush -w node[32-159] uname -r >>/tmp/clush_output

Display file gathered results (in line-mode):
    # clubak -bL </tmp/clush_output

2.  Another example, iterate over node* text files in current directory and gather characters count for all of them:
    # find -name "node*" -exec wc -c {} ; | awk '{ gsub("./","",$2); print $2": "$1 }' | clubak -bL
    node[1,3]: 7
    node2: 9

SEE ALSO

cluset(1), clush(1), nodeset(1), groups.conf(5).

https://clustershell.readthedocs.io/

BUG REPORTS

Use the following URL to submit a bug report or feedback:
    https://github.com/clustershell/clustershell/issues

AUTHOR
Stephane Thiell

COPYRIGHT
GNU Lesser General Public License version 2.1 or later (LGPLv2.1+)