This document applies to Apache Kudu version 1.17.1. Please consult the documentation of the appropriate release that’s applicable to the version of the Kudu cluster. |
cluster
: Operate on a Kudu clusterksck
: Check the health of a Kudu cluster By default, ksck checks that master and tablet server processes are running, and that table metadata is consistent. Use the 'checksum' flag to check that tablet data is consistent (also see the 'tables' and 'tablets' flags). Use the 'checksum_snapshot' along with 'checksum' if the table or tablets are actively receiving inserts or updates. Use the 'ksck_format' flag to output detailed information on cluster status even if no inconsistency is found in metadata.
Usage:
kudu cluster ksck <master_addresses> [-checksum_cache_blocks] [-checksum_scan] [-checksum_scan_concurrency=<concurrency>] [-nochecksum_snapshot] [-checksum_timeout_sec=<sec>] [-color=<color>] [-noconsensus] [-fetch_info_concurrency=<concurrency>] [-flags_categories_to_check=<check>] [-ksck_format=<format>] [-noquiescing_info] [-sections=<sections>] [-tables=<tables>] [-tablets=<tablets>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
checksum_cache_blocks (optional) |
Should the checksum scanners cache the read blocks. |
bool |
|
checksum_scan (optional) |
Perform a checksum scan on data in the cluster. |
bool |
|
checksum_scan_concurrency (optional) |
Number of concurrent checksum scans to execute per tablet server. |
int32 |
|
checksum_snapshot (optional) |
Should the checksum scanner use a snapshot scan? |
bool |
|
checksum_timeout_sec (optional) |
Maximum total seconds to wait for a checksum scan to complete before timing out. |
int32 |
|
color (optional) |
Specifies whether output should be colorized. The default value 'auto' colorizes output if the output is a terminal. The other valid values are 'always' or 'never'. |
string |
|
consensus (optional) |
Whether to check the consensus state from each tablet against the master. |
bool |
|
fetch_info_concurrency (optional) |
Number of threads to fetch info concurrently. |
int32 |
|
flags_categories_to_check (optional) |
Comma-separated list of flag categories to check for divergence across the cluster; default is time_source; available categories are time_source, unusual. |
string |
|
ksck_format (optional) |
Output format for ksck. Available options are 'plain_concise', 'plain_full', 'json_pretty', and 'json_compact'. 'plain_concise' format is plain text, omitting most information about healthy tablets. 'plain_full' is plain text with all results included. 'json_pretty' produces pretty-printed json. 'json_compact' produces json suitable for parsing by other programs. 'json_pretty' and 'json_compact' differ in format, not content. |
string |
|
quiescing_info (optional) |
Whether to display the quiescing-related information of each tablet server, e.g. number of tablet leaders per server, the number of active scanners per server. |
bool |
|
sections (optional) |
Sections to print (comma-separated list of sections, available sections are: MASTER_SUMMARIES, TSERVER_SUMMARIES, VERSION_SUMMARIES, TABLET_SUMMARIES, TABLE_SUMMARIES, SYSTEM_TABLE_SUMMARIES, CHECKSUM_RESULTS and TOTAL_COUNT.) If not specified, print all sections. |
string |
|
tables (optional) |
Tables to include (comma-separated list of table names)If not specified, includes all tables. |
string |
none |
tablets (optional) |
Tablets to check (comma-separated list of IDs) If not specified, checks all tablets. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
rebalance
: Move tablet replicas between tablet servers to balance replica counts for each table and for the cluster as a whole. The rebalancing tool moves tablet replicas between tablet servers, in the same manner as the 'kudu tablet change_config move_replica' command, attempting to balance the count of replicas per table on each tablet server, and after that attempting to balance the total number of replicas per tablet server.
Usage:
kudu cluster rebalance <master_addresses> [-disable_cross_location_rebalancing] [-disable_intra_location_rebalancing] [-disable_policy_fixer] [-fetch_info_concurrency=<concurrency>] [-force_rebalance_replicas_on_maintenance_tservers] [-ignored_tservers=<tservers>] [-intra_location_rebalancing_concurrency=<concurrency>] [-load_imbalance_threshold=<threshold>] [-max_moves_per_server=<server>] [-max_run_time_sec=<sec>] [-max_staleness_interval_sec=<sec>] [-move_replicas_from_ignored_tservers] [-move_single_replicas=<replicas>] [-output_replica_distribution_details] [-enable_range_rebalancing] [-report_only] [-tables=<tables>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
disable_cross_location_rebalancing (optional) |
In case of multi-location cluster, whether to move tablet replicas between locations in attempt to spread tablet replicas among location evenly (equalizing loads of locations throughout the cluster). This setting is applicable to multi-location clusters only. |
bool |
|
disable_intra_location_rebalancing (optional) |
In case of multi-location cluster, whether to rebalance tablet replica distribution within each location. This setting is applicable to multi-location clusters only. |
bool |
|
disable_policy_fixer (optional) |
In case of multi-location cluster, whether to detect and fix placement policy violations. Fixing placement policy violations involves moving tablet replicas across different locations of the cluster. This setting is applicable to multi-location clusters only. |
bool |
|
fetch_info_concurrency (optional) |
Number of threads to fetch info concurrently. |
int32 |
|
force_rebalance_replicas_on_maintenance_tservers (optional) |
This flag only takes effect in the case that some tservers are set maintenance mode but not specified in 'ignored_tservers'. If set true, the tool would rebalance all known replicas among all known tservers. The side effect of this is new replicas may be moved to maintenance tservers which are likely to be restarted or decommissioned soon. It is generally more recommended to specify all maintenance tservers in 'ignored_tservers', so that the rebalancer tool would ignore these tservers' states and replicas on them when planning replica moves. |
bool |
|
ignored_tservers (optional) |
UUIDs of tablet servers to ignore while rebalancing the cluster (comma-separated list). If specified, the tablet servers are effectively ignored by the rebalancer tool, they are not considered as a part of the cluster as well as the replicas on them. If not specified, the rebalancer tool will run on all the tablet servers in the cluster. |
string |
none |
intra_location_rebalancing_concurrency (optional) |
How many independent intra-location rebalancing sessions can be run in parallel. Since the location assignment naturally provides non-intersecting sets of servers, it’s possible to independently move tablet replicas within different locations in parallel. Value of 0 means 'the number of CPU cores'. The actual number of concurrent sessions is the minimum of two values: this setting and the number of locations in a cluster. |
uint32 |
|
load_imbalance_threshold (optional) |
The threshold for the per-table location load imbalance. The threshold is used during the cross-location rebalancing phase. If the measured cross-location load imbalance for a table is greater than the specified threshold, the rebalancer tries to move table’s replicas to reduce the imbalance. The recommended range for the threshold is [0.5, …) with the default value of 1.0. The threshold represents a policy wrt what to prefer: either ideal balance of the cross-location load on per-table basis (lower threshold value) or minimum number of replica movements between locations (greater threshold value). The default value is empirically proven to be a good choice between 'ideal' and 'good enough' replica distributions. |
double |
|
max_moves_per_server (optional) |
Maximum number of replica moves to perform concurrently on one tablet server: 'move from' and 'move to' are counted as separate move operations. |
uint32 |
|
max_run_time_sec (optional) |
Maximum time to run the rebalancing, in seconds. Specifying 0 means not imposing any limit on the rebalancing run time. |
int64 |
|
max_staleness_interval_sec (optional) |
Maximum duration of the 'staleness' interval, when the rebalancer cannot make any progress in scheduling new moves and no prior scheduled moves are left, even if re-synchronizing against the cluster’s state again and again. Such a staleness usually happens in case of a persistent problem with the cluster or when some unexpected concurrent activity is present (such as automatic recovery of failed replicas, etc.) |
uint32 |
|
move_replicas_from_ignored_tservers (optional) |
Whether to move replicas from the specified 'ignored_tservers' to other servers when the source tablet server is healthy. This setting is effective only if the '--ignored_tservers' flag is specified as well. If set true, then all ignored tablet servers must be placed into the 'maintenance mode'. |
bool |
|
move_single_replicas (optional) |
Whether to move single replica tablets (i.e. replicas of tablets of replication factor 1). Acceptable values are: 'auto', 'enabled', 'disabled'. The value of 'auto' means turn it on/off depending on the replica management scheme and Kudu version. |
string |
|
output_replica_distribution_details (optional) |
Whether to output details on per-table and per-server replica distribution |
bool |
|
enable_range_rebalancing (optional) |
Whether to enable table range rebalancing |
bool |
|
report_only (optional) |
Whether to report on table- and cluster-wide replica distribution skew and exit without doing any actual rebalancing |
bool |
|
tables (optional) |
Tables to include (comma-separated list of table names)If not specified, includes all tables. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
diagnose
: Diagnostic tools for Kudu servers and clustersparse_stacks
: Parse sampled stack traces out of a diagnostics log Usage:
kudu diagnose parse_stacks <path>…
Arguments:
Name | Description | Type | Default |
---|---|---|---|
path… |
Path(s) to log file(s) to parse, separated by a whitespace, if many |
string |
none |
parse_metrics
: Parse metrics out of a diagnostics log Usage:
kudu diagnose parse_metrics <path>… [-tablet_ids=<ids>] [-simple_metrics=<metrics>] [-rate_metrics=<metrics>] [-histogram_metrics=<metrics>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
path… |
Path(s) to log file(s) to parse, separated by a whitespace, if many |
string |
none |
tablet_ids (optional) |
comma-separated list of tablet identifiers to aggregate tablet metrics across; defaults to aggregating all tablets |
string |
none |
simple_metrics (optional) |
comma-separated list of metrics to parse, of the format <entity>.<metric name>[:<display name>], where <entity> must be one of 'server', 'table', or 'tablet', and <metric name> refers to the metric name; <display name> is optional and stands for the column name/tag that the metric is output with |
string |
none |
rate_metrics (optional) |
comma-separated list of metrics to compute the rates of |
string |
none |
histogram_metrics (optional) |
comma-separated list of histogram metrics to parse percentiles for |
string |
none |
fs
: Operate on a local Kudu filesystemcheck
: Check a Kudu filesystem for inconsistencies Usage:
kudu fs check [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-repair]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
repair (optional) |
Repair any inconsistencies in the filesystem. |
bool |
|
format
: Format a new Kudu filesystem Usage:
kudu fs format [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-uuid=<uuid>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
uuid (optional) |
The uuid to use in the filesystem. If not provided, one is generated |
string |
none |
list
: List metadata for on-disk tablets, rowsets, blocks, and cfiles This tool is useful for discovering and gathering information about on-disk data. Many field types can be added to the results with the --columns flag, and results can be filtered to a specific table, tablet, rowset, column, or block through flags.
Note: adding any of the 'cfile' fields to --columns will cause the tool to read on-disk metadata for each CFile in the result set, which could require large amounts of I/O when many results are returned.
Usage:
kudu fs list [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-table_id=<id>] [-table_name=<name>] [-tablet_id=<id>] [-rowset_id=<id>] [-column_id=<id>] [-block_id=<id>] [-columns=<columns>] [-format=<format>] [-noh]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
table_id (optional) |
Restrict output to a specific table by id |
string |
none |
table_name (optional) |
Restrict output to a specific table by name |
string |
none |
tablet_id (optional) |
Restrict output to a specific tablet |
string |
none |
rowset_id (optional) |
Restrict output to a specific rowset |
int64 |
|
column_id (optional) |
Restrict output to a specific column |
int32 |
|
block_id (optional) |
Restrict output to a specific block |
uint64 |
|
columns (optional) |
Comma-separated list of fields to include in output. Possible values: table, table-id, tablet-id, partition, rowset-id, block-id, block-kind, column, column-id, cfile-data-type, cfile-nullable, cfile-encoding, cfile-compression, cfile-num-values, cfile-size, cfile-incompatible-features, cfile-compatible-features, cfile-min-key, cfile-max-key, cfile-delta-stats |
string |
|
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
h (optional) |
Pretty-print values in human-readable units |
bool |
|
update_dirs
: Updates the set of data directories in an existing Kudu filesystem If a data directory is in use by a tablet and is removed, the operation will fail unless --force is also used. Starting with Kudu 1.12.0, it is not required to run this tool to add or remove directories. This tool is preserved for backwards compatibility
Usage:
kudu fs update_dirs [-force] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
force (optional) |
If true, permits the removal of a data directory that is configured for use by existing tablets. Those tablets will fail the next time the server is started |
bool |
|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
dump
: Dump a Kudu filesystemblock
: Dump the binary contents of a data block This performs no parsing or interpretation of the data stored in the block but rather outputs its binary contents directly.
Usage:
kudu fs dump block <block_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
block_id |
block identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
cfile
: Dump the contents of a CFile (column file) This interprets the contents of a CFile-formatted block and outputs the decoded row data.
Usage:
kudu fs dump cfile <block_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-noprint_meta] [-noprint_rows]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
block_id |
block identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
print_meta (optional) |
Include metadata in output |
bool |
|
print_rows (optional) |
Print each row in the CFile |
bool |
|
tree
: Dump the tree of a Kudu filesystem Usage:
kudu fs dump tree [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
uuid
: Dump the UUID of a Kudu filesystem Usage:
kudu fs dump uuid [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
hms
: Operate on remote Hive Metastorescheck
: Check metadata consistency between Kudu and the Hive Metastore catalogs Usage:
kudu hms check <master_addresses> [-hive_metastore_sasl_enabled] [-hive_metastore_uris=<uris>] [-noignore_other_clusters] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
hive_metastore_sasl_enabled (optional) |
Configures whether Thrift connections to the Hive Metastore use SASL (Kerberos) security. Only takes effect when --hive_metastore_uris is set, otherwise the configuration from the Kudu master is used. The configured value must match the the hive.metastore.sasl.enabled option in the Hive Metastore configuration. |
bool |
|
hive_metastore_uris (optional) |
Address of the Hive Metastore instance(s). If not set, the configuration from the Kudu master is used, so this flag should not be overriden in typical situations. The provided port must be for the HMS Thrift service. If a port is not provided, defaults to 9083. If the HMS is deployed in an HA configuration, multiple comma-separated addresses should be supplied. The configured value must match the Hive hive.metastore.uris configuration. |
string |
none |
ignore_other_clusters (optional) |
Whether to ignore entirely separate Kudu clusters, as indicated by a different set of master addresses. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
downgrade
: Downgrade the metadata to legacy format for Kudu and the Hive Metastores Usage:
kudu hms downgrade <master_addresses> [-hive_metastore_sasl_enabled] [-hive_metastore_uris=<uris>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
hive_metastore_sasl_enabled (optional) |
Configures whether Thrift connections to the Hive Metastore use SASL (Kerberos) security. Only takes effect when --hive_metastore_uris is set, otherwise the configuration from the Kudu master is used. The configured value must match the the hive.metastore.sasl.enabled option in the Hive Metastore configuration. |
bool |
|
hive_metastore_uris (optional) |
Address of the Hive Metastore instance(s). If not set, the configuration from the Kudu master is used, so this flag should not be overriden in typical situations. The provided port must be for the HMS Thrift service. If a port is not provided, defaults to 9083. If the HMS is deployed in an HA configuration, multiple comma-separated addresses should be supplied. The configured value must match the Hive hive.metastore.uris configuration. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
fix
: Fix automatically-repairable metadata inconsistencies in the Kudu and Hive Metastore catalogs Usage:
kudu hms fix <master_addresses> [-dryrun] [-drop_orphan_hms_tables] [-nocreate_missing_hms_tables] [-nofix_inconsistent_tables] [-noupgrade_hms_tables] [-hive_metastore_sasl_enabled] [-hive_metastore_uris=<uris>] [-noignore_other_clusters] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
dryrun (optional) |
Print a message for each fix, but do not make modifications to Kudu or the Hive Metastore. |
bool |
|
drop_orphan_hms_tables (optional) |
Drop orphan Hive Metastore tables which refer to non-existent Kudu tables. |
bool |
|
create_missing_hms_tables (optional) |
Create a Hive Metastore table for each Kudu table which is missing one. |
bool |
|
fix_inconsistent_tables (optional) |
Fix tables whose Kudu and Hive Metastore metadata differ. If the table name is different, the table is renamed in Kudu to match the HMS. If the columns or other metadata is different the HMS is updated to match Kudu. |
bool |
|
upgrade_hms_tables (optional) |
Upgrade Hive Metastore tables from the legacy Impala metadata format to the new Kudu metadata format. |
bool |
|
hive_metastore_sasl_enabled (optional) |
Configures whether Thrift connections to the Hive Metastore use SASL (Kerberos) security. Only takes effect when --hive_metastore_uris is set, otherwise the configuration from the Kudu master is used. The configured value must match the the hive.metastore.sasl.enabled option in the Hive Metastore configuration. |
bool |
|
hive_metastore_uris (optional) |
Address of the Hive Metastore instance(s). If not set, the configuration from the Kudu master is used, so this flag should not be overriden in typical situations. The provided port must be for the HMS Thrift service. If a port is not provided, defaults to 9083. If the HMS is deployed in an HA configuration, multiple comma-separated addresses should be supplied. The configured value must match the Hive hive.metastore.uris configuration. |
string |
none |
ignore_other_clusters (optional) |
Whether to ignore entirely separate Kudu clusters, as indicated by a different set of master addresses. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
list
: List the Kudu table HMS entries Usage:
kudu hms list <master_addresses> [-columns=<columns>] [-format=<format>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
columns (optional) |
Comma-separated list of HMS entry fields to include in output. Possible values: database, table, type, owner, comment, kudu.table_name, kudu.table_id, kudu.cluster_id, kudu.master_addresses, storage_handler |
string |
|
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
precheck
: Check that the Kudu cluster is prepared to enable the Hive Metastore integration Usage:
kudu hms precheck <master_addresses> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
local_replica
: Operate on local tablet replicas via the local filesystemcopy_from_local
: Copy tablet replicas from local filesystem. Before using this tool, you MUST stop the master/tserver you want to copy from, and make sure --src_*dir(s) and --dst*_dir(s) are exactly what whey should be. Usage:
kudu local_replica copy_from_local <tablet_ids> [-src_fs_wal_dir=<dir>] [-src_fs_metadata_dir=<dir>] [-src_fs_data_dirs=<dirs>] [-dst_fs_wal_dir=<dir>] [-dst_fs_metadata_dir=<dir>] [-dst_fs_data_dirs=<dirs>] [-num_threads=<threads>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_ids |
Comma-separated list of Tablet Identifiers |
string |
none |
src_fs_wal_dir (optional) |
Source: Directory with write-ahead logs. |
string |
none |
src_fs_metadata_dir (optional) |
Source: Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of --dst_fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, --dst_fs_wal_dir will be used as the metadata directory. |
string |
none |
src_fs_data_dirs (optional) |
Source: Comma-separated list of directories with data blocks. If this is not specified, --src_fs_wal_dir will be used as the sole data block directory. |
string |
none |
dst_fs_wal_dir (optional) |
Destination: Directory with write-ahead logs. |
string |
none |
dst_fs_metadata_dir (optional) |
Destination: Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of --dst_fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, --dst_fs_wal_dir will be used as the metadata directory. |
string |
none |
dst_fs_data_dirs (optional) |
Destination: Comma-separated list of directories with data blocks. If this is not specified, --dst_fs_wal_dir will be used as the sole data block directory. |
string |
none |
num_threads (optional) |
Number of threads to run. |
int32 |
|
copy_from_remote
: Copy tablet replicas from a remote server Usage:
kudu local_replica copy_from_remote <tablet_ids> <source> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-tablet_copy_download_threads_nums_per_session=<session>] [-num_threads=<threads>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_ids |
Comma-separated list of Tablet Identifiers |
string |
none |
source |
Source RPC address of form hostname:port |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
tablet_copy_download_threads_nums_per_session (optional) |
Number of threads per tablet copy session for downloading tablet data blocks. |
int32 |
|
num_threads (optional) |
Number of threads to run. |
int32 |
|
data_size
: Summarize the data size/space usage of the given local replica(s). Usage:
kudu local_replica data_size <tablet_id_pattern> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-format=<format>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id_pattern |
Tablet identifier pattern. This argument supports basic glob syntax: '*' matches 0 or more wildcard characters. |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
delete
: Delete tablet replicas from the local filesystem. By default, leaves a tombstone record upon replica removal. Usage:
kudu local_replica delete <tablet_id_patterns> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-clean_unsafe] [-ignore_nonexistent] [-tables=<tables>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id_patterns |
Comma-separated list of Tablet identifier patterns. This argument supports basic glob syntax: '*' matches 0 or more wildcard characters. |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
clean_unsafe (optional) |
Delete the local replica completely, not leaving a tombstone. This is not guaranteed to be safe because it also removes the consensus metadata (including Raft voting record) for the specified tablet, which violates the Raft vote durability requirements. |
bool |
|
ignore_nonexistent (optional) |
Whether to ignore non-existent tablet replicas when deleting: if set to 'true', the tool does not report an error if the requested tablet replica to remove is not found |
bool |
|
tables (optional) |
Tables to include (comma-separated list of table names)If not specified, includes all tables. |
string |
none |
list
: Show list of tablet replicas in the local filesystem Usage:
kudu local_replica list [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-list_detail]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
list_detail (optional) |
Print partition info for the local replicas |
bool |
|
cmeta
: Operate on a local tablet replica’s consensus metadata fileprint_replica_uuids
: Print all tablet replica peer UUIDs found in a tablet’s Raft configuration Usage:
kudu local_replica cmeta print_replica_uuids <tablet_ids> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_ids |
Comma-separated list of Tablet Identifiers |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
rewrite_raft_config
: Rewrite a tablet replica’s Raft configuration Usage:
kudu local_replica cmeta rewrite_raft_config <tablet_ids> <peers>… [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_ids |
Comma-separated list of Tablet Identifiers |
string |
none |
peers… |
List of peers where each element is of form 'uuid:hostname:port', with elements of the list separated by a whitespace |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
set_term
: Bump the current term stored in consensus metadata Usage:
kudu local_replica cmeta set_term <tablet_id> <term> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
term |
the new raft term (must be greater than the current term) |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
tmeta
: Edit a local tablet metadatadelete_rowsets
: Delete rowsets from a local replica. The common usage pattern of this tool is described below.
That involves checking the result by a dry run of the tablet server with the modified tablet’s data after running the tool. It’s crucial to customize tablet server’s --enable_tablet_orphaned_block_deletion flag for the dry run to avoid deleting orphaned blocks, so it’s possible to roll back to the original state of the tablet’s data if something goes wrong. First, run the tool with default settings for --backup_metadata and --enable_tablet_orphaned_block_deletion to (a) create a backup of the original metadata file and (b) keep the orphaned blocks on the file system. Second, start the tablet server with --enable_tablet_orphaned_block_deletion=false to check whether the change worked as expected and the tablet server works fine with the new state of the tablet’s data. If it doesn’t work as expected, stop the tablet server (if still running), rollback the change by replacing the updated metadata file with the backup created earlier, and retry the procedure again, specifying proper rowset identifiers to the tool. If the change works as expected and the tablet server runs fine after with the updated tablet’s data, remove the customization for the --enable_tablet_orphaned_block_deletion flag and restart the tablet server.
Usage:
kudu local_replica tmeta delete_rowsets <tablet_id> <rowset_ids> [-nobackup_metadata] [-enable_tablet_orphaned_block_deletion] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
rowset_ids |
Comma-separated list of Rowset Identifiers |
string |
none |
backup_metadata (optional) |
Whether to backup tablet metadata file when editing it. |
bool |
|
enable_tablet_orphaned_block_deletion (optional) |
Whether to enable deletion of orphaned blocks from disk. Note: This is only exposed for debugging purposes and used in CLI tools. |
bool |
|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
dump
: Dump a Kudu filesystemblock_ids
: Dump the IDs of all blocks belonging to a local replica Usage:
kudu local_replica dump block_ids <tablet_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
data_dirs
: Dump the data directories where the replica’s data is stored Usage:
kudu local_replica dump data_dirs <tablet_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
meta
: Dump the metadata of a local replica Usage:
kudu local_replica dump meta <tablet_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
rowset
: Dump the rowset contents of a local replica Usage:
kudu local_replica dump rowset <tablet_id> [-nodump_all_columns] [-nodump_metadata] [-dump_primary_key_bounds_only] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-nrows=<nrows>] [-rowset_index=<index>] [-use_readable_format]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
dump_all_columns (optional) |
If true, dumped rows include all of the columns in the rowset. If false, dumped rows include just the key columns (in a comparable format). |
bool |
|
dump_metadata (optional) |
If true, dumps rowset metadata before dumping data. If false, only dumps the data. |
bool |
|
dump_primary_key_bounds_only (optional) |
Whether to dump rowset primary key bounds only, otherwise, dump all rows. |
bool |
|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
nrows (optional) |
Number of rows to dump. If negative, dumps all rows. |
int64 |
|
rowset_index (optional) |
Index of the rowset in local replica, default value(-1) will dump all the rowsets of the local replica |
int64 |
|
use_readable_format (optional) |
Whether to dump primary key in human readable format, otherwise, dump primary key in comparable format. |
bool |
|
wals
: Dump all WAL (write-ahead log) segments of a local replica Usage:
kudu local_replica dump wals <tablet_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-print_entries=<entries>] [-noprint_meta] [-truncate_data=<data>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
print_entries (optional) |
How to print entries: false|0|no = don’t print true|1|yes|decoded = print them decoded pb = print the raw protobuf id = print only their ids |
string |
|
print_meta (optional) |
Include metadata in output |
bool |
|
truncate_data (optional) |
Truncate the data fields to the given number of bytes before printing. Set to 0 to disable |
int32 |
|
master
: Operate on a Kudu Masterdump_memtrackers
: Dump the memtrackers from a Kudu Master Usage:
kudu master dump_memtrackers <master_address> [-format=<format>] [-memtracker_output=<output>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
memtracker_output (optional) |
One of 'json', 'json_compact' or 'table'. Table output flattens the memtracker hierarchy. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
get_flags
: Get the gflags for a Kudu Master Usage:
kudu master get_flags <master_address> [-all_flags] [-flags=<flags>] [-flag_tags=<tags>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
all_flags (optional) |
Whether to return all flags, or only flags that were explicitly set. |
bool |
|
flags (optional) |
Comma-separated list of flags used to restrict which flags are returned. An empty value means no restriction. If non-empty, all_flags is ignored. |
string |
none |
flag_tags (optional) |
Comma-separated list of tags used to restrict which flags are returned. An empty value matches all tags |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
run
: Run a Kudu Master Note: The master server is started in this process and runs until interrupted.
The most common configuration flags are described below. For all the configuration options pass --helpfull or see https://kudu.apache.org/docs/configuration_reference.html#kudu-master_supported
Usage:
kudu master run [-master_addresses=<addresses>] [-fs_wal_dir=<dir>] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-log_dir=<dir>] [-logtostderr]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses (optional) |
Comma-separated list of the RPC addresses belonging to all Masters in this cluster. NOTE: if not specified or a single address is specified, configures a non-replicated Master. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
log_dir (optional) |
If specified, logfiles are written into this directory instead of the default logging directory. |
string |
none |
logtostderr (optional) |
log messages go to stderr instead of logfiles |
bool |
|
set_flag
: Change a gflag value on a Kudu Master Usage:
kudu master set_flag <master_address> <flag> <value> [-force] [-norun_consistency_check] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
flag |
Name of the gflag |
string |
none |
value |
New value for the gflag |
string |
none |
force (optional) |
If true, allows the set_flag command to set a flag which is not explicitly marked as runtime-settable. Such flag changes may be simply ignored on the server, or may cause the server to crash. |
bool |
|
run_consistency_check (optional) |
If true, Kudu server checks all flags for consistency upon setting a flag. In this mode, the server rolls the flag back to its previous value and sends corresponding error response if an inconsistency is detected. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_flag_for_all
: Change a gflag value for all Kudu Masters in the cluster Usage:
kudu master set_flag_for_all <master_addresses> <flag> <value> [-force] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
flag |
Name of the gflag |
string |
none |
value |
New value for the gflag |
string |
none |
force (optional) |
If true, allows the set_flag command to set a flag which is not explicitly marked as runtime-settable. Such flag changes may be simply ignored on the server, or may cause the server to crash. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
status
: Get the status of a Kudu Master Usage:
kudu master status <master_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
timestamp
: Get the current timestamp of a Kudu Master Usage:
kudu master timestamp <master_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
list
: List masters in a Kudu cluster Usage:
kudu master list <master_addresses> [-columns=<columns>] [-format=<format>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
columns (optional) |
Comma-separated list of master info fields to include in output. Possible values: uuid, cluster_id, rpc-addresses, http-addresses, version, seqno, start_time, role and member_type |
string |
|
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
add
: Add a master to the Kudu cluster This is an advanced command that orchestrates the workflow to bring up and add a new master to the Kudu cluster. It must be run locally on the new master being added and not on the leader master. This tool shuts down the new master after completion of the command regardless of whether the new master addition is successful. After the command completes successfully, user is expected to explicitly start the new master using the same flags as supplied to this tool.
Supply all the necessary flags to bring up the new master. The most common configuration flags used to bring up a master are described below. See "Kudu Configuration Reference" for all the configuration options that apply to a Kudu master.
Please refer to the Kudu administration documentation on "Migrating to Multiple Kudu Masters" for the complete steps.
Usage:
kudu master add <master_addresses> <master_address> [-wait_secs=<secs>] [-kudu_abs_path=<path>] [-fs_wal_dir=<dir>] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-log_dir=<dir>] [-logtostderr]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
wait_secs (optional) |
Timeout in seconds to wait while retrying operations like bringing up new master, running ksck, waiting for the new master to be promoted as VOTER, etc. This flag is not passed to the new master. |
int64 |
|
kudu_abs_path (optional) |
Absolute file path of the 'kudu' executable used to bring up new master and other workflow steps. This flag is not passed to the new master. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
log_dir (optional) |
If specified, logfiles are written into this directory instead of the default logging directory. |
string |
none |
logtostderr (optional) |
log messages go to stderr instead of logfiles |
bool |
|
remove
: Remove a master from the Kudu cluster Removes a master from the Raft configuration of the Kudu cluster.
Please refer to the Kudu administration documentation on "Removing Kudu Masters from a Multi-Master Deployment" or "Recovering from a dead Kudu Master in a Multi-Master Deployment" as appropriate.
Usage:
kudu master remove <master_addresses> <master_address> [-master_uuid=<uuid>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
master_address |
Address of a Kudu Master of form 'hostname:port'. Port may be omitted if the Master is bound to the default port. |
string |
none |
master_uuid (optional) |
Permanent UUID of the master. Only needed to disambiguate in case of multiple masters with same RPC address |
string |
none |
unsafe_rebuild
: Rebuild a Kudu master from tablet server metadata Attempts to create or update on-disk metadata that can be used by a non-replicated master to recover a Kudu cluster that has permanently lost its masters. It has a number of limitations:
Security metadata like cryptographic keys are not rebuilt. Tablet servers and clients must be restarted before starting the new master in order to communicate with the new master.
Table IDs are known only by the masters. Reconstructed tables will have new IDs.
If a create, delete, or alter table was in progress when the masters were lost, it may not be possible to restore the table.
If all replicas of a tablet are missing, it may not be able to recover the table fully. Moreover, the rebuild tool cannot detect that a tablet is missing.
It’s not possible to determine the replication factor of a table from tablet server metadata. The rebuild tool sets the replication factor of each table to --default_num_replicas instead.
It’s not possible to determine the next column id for a table from tablet server metadata. Instead, the rebuilt tool sets the next column id to a very large number.
Table metadata like comments, owners, and configurations are not stored on tablet servers and are thus not restored.
Without '--tables', the tool will build a brand new syscatalog table based on tablet data on tablet server metadata.
With '--tables', the tool will update specific tables in current syscatalog.
This tool is potentially unsafe. Only use it when there is no possibility of recovering the original masters, and you know what you are doing.
Usage: kudu master unsafe_rebuild <tserver_addresses>… [-default_num_replicas=<replicas>] [-default_schema_version=<version>] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-tables=<tables>]
Arguments: |
Name | Description | Type | Default |
---|---|---|---|
tserver_addresses… |
Address list of Kudu tablet servers of form 'hostname-0:port-0 hostname-1:port-1 … hostname-n:port-n'. Port may be omitted if the tablet server is bound to the default port. |
string |
none |
default_num_replicas (optional) |
Default number of replicas for tables that do not have the num_replicas set. |
int32 |
|
default_schema_version (optional) |
The table schema version assigned to tables if one cannot be determined automatically. When the tablet server version is < 1.16, a viable value can be determined manually using 'kudu pbc dump tablet-meta/<tablet-id>' on each server and taking the max value found across all tablets. In tablet server versions >= 1.16, Kudu will determine the proper value for each tablet automatically. |
uint32 |
|
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
tables (optional) |
Tables to include (comma-separated list of table names)If not specified, includes all tables. |
string |
none |
authz_cache
: Operate on the authz caches of the Kudu Mastersrefresh
: Refresh the authorization policies Usage:
kudu master authz_cache refresh <master_addresses> [-force] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
force (optional) |
Ignore mismatches of the specified and the actual lists of master addresses in the cluster |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
pbc
: Operate on PBC (protobuf container) filesdump
: Dump a PBC (protobuf container) file Usage:
kudu pbc dump <path> [-debug] [-oneline] [-json] [-json_pretty]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
path |
path to PBC file |
string |
none |
debug (optional) |
Print extra debugging information about each protobuf |
bool |
|
oneline (optional) |
Print each protobuf on a single line |
bool |
|
json (optional) |
Print protobufs in JSON format |
bool |
|
json_pretty (optional) |
Print or edit protobufs in JSON pretty format |
bool |
|
edit
: Edit a PBC (protobuf container) file Usage:
kudu pbc edit <path> [-nobackup] [-json] [-json_pretty]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
path |
path to PBC file |
string |
none |
backup (optional) |
Write a backup file |
bool |
|
json (optional) |
Print protobufs in JSON format |
bool |
|
json_pretty (optional) |
Print or edit protobufs in JSON pretty format |
bool |
|
perf
: Measure the performance of a Kudu clusterloadgen
: Run load generation with optional scan afterwards Run load generation tool which inserts auto-generated data into an existing or auto-created table as fast as possible. If requested, also scan the inserted rows to check whether the actual count of inserted rows matches the expected one.
Usage:
kudu perf loadgen <master_addresses> [-auto_database=<database>] [-buffer_flush_watermark_pct=<pct>] [-buffer_size_bytes=<bytes>] [-buffers_num=<num>] [-error_buffer_size_bytes=<bytes>] [-flush_per_n_rows=<rows>] [-keep_auto_table] [-num_rows_per_thread=<thread>] [-num_threads=<threads>] [-run_cleanup] [-run_scan] [-seq_start=<start>] [-show_first_n_errors=<errors>] [-string_fixed=<fixed>] [-string_len=<len>] [-table_name=<name>] [-table_num_hash_partitions=<partitions>] [-table_num_range_partitions=<partitions>] [-table_num_replicas=<replicas>] [-txn_start] [-txn_commit] [-txn_rollback] [-nouse_client_per_thread] [-use_random] [-use_random_pk] [-use_random_non_pk] [-use_upsert] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
auto_database (optional) |
The database in which to create the automatically generated table. If --table_name is set, this flag has no effect, since a table is not created. This flag is useful primarily when the Hive Metastore integration is enabled in the cluster. If empty, no database is used. |
string |
|
buffer_flush_watermark_pct (optional) |
Mutation buffer flush watermark, in percentage of total size. |
double |
|
buffer_size_bytes (optional) |
Size of the mutation buffer, per session (bytes). |
int32 |
|
buffers_num (optional) |
Number of mutation buffers per session. |
int32 |
|
error_buffer_size_bytes (optional) |
Size of the error buffer, per session (bytes). 0 means 'unlimited'. This setting may impose an additional upper limit for the effective number of errors controlled by the '--show_first_n_errors' flag. |
int32 |
|
flush_per_n_rows (optional) |
Perform async flush per given number of rows added. Setting to non-zero implicitly turns on manual flush mode. |
int32 |
|
keep_auto_table (optional) |
If using the auto-generated table, enabling this option retains the table populated with the data after the test finishes. By default, the auto-generated table is dropped after successfully finishing the test. NOTE: this parameter has no effect if using already existing table (see the '--table_name' flag): neither the existing table nor its data is ever dropped/deleted. |
bool |
|
num_rows_per_thread (optional) |
Number of rows each thread generates and inserts; -1 means unlimited. All rows generated by a thread are inserted in the context of the same session. |
int64 |
|
num_threads (optional) |
Number of threads to run. |
int32 |
|
run_cleanup (optional) |
Whether to run post-insertion deletion to reset the existing table as before. |
bool |
|
run_scan (optional) |
Whether to run post-insertion scan to verify that the count of the inserted rows matches the expected number. If enabled, the scan is run only if no errors were encountered while inserting the generated rows. |
bool |
|
seq_start (optional) |
Initial value for the generator in sequential mode. This is useful when running multiple times against already existing table: for every next run, set this flag to (num_threads * num_rows_per_thread * column_num + seq_start). |
uint64 |
|
show_first_n_errors (optional) |
Output detailed information on the specified number of first n errors (if any). The limit on the per-session error buffer space may impose an additional upper limit for the effective number of errors in the output. If so, consider increasing the size of the error buffer using the '--error_buffer_size_bytes' flag. |
int32 |
|
string_fixed (optional) |
Pre-defined string to write into binary and string columns. Client generates more data per second using pre-defined string compared with auto-generated strings of the same length if run with the same CPU/memory configuration. If left empty, then auto-generated strings of length specified by the '--string_len' parameter are used instead. |
string |
none |
string_len (optional) |
Length of strings to put into string and binary columns. This parameter is not in effect if '--string_fixed' is specified. |
int32 |
|
table_name (optional) |
Name of an existing table to use for the test. The test will determine the structure of the table schema and populate it with data accordingly. If left empty, the test automatically creates a table of pre-defined columnar structure with unique name and uses it to insert auto-generated data. The auto-created table is dropped upon successful completion of the test if not overridden by the '--keep_auto_table' flag. If running the test against an already existing table, it’s recommended to use a dedicated table created just for testing purposes: the tool doesn’t delete the rows it inserted into the table. Neither the existing table nor its data is ever dropped/deleted. |
string |
none |
table_num_hash_partitions (optional) |
The number of hash partitions to create when this tool creates a new table. Note: The total number of partitions must be greater than 1. |
int32 |
|
table_num_range_partitions (optional) |
The number of range partitions to create when this tool creates a new table. A range partition schema will be determined to evenly split a sequential workload across ranges, leaving the outermost ranges unbounded to ensure coverage of the entire keyspace. Note: The total number of partitions must be greater than 1. |
int32 |
|
table_num_replicas (optional) |
The number of replicas for the auto-created table; 0 means 'use server-side default'. |
int32 |
|
txn_start (optional) |
Whether the generated rows are inserted in the context of a multi-row transaction. For now, only supported if configured to insert rows (i.e. UPDATE and DELETE are not yet supported). Unless --txn_commit or --txn_rollback is specified, the started transaction is left 'as is' (i.e. neither commit, nor rollback is performed) once the tool completes its operations. |
bool |
|
txn_commit (optional) |
Whether to commit the multi-row transaction which contains all the inserted rows. Setting --txn_commit=true implies setting --txn_start=true as well. |
bool |
|
txn_rollback (optional) |
Whether to rollback the multi-row transaction which contains all the inserted rows. Setting --txn_rollback=true implies setting --txn_start=true as well. |
bool |
|
use_client_per_thread (optional) |
Use a separate KuduClient instance for each load-generating thread. This increases throughput by reducing contention on various Client internals. |
bool |
|
use_random (optional) |
Whether to use random numbers instead of sequential ones for both primary keys and non-primary key columns. In case of using random numbers collisions are possible over the data for columns with unique constraint (e.g. primary key). This option has been deprecated, use '--use_random_pk' and/or '--use_random_non_pk' instead. If either '--use_random_pk' or '--use_random_non_pk' is specified with '--use_random' then this option will be ignored. |
bool |
|
use_random_pk (optional) |
Whether to use random numbers instead of sequential ones for primary key columns. Using random numbers may cause collisions over primary key columns. |
bool |
|
use_random_non_pk (optional) |
Whether to use random numbers instead of sequential ones for non-primary key columns. |
bool |
|
use_upsert (optional) |
Whether to use UPSERT instead of INSERT to store the generated data into the table |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
table_scan
: Show row count and scanning time cost of tablets in a table Show row count and scanning time of tablets in a table. This can be useful to check for row count skew across different tablets, or whether there is a long latency tail when scanning different tables.
Usage:
kudu perf table_scan <master_addresses> <table_name> [-columns=<columns>] [-row_count_only] [-report_scanner_stats] [-scan_batch_size=<size>] [-fault_tolerant] [-nofill_cache] [-num_threads=<threads>] [-predicates=<predicates>] [-tablets=<tablets>] [-replica_selection=<selection>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to scan |
string |
none |
columns (optional) |
Comma-separated list of column fields to include in output tables |
string |
|
row_count_only (optional) |
Whether to only count rows instead of reading row cells: yields an empty projection for the table |
bool |
|
report_scanner_stats (optional) |
Whether to report scanner statistics |
bool |
|
scan_batch_size (optional) |
The size for scan results batches, in bytes. A negative value means the server-side default is used, where the server-side default is controlled by the tablet server’s --scanner_default_batch_size_bytes flag. |
int32 |
|
fault_tolerant (optional) |
Whether to make scans resumable at another tablet server if current server fails. Fault-tolerant scans typically have lower throughput than non fault-tolerant scans, but the results are returned in primary key order for a single tablet. |
bool |
|
fill_cache (optional) |
Whether to fill block cache when scanning. |
bool |
|
num_threads (optional) |
Number of threads to run. |
int32 |
|
predicates (optional) |
Query predicates on columns. Unlike traditional SQL syntax, the scan tool’s simple query predicates are represented in a simple JSON syntax. Three types of predicates are supported, including 'Comparison', 'InList' and 'IsNull'.
* The 'Comparison' type support ⇐, <, =, > and >=,
which can be represented as '[operator, column_name, value]',
e.g. '[">=", "col1", "value"]'
* The 'InList' type can be represented as
'["IN", column_name, [value1, value2, …]]'
e.g. '["IN", "col2", ["value1", "value2"]]'
* The 'IsNull' type determine whether the value is NULL or not,
which can be represented as '[operator, column_name]'
e.g. '["NULL", "col1"]', or '["NOTNULL", "col2"]'
Predicates can be combined together with predicate operators using the syntax
[operator, predicate, predicate, …, predicate].
For example,
["AND", [">=", "col1", "value"], ["NOTNULL", "col2"]]
The only supported predicate operator is |
string |
none |
tablets (optional) |
Tablets to check (comma-separated list of IDs) If not specified, checks all tablets. |
string |
none |
replica_selection (optional) |
Replica selection for scan operations. Acceptable values are: CLOSEST, LEADER (maps into KuduClient::CLOSEST_REPLICA and KuduClient::LEADER_ONLY correspondingly). |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
tablet_scan
: Show row count of a local tablet Usage:
kudu perf tablet_scan <tablet_id> [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-fs_wal_dir=<dir>] [-num_iters=<iters>] [-ordered_scan]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
num_iters (optional) |
Number of times to run the scan. |
int32 |
|
ordered_scan (optional) |
Whether to run an ordered or unordered scan. |
bool |
|
remote_replica
: Operate on remote tablet replicas on a Kudu Tablet Servercheck
: Check if all tablet replicas on a Kudu tablet server are running. Tombstoned replica do not count as not running, because they are just records of the previous existence of a replica. Usage:
kudu remote_replica check <tserver_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
copy
: Copy a tablet replica from one Kudu Tablet Server to another Usage:
kudu remote_replica copy <tablet_id> <src_address> <dst_address> [-force_copy] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tablet_id |
Tablet Identifier |
string |
none |
src_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
dst_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
force_copy (optional) |
Force the copy when the destination tablet server has this replica |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
delete
: Delete a tablet replica from a Kudu Tablet Server Usage:
kudu remote_replica delete <tserver_address> <tablet_id> <reason> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
reason |
Reason for deleting the replica |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
dump
: Dump the data of a tablet replica on a Kudu Tablet Server Usage:
kudu remote_replica dump <tserver_address> <tablet_id> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
list
: List all tablet replicas on a Kudu Tablet Server Usage:
kudu remote_replica list <tserver_address> [-noinclude_schema] [-table_name=<name>] [-tablets=<tablets>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
include_schema (optional) |
Whether to include the schema of each replica |
bool |
|
table_name (optional) |
Restrict output to a specific table by name |
string |
none |
tablets (optional) |
Comma-separated list of tablet IDs used to filter the list of replicas |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
unsafe_change_config
: Force the specified replica to adopt a new Raft config This tool is useful when a config change is necessary because a tablet cannot make progress with its current Raft configuration (e.g. to evict followers when a majority is unavailable).
Note: The members of the new Raft config must be a subset of (or the same as) the members of the existing committed Raft config.
Usage:
kudu remote_replica unsafe_change_config <tserver_address> <tablet_id> <peer uuids>… [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
peer uuids… |
List of peer uuids to be part of new config, separated by whitespace |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
table
: Operate on Kudu tablesadd_column
: Add a column Usage:
kudu table add_column <master_addresses> <table_name> <column_name> <data_type> [-encoding_type=<type>] [-compression_type=<type>] [-default_value=<value>] [-comment=<comment>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to add |
string |
none |
data_type |
Data Type, eg: INT8, INT16, INT32, INT64, STRING, BOOL, FLOAT, DOUBLE, BINARY, UNIXTIME_MICROS, DECIMAL, VARCHAR, TIMESTAMP, DATE |
string |
none |
encoding_type (optional) |
Type of encoding for the column including AUTO_ENCODING, PLAIN_ENCODING, PREFIX_ENCODING, RLE, DICT_ENCODING, BIT_SHUFFLE, GROUP_VARINT |
string |
|
compression_type (optional) |
Type of compression for the column including DEFAULT_COMPRESSION, NO_COMPRESSION, SNAPPY, LZ4, ZLIB |
string |
|
default_value (optional) |
Default value for this column. |
string |
none |
comment (optional) |
Comment for this column. |
string |
none |
add_range_partition
: Add a range partition for table Usage:
kudu table add_range_partition <master_addresses> <table_name> <table_range_lower_bound> <table_range_upper_bound> [-lower_bound_type=<type>] [-upper_bound_type=<type>] [-hash_schema=<schema>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table |
string |
none |
table_range_lower_bound |
String representation of lower bound of the table range partition as a JSON array.If the parameter is an empty array, the lower range partition will be unbounded |
string |
none |
table_range_upper_bound |
String representation of upper bound of the table range partition as a JSON array.If the parameter is an empty array, the upper range partition will be unbounded |
string |
none |
lower_bound_type (optional) |
The type of the lower bound, either inclusive or exclusive. Defaults to inclusive. This flag is case-insensitive. |
string |
|
upper_bound_type (optional) |
The type of the upper bound, either inclusive or exclusive. Defaults to exclusive. This flag is case-insensitive. |
string |
|
hash_schema (optional) |
String representation of range-specific hash schema as a JSON object, e.g. {"hash_schema": [{"columns": ["c0"], "num_buckets": 5}]} |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
clear_comment
: Clear the comment for a table Usage:
kudu table clear_comment <master_addresses> <table_name> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_remove_default
: Remove write_default value for a column Usage:
kudu table column_remove_default <master_addresses> <table_name> <column_name> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_set_block_size
: Set block size for a column Usage:
kudu table column_set_block_size <master_addresses> <table_name> <column_name> <block_size> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
block_size |
Block size of the column |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_set_compression
: Set compression type for a column Usage:
kudu table column_set_compression <master_addresses> <table_name> <column_name> <compression_type> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
compression_type |
Compression type of the column |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_set_default
: Set write_default value for a column Usage:
kudu table column_set_default <master_addresses> <table_name> <column_name> <default_value> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
default_value |
Write default value of the column, should be provided as a JSON array, e.g. [1] or ["foo"] |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_set_encoding
: Set encoding type for a column Usage:
kudu table column_set_encoding <master_addresses> <table_name> <column_name> <encoding_type> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
encoding_type |
Encoding type of the column |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
column_set_comment
: Set comment for a column Usage:
kudu table column_set_comment <master_addresses> <table_name> <column_name> <column_comment> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to alter |
string |
none |
column_comment |
Comment of the column |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
copy
: Copy table data to another table Copy table data to another table; the two tables could be in the same cluster or not. The two tables must have the same table schema, but could have different partition schemas. Alternatively, the tool can create the new table using the same table and partition schema as the source table.
Usage:
kudu table copy <master_addresses> <table_name> <dest_master_addresses> [-nocreate_table] [-create_table_hash_bucket_nums=<nums>] [-create_table_replication_factor=<factor>] [-dst_table=<table>] [-fault_tolerant] [-nofill_cache] [-num_threads=<threads>] [-predicates=<predicates>] [-scan_batch_size=<size>] [-tablets=<tablets>] [-write_type=<type>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the source table |
string |
none |
dest_master_addresses |
Either comma-separated list of destination Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
create_table (optional) |
Whether to create the destination table if it doesn’t exist. |
bool |
|
create_table_hash_bucket_nums (optional) |
The number of hash buckets in each hash dimension seperated by comma |
string |
none |
create_table_replication_factor (optional) |
The replication factor of the destination table if the table will be created. By default, the replication factor of source table will be used. |
int32 |
|
dst_table (optional) |
The name of the destination table the data will be copied to. If the empty string, use the same name as the source table. |
string |
none |
fault_tolerant (optional) |
Whether to make scans resumable at another tablet server if current server fails. Fault-tolerant scans typically have lower throughput than non fault-tolerant scans, but the results are returned in primary key order for a single tablet. |
bool |
|
fill_cache (optional) |
Whether to fill block cache when scanning. |
bool |
|
num_threads (optional) |
Number of threads to run. |
int32 |
|
predicates (optional) |
Query predicates on columns. Unlike traditional SQL syntax, the scan tool’s simple query predicates are represented in a simple JSON syntax. Three types of predicates are supported, including 'Comparison', 'InList' and 'IsNull'.
* The 'Comparison' type support ⇐, <, =, > and >=,
which can be represented as '[operator, column_name, value]',
e.g. '[">=", "col1", "value"]'
* The 'InList' type can be represented as
'["IN", column_name, [value1, value2, …]]'
e.g. '["IN", "col2", ["value1", "value2"]]'
* The 'IsNull' type determine whether the value is NULL or not,
which can be represented as '[operator, column_name]'
e.g. '["NULL", "col1"]', or '["NOTNULL", "col2"]'
Predicates can be combined together with predicate operators using the syntax
[operator, predicate, predicate, …, predicate].
For example,
["AND", [">=", "col1", "value"], ["NOTNULL", "col2"]]
The only supported predicate operator is |
string |
none |
scan_batch_size (optional) |
The size for scan results batches, in bytes. A negative value means the server-side default is used, where the server-side default is controlled by the tablet server’s --scanner_default_batch_size_bytes flag. |
int32 |
|
tablets (optional) |
Tablets to check (comma-separated list of IDs) If not specified, checks all tablets. |
string |
none |
write_type (optional) |
Write operation type to use when populating the destination table with the rows from the source table. Choose from 'insert', 'insert_ignore', 'upsert', 'upsert_ignore', or an empty string. Empty string means the data isn’t going to be copied, which is useful with --create_table=true when just creating the destination table without copying the data. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
create
: Create a new table provide parameters for the table to create as a JSON object, e.g.
'{
"table_name": "test",
"schema": {
"columns": [
{
"column_name": "id",
"column_type": "INT32",
"default_value": "1"
},
{
"column_name": "key",
"column_type": "INT64",
"is_nullable": false,
"comment": "range partition column"
},
{
"column_name": "name",
"column_type": "STRING",
"is_nullable": false,
"comment": "user name"
}
],
"key_column_names": ["id", "key"]
},
"partition": {
"hash_partitions": [{"columns": ["id"], "num_buckets": 2, "seed": 8}],
"range_partition": {
"columns": ["key"],
"range_bounds": [
{
"lower_bound": {"bound_type": "inclusive", "bound_values": ["2"]},
"upper_bound": {"bound_type": "exclusive", "bound_values": ["3"]}
},
{
"lower_bound": {"bound_type": "inclusive", "bound_values": ["3"]}
}
]
}
},
"extra_configs": {
"configs": { "kudu.table.history_max_age_sec": "3600" }
},
"comment": "a test table",
"num_replicas": 3
}'
Usage:
kudu table create <master_addresses> <create_table_json> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
create_table_json |
JSON object for creating table |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
delete_column
: Delete a column Usage:
kudu table delete_column <master_addresses> <table_name> <column_name> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to delete |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
delete
: Delete a table Usage:
kudu table delete <master_addresses> <table_name> [-nomodify_external_catalogs] [-reserve_seconds=<seconds>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to delete |
string |
none |
modify_external_catalogs (optional) |
Whether to modify external catalogs, such as the Hive Metastore, when renaming or dropping a table. |
bool |
|
reserve_seconds (optional) |
Grace period before purging a soft-deleted table, in seconds. If set to 0, it would be purged when a table is dropped/deleted. |
int32 |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
describe
: Describe a table Usage:
kudu table describe <master_addresses> <table_name> [-show_attributes] [-show_column_comment] [-show_avro_format_schema] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to describe |
string |
none |
show_attributes (optional) |
Whether to show column attributes, including column encoding type, compression type, and default read/write value. |
bool |
|
show_column_comment (optional) |
Whether to show column comment. |
bool |
|
show_avro_format_schema (optional) |
Display the table schema in avro format. When enabled it only outputs the table schema in Avro format without any other information like partition/owner/comments. It cannot be used in conjunction with other flags |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
drop_range_partition
: Drop a range partition of table Usage:
kudu table drop_range_partition <master_addresses> <table_name> <table_range_lower_bound> <table_range_upper_bound> [-lower_bound_type=<type>] [-upper_bound_type=<type>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table |
string |
none |
table_range_lower_bound |
String representation of lower bound of the table range partition as a JSON array |
string |
none |
table_range_upper_bound |
String representation of upper bound of the table range partition as a JSON array |
string |
none |
lower_bound_type (optional) |
The type of the lower bound, either inclusive or exclusive. Defaults to inclusive. This flag is case-insensitive. |
string |
|
upper_bound_type (optional) |
The type of the upper bound, either inclusive or exclusive. Defaults to exclusive. This flag is case-insensitive. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
get_extra_configs
: Get the extra configuration properties for a table Usage:
kudu table get_extra_configs <master_addresses> <table_name> [-config_names=<names>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table for which to get extra configurations |
string |
none |
config_names (optional) |
Comma-separated list of configurations to display. An empty value displays all configs. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
list
: List tables Usage:
kudu table list <master_addresses> [-soft_deleted_only] [-tables=<tables>] [-list_tablets] [-show_tablet_partition_info] [-show_hash_partition_info] [-show_table_info] [-list_table_output_format=<format>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
soft_deleted_only (optional) |
Show only soft-deleted tables if set true, otherwise show regular tables. |
bool |
|
tables (optional) |
Tables to include (comma-separated list of table names)If not specified, includes all tables. |
string |
none |
list_tablets (optional) |
Include tablet and replica UUIDs in the output |
bool |
|
show_tablet_partition_info (optional) |
Include partition keys information corresponding to tablet in the output. |
bool |
|
show_hash_partition_info (optional) |
Include hash partition keys information corresponding to tablet in the output. |
bool |
|
show_table_info (optional) |
Include extra information such as number of tablets, replicas, and live row count for a table in the output |
bool |
|
list_table_output_format (optional) |
One of 'json', 'json_compact' or 'pretty'. Pretty output flattens the table list hierarchy. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
locate_row
: Locate which tablet a row belongs to Provide the primary key as a JSON array of primary key values, e.g. '[1, "foo", 2, "bar"]'. The output will be the tablet id associated with the row key. If there is no such tablet, an error message will be printed and the command will return a non-zero status
Usage:
kudu table locate_row <master_addresses> <table_name> <primary_key> [-check_row_existence] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to look up against |
string |
none |
primary_key |
String representation of the row’s primary key as a JSON array |
string |
none |
check_row_existence (optional) |
Also check for the existence of the row on the leader replica of the tablet. If found, the full row will be printed; if not found, an error message will be printed and the command will return a non-zero status. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
recall
: Recall a deleted but still reserved table Usage:
kudu table recall <master_addresses> <table_id> [-new_table_name=<name>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_id |
ID of the table to recall |
string |
none |
new_table_name (optional) |
The new name for the recalled table. Leave empty to recall the table under its original name. |
string |
none |
rename_column
: Rename a column Usage:
kudu table rename_column <master_addresses> <table_name> <column_name> <new_column_name> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_name |
Name of the table column to rename |
string |
none |
new_column_name |
New column name |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
rename_table
: Rename a table Usage:
kudu table rename_table <master_addresses> <table_name> <new_table_name> [-nomodify_external_catalogs] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to rename |
string |
none |
new_table_name |
New table name |
string |
none |
modify_external_catalogs (optional) |
Whether to modify external catalogs, such as the Hive Metastore, when renaming or dropping a table. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
scan
: Scan rows from a table Scan rows from an existing table. See the help for the --predicates flag on how predicates can be specified.
Usage:
kudu table scan <master_addresses> <table_name> [-columns=<columns>] [-row_count_only] [-report_scanner_stats] [-scan_batch_size=<size>] [-fault_tolerant] [-nofill_cache] [-num_threads=<threads>] [-predicates=<predicates>] [-tablets=<tablets>] [-replica_selection=<selection>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to scan |
string |
none |
columns (optional) |
Comma-separated list of column fields to include in output tables |
string |
|
row_count_only (optional) |
Whether to only count rows instead of reading row cells: yields an empty projection for the table |
bool |
|
report_scanner_stats (optional) |
Whether to report scanner statistics |
bool |
|
scan_batch_size (optional) |
The size for scan results batches, in bytes. A negative value means the server-side default is used, where the server-side default is controlled by the tablet server’s --scanner_default_batch_size_bytes flag. |
int32 |
|
fault_tolerant (optional) |
Whether to make scans resumable at another tablet server if current server fails. Fault-tolerant scans typically have lower throughput than non fault-tolerant scans, but the results are returned in primary key order for a single tablet. |
bool |
|
fill_cache (optional) |
Whether to fill block cache when scanning. |
bool |
|
num_threads (optional) |
Number of threads to run. |
int32 |
|
predicates (optional) |
Query predicates on columns. Unlike traditional SQL syntax, the scan tool’s simple query predicates are represented in a simple JSON syntax. Three types of predicates are supported, including 'Comparison', 'InList' and 'IsNull'.
* The 'Comparison' type support ⇐, <, =, > and >=,
which can be represented as '[operator, column_name, value]',
e.g. '[">=", "col1", "value"]'
* The 'InList' type can be represented as
'["IN", column_name, [value1, value2, …]]'
e.g. '["IN", "col2", ["value1", "value2"]]'
* The 'IsNull' type determine whether the value is NULL or not,
which can be represented as '[operator, column_name]'
e.g. '["NULL", "col1"]', or '["NOTNULL", "col2"]'
Predicates can be combined together with predicate operators using the syntax
[operator, predicate, predicate, …, predicate].
For example,
["AND", [">=", "col1", "value"], ["NOTNULL", "col2"]]
The only supported predicate operator is |
string |
none |
tablets (optional) |
Tablets to check (comma-separated list of IDs) If not specified, checks all tablets. |
string |
none |
replica_selection (optional) |
Replica selection for scan operations. Acceptable values are: CLOSEST, LEADER (maps into KuduClient::CLOSEST_REPLICA and KuduClient::LEADER_ONLY correspondingly). |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_comment
: Set the comment for a table Usage:
kudu table set_comment <master_addresses> <table_name> <column_comment> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
column_comment |
Comment of the table |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_extra_config
: Change a extra configuration value on a table Usage:
kudu table set_extra_config <master_addresses> <table_name> <config_name> <config_value> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
config_name |
Name of the configuration |
string |
none |
config_value |
New value for the configuration |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_replication_factor
: Change a table’s replication factor Usage:
kudu table set_replication_factor <master_addresses> <table_name> <replication_factor> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to alter |
string |
none |
replication_factor |
New replication factor of the table |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
statistics
: Get table statistics Usage:
kudu table statistics <master_addresses> <table_name> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to get statistics |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_limit
: Set the write limit for a tabledisk_size
: Set the disk size limit Usage:
kudu table set_limit disk_size <master_addresses> <table_name> <disk_size> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to set limit |
string |
none |
disk_size |
The disk size limit, 'unlimited' for no write limit |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
row_count
: Set the row count limit Usage:
kudu table set_limit row_count <master_addresses> <table_name> <row_count> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
table_name |
Name of the table to set limit |
string |
none |
row_count |
The row count limit, 'unlimited' for no write limit |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
tablet
: Operate on remote Kudu tabletsleader_step_down
: Change the tablet’s leader Usage:
kudu tablet leader_step_down <master_addresses> <tablet_id> [-abrupt] [-new_leader_uuid=<uuid>] [-current_leader_uuid=<uuid>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
abrupt (optional) |
Whether the leader should step down without attempting to transfer leadership gracefully. A graceful transfer minimizes delays in tablet operations, but will fail if the tablet cannot arrange a successor. |
bool |
|
new_leader_uuid (optional) |
UUID of the server that leadership should be transferred to. Leadership may only be transferred to a voting member of the leader’s active config. If the designated successor cannot catch up to the leader within one election timeout, leadership transfer will not occur. If blank, the leader chooses its own successor, attempting to transfer leadership as soon as possible. This cannot be set if --abrupt is set. |
string |
none |
current_leader_uuid (optional) |
UUID of the server that currently hosts leader replica of the tablet. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
unsafe_replace_tablet
: Replace a tablet with an empty one, deleting the previous tablet. Use this tool to repair a table when one of its tablets has permanently lost all of its replicas. It replaces the unrecoverable tablet with a new empty one representing the same partition. Its primary use is to jettison an unrecoverable tablet in order to make the rest of the table available.
The original tablet will be deleted. Its data will be permanently lost. Additionally, clients should be restarted before attempting to use the repaired table (see KUDU-2376). Usage: kudu tablet unsafe_replace_tablet <master_addresses> <tablet_id> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments: |
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
change_config
: Change a tablet’s Raft configurationadd_replica
: Add a new replica to a tablet’s Raft configuration Usage:
kudu tablet change_config add_replica <master_addresses> <tablet_id> <ts_uuid> <replica_type> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
ts_uuid |
UUID of the tablet server that should host the new replica |
string |
none |
replica_type |
New replica’s type. Must be VOTER or NON_VOTER. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
change_replica_type
: Change the type of an existing replica in a tablet’s Raft configuration Usage:
kudu tablet change_config change_replica_type <master_addresses> <tablet_id> <ts_uuid> <replica_type> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
ts_uuid |
UUID of the tablet server hosting the existing replica |
string |
none |
replica_type |
Existing replica’s new type. Must be VOTER or NON_VOTER. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
move_replica
: Move a tablet replica from one tablet server to another The replica move tool effectively moves a replica from one tablet server to another by adding a replica to the new server and then removing it from the old one. It requires that ksck return no errors when run against the target tablet. If the move fails, the user should wait for any tablet copy to complete, and, if the copy succeeds, use remove_replica manually. If the copy fails, the new replica will be deleted automatically after some time, and then the move can be retried.
Usage:
kudu tablet change_config move_replica <master_addresses> <tablet_id> <from_ts_uuid> <to_ts_uuid> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
from_ts_uuid |
UUID of the tablet server to move from |
string |
none |
to_ts_uuid |
UUID of the tablet server to move to |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
remove_replica
: Remove an existing replica from a tablet’s Raft configuration Usage:
kudu tablet change_config remove_replica <master_addresses> <tablet_id> <ts_uuid> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tablet_id |
Tablet Identifier |
string |
none |
ts_uuid |
UUID of the tablet server hosting the existing replica |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
test
: Various test actionsmini_cluster
: Spawn a control shell for running a mini-cluster The protocol for the control shell is protobuf-based and is documented in src/kudu/tools/tool.proto. It is currently considered to be highly experimental and subject to change.
Example JSON input to create and start a cluster:
{"createCluster":{"numTservers":3}}
{"startCluster":{}}
Usage:
kudu test mini_cluster [-serialization=<serialization>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
serialization (optional) |
Serialization method to be used by the control shell. Valid values are 'json' (protobuf serialized into JSON and terminated with a newline character) or 'pb' (four byte protobuf message length in big endian followed by the protobuf message itself). |
string |
|
txn
: Operate on multi-row transactionslist
: Show details of multi-row transactions in the cluster Usage:
kudu txn list <master_addresses> [-columns=<columns>] [-max_txn_id=<id>] [-min_txn_id=<id>] [-included_states=<states>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
columns (optional) |
Comma-separated list of transaction-related info fields to include in the output. Possible values: txn_id, user, state, commit_datetime, commit_hybridtime, start_datetime, last_transition_datetime |
string |
|
max_txn_id (optional) |
Inclusive maximum transaction ID to display, or -1 for no maximum. |
int64 |
|
min_txn_id (optional) |
Inclusive minimum transaction ID to display, or -1 for no minimum. |
int64 |
|
included_states (optional) |
Comma-separated list of transaction states to display. Supported states are 'open', 'abort_in_progress', 'aborted', 'commit_in_progress', 'finalize_in_progress', and 'committed', or '*' for all states. By default, shows currently active transactions. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
show
: Show details of a specific transaction Usage:
kudu txn show <master_addresses> <txn_id> [-columns=<columns>] [-timeout_ms=<ms>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
txn_id |
Transaction ID on which to operate |
string |
none |
columns (optional) |
Comma-separated list of transaction-related info fields to include in the output. Possible values: txn_id, user, state, commit_datetime, commit_hybridtime, start_datetime, last_transition_datetime, participant_tablet_id, participant_is_aborted, participant_flushed_committed_mrs, participant_begin_commit_datetime, participant_begin_commit_hybridtime, participant_commit_datetime, participant_commit_hybridtime |
string |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
tserver
: Operate on a Kudu Tablet Serverdump_memtrackers
: Dump the memtrackers from a Kudu Tablet Server Usage:
kudu tserver dump_memtrackers <tserver_address> [-format=<format>] [-memtracker_output=<output>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
memtracker_output (optional) |
One of 'json', 'json_compact' or 'table'. Table output flattens the memtracker hierarchy. |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
get_flags
: Get the gflags for a Kudu Tablet Server Usage:
kudu tserver get_flags <tserver_address> [-all_flags] [-flags=<flags>] [-flag_tags=<tags>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
all_flags (optional) |
Whether to return all flags, or only flags that were explicitly set. |
bool |
|
flags (optional) |
Comma-separated list of flags used to restrict which flags are returned. An empty value means no restriction. If non-empty, all_flags is ignored. |
string |
none |
flag_tags (optional) |
Comma-separated list of tags used to restrict which flags are returned. An empty value matches all tags |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
run
: Run a Kudu Tablet Server Note: The tablet server is started in this process and runs until interrupted.
The most common configuration flags are described below. For all the configuration options pass --helpfull or see https://kudu.apache.org/docs/configuration_reference.html#kudu-tserver_supported
Usage:
kudu tserver run [-tserver_master_addrs=<addrs>] [-fs_wal_dir=<dir>] [-fs_data_dirs=<dirs>] [-fs_metadata_dir=<dir>] [-block_cache_capacity_mb=<mb>] [-memory_limit_hard_bytes=<bytes>] [-log_dir=<dir>] [-logtostderr]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_master_addrs (optional) |
Comma separated addresses of the masters which the tablet server should connect to. The masters do not read this flag — configure the masters separately using 'rpc_bind_addresses'. |
string |
|
fs_wal_dir (optional) |
Directory with write-ahead logs. If this is not specified, the program will not start. May be the same as fs_data_dirs |
string |
none |
fs_data_dirs (optional) |
Comma-separated list of directories with data blocks. If this is not specified, fs_wal_dir will be used as the sole data block directory. |
string |
none |
fs_metadata_dir (optional) |
Directory with metadata. If this is not specified, for compatibility with Kudu 1.6 and below, Kudu will check the first entry of fs_data_dirs for metadata and use it as the metadata directory if any exists. If none exists, fs_wal_dir will be used as the metadata directory. |
string |
none |
block_cache_capacity_mb (optional) |
block cache capacity in MB |
int64 |
|
memory_limit_hard_bytes (optional) |
Maximum amount of memory this daemon should use, in bytes. A value of 0 autosizes based on the total system memory. A value of -1 disables all memory limiting. |
int64 |
|
log_dir (optional) |
If specified, logfiles are written into this directory instead of the default logging directory. |
string |
none |
logtostderr (optional) |
log messages go to stderr instead of logfiles |
bool |
|
set_flag
: Change a gflag value on a Kudu Tablet Server Usage:
kudu tserver set_flag <tserver_address> <flag> <value> [-force] [-norun_consistency_check] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
flag |
Name of the gflag |
string |
none |
value |
New value for the gflag |
string |
none |
force (optional) |
If true, allows the set_flag command to set a flag which is not explicitly marked as runtime-settable. Such flag changes may be simply ignored on the server, or may cause the server to crash. |
bool |
|
run_consistency_check (optional) |
If true, Kudu server checks all flags for consistency upon setting a flag. In this mode, the server rolls the flag back to its previous value and sends corresponding error response if an inconsistency is detected. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
set_flag_for_all
: Change a gflag value for all Kudu Tablet Servers in the cluster Usage:
kudu tserver set_flag_for_all <master_addresses> <flag> <value> [-force] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
flag |
Name of the gflag |
string |
none |
value |
New value for the gflag |
string |
none |
force (optional) |
If true, allows the set_flag command to set a flag which is not explicitly marked as runtime-settable. Such flag changes may be simply ignored on the server, or may cause the server to crash. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
status
: Get the status of a Kudu Tablet Server Usage:
kudu tserver status <tserver_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
timestamp
: Get the current timestamp of a Kudu Tablet Server Usage:
kudu tserver timestamp <tserver_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
list
: List tablet servers in a Kudu cluster Usage:
kudu tserver list <master_addresses> [-columns=<columns>] [-format=<format>] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
columns (optional) |
Comma-separated list of tserver info fields to include in output. Possible values: uuid, rpc-addresses, http-addresses, version, seqno, heartbeat, start_time, state |
string |
|
format (optional) |
Format to use for printing list output tables. Possible values: pretty, space, tsv, csv, and json |
string |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
unregister
: Unregister a tablet server from the master’s in-memory state and system catalog. Usage:
kudu tserver unregister <master_addresses> <tserver_uuid> [-force_unregister_live_tserver] [-noremove_tserver_state] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tserver_uuid |
UUID of a Kudu Tablet Server |
string |
none |
force_unregister_live_tserver (optional) |
If true, force the unregistration of the tserver even if it is not presumed dead by the master. Make sure the tserver has been shut down before setting this true. |
bool |
|
remove_tserver_state (optional) |
If false, remove the tserver from the master’s in-memory map but keep its persisted state (if any). If the same tserver re-registers on the master it will get its original state |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
quiesce
: Operate on the quiescing state of a Kudu Tablet Server.status
: Output information about the quiescing state of a Tablet Server. Usage:
kudu tserver quiesce status <tserver_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
start
: Start quiescing the given Tablet Server. While a Tablet Server is quiescing, Tablet replicas on it will no longer attempt to become leader, and new scan requests will be retried at other servers. Usage:
kudu tserver quiesce start <tserver_address> [-error_if_not_fully_quiesced] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
error_if_not_fully_quiesced (optional) |
If true, the command to start quiescing will return an error if the tserver is not fully quiesced, i.e. there are still tablet leaders or active scanners on it. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
stop
: Stop quiescing a Tablet Server. Usage:
kudu tserver quiesce stop <tserver_address> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
tserver_address |
Address of a Kudu Tablet Server of form 'hostname:port'. Port may be omitted if the Tablet Server is bound to the default port. |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
state
: Operate on the state of a Kudu Tablet Serverenter_maintenance
: Begin maintenance on the Tablet Server. While under maintenance, downtime of the Tablet Server will not lead to the immediate re-replication of its tablet replicas. Usage:
kudu tserver state enter_maintenance <master_addresses> <tserver_uuid> [-allow_missing_tserver] [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tserver_uuid |
UUID of a Kudu Tablet Server |
string |
none |
allow_missing_tserver (optional) |
If true, performs the action on the tserver even if it has not been registered with the master and has no existing tserver state records associated with it. |
bool |
|
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
exit_maintenance
: End maintenance of the Tablet Server. Usage:
kudu tserver state exit_maintenance <master_addresses> <tserver_uuid> [-negotiation_timeout_ms=<ms>] [-timeout_ms=<ms>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
master_addresses |
Either comma-separated list of Kudu master addresses where each address is of form 'hostname:port', or a cluster name if it has been configured in ${KUDU_CONFIG}/kudurc |
string |
none |
tserver_uuid |
UUID of a Kudu Tablet Server |
string |
none |
negotiation_timeout_ms (optional) |
Timeout for negotiating an RPC connection to a Kudu server, in milliseconds |
int64 |
|
timeout_ms (optional) |
RPC timeout in milliseconds |
int64 |
|
wal
: Operate on WAL (write-ahead log) filesdump
: Dump a WAL (write-ahead log) file Usage:
kudu wal dump <path> [-print_entries=<entries>] [-noprint_meta] [-truncate_data=<data>]
Arguments:
Name | Description | Type | Default |
---|---|---|---|
path |
path to WAL file |
string |
none |
print_entries (optional) |
How to print entries: false|0|no = don’t print true|1|yes|decoded = print them decoded pb = print the raw protobuf id = print only their ids |
string |
|
print_meta (optional) |
Include metadata in output |
bool |
|
truncate_data (optional) |
Truncate the data fields to the given number of bytes before printing. Set to 0 to disable |
int32 |
|