summaryrefslogtreecommitdiffstats
path: root/ctdb/lib/util/debug.c
diff options
context:
space:
mode:
authorMartin Schwenke <martin@meltin.net>2010-08-06 11:10:56 +1000
committerMartin Schwenke <martin@meltin.net>2010-08-06 11:10:56 +1000
commit0f18859a6ca76495d0998beed668005884eb4d1e (patch)
tree1a58eb38a9f6a17562efd14dbec9cd8c01d89d49 /ctdb/lib/util/debug.c
parentb50ec6596353769ee2148a41a4ee6afc101cce5c (diff)
downloadsamba-0f18859a6ca76495d0998beed668005884eb4d1e.tar.gz
samba-0f18859a6ca76495d0998beed668005884eb4d1e.tar.xz
samba-0f18859a6ca76495d0998beed668005884eb4d1e.zip
Add some command-line options to ctdb_diagnostics.
In some contexts ctdb_diagnostics generates too many errors when it is run on heterogeneous and machine-configured clusters. In some clusters some nodes are expected to be differently configured and also machine-generated configured files can have comments containing timestamps. This adds some command-line options that can be used to reduce the number of errors reported: -n <nodes> Comma separated list of nodes to operate on -c Ignore comment lines (starting with '#') in file comparisons -w Ignore whitespace in file comparisons --no-ads Do not use commands that assume an Active Directory Server The -n option simply allows ctdb_diagnostics to operate on a subset of nodes, avoiding file comparisons with and data collection on nodes that are differently configured. For file comparisons, instead of showing each file on the current node and then comparing other nodes to that file, the file from the first (available or requested) nodes is shown and then other nodes are compared to that. That has resulted in changes in output - that is, ctdb diagnostics no longer prints messages referencing the current node. -c and -w are used to weaken comparisons between configuration files. --no-ads can be used to avoid running ADS-specific commands if a cluster uses LDAP (or other non-ADS) configuration. This also fixes a number of bugs in related code: * A call to onnode was losing the >> NODE ... << lines because they now go to stderr. This was changed in onnode long ago but ctdb_diagnostics was never updated to match. * ctdb_diagnostics was counting lines in /etc/ctdb/nodes to determine what nodes to operate on. For some time the nodes file has supported syntax that makes this invalid. "ctdb listnodes -Y" is now used to list available nodes. Signed-off-by: Martin Schwenke <martin@meltin.net> (This used to be ctdb commit 36c8244a0f68c7c9bbee40982f230e9d14d3c0ea)
Diffstat (limited to 'ctdb/lib/util/debug.c')
0 files changed, 0 insertions, 0 deletions