Cluster Tool Options

The vkconfig script's cluster tool lets you define the streaming hosts your scheduler connects to.

Syntax

vkconfig cluster {--create | --read | --update | --delete} [--cluster cluster_name] [other_options...]
Option Description
--create

Creates a new cluster. Cannot be used with --delete, --read, or --update.

--read

Outputs the settings of all clusters defined in the scheduler. This output is in JSON format. Cannot be used with --create, --delete, or --update.

You can limit the output to specific clusters by supplying one or more cluster names in the --cluster option. You an also limit the output to clusters that contain one or more specific hosts using the --hosts option. Use commas to separate multiple values.

You can use LIKE wildcards in these options. See LIKE predicate for more information about using wildcards.

--update

Updates an existing cluster. Cannot be used with --create, --delete, or --read.

--delete

Deletes a cluster. Cannot be used with --create, --read, or --update.

--dump

When you use this option along with the --read option, vkconfig outputs the Vertica query it would use to retrieve the data, rather than outputting the data itself. This option is useful if you want to access the data from within Vertica without having to go through vkconfig. This option has no effect if not used with --read.

--cluster cluster_name A unique, case-insensitive name for the cluster to operate on. This option is required for --create, --update, and --delete.
--hosts b1:port[,b2:port…]

Identifies the broker hosts that you want to add, edit, or remove from a Kafka cluster. To identify multiple hosts, use a comma delimiter.

--kafka_conf 'option=value[;option2=value2...]'

A semicolon-delimited list of option=value pairs to pass directly to the rdkafka library. This is the library Vertica uses to communicate with Kafka. You can use this parameter to directly set configuration options that are not available through the Vertica integration with Kafka. See Directly Setting Kafka Library Options for details.

--new-cluster cluster_name The updated name for the cluster. Requires the --update shared utility option.
--validation-type{ERROR|WARN|SKIP}

Specifies the level of validation performed on a created or updated cluster:

  • ERROR - Cancel configuration or creation if vkconfig cannot validate that the cluster exists. This is the default setting.
  • WARN - Proceed with task if validation fails, but display a warning.
  • SKIP - Perform no validation.

Renamed from --skip-validation.

See Common vkconfig Script Options for options that are available in all of the vkconfig tools.

Examples

This example shows how you can create the cluster, StreamCluster1, and assign two hosts:

$ /opt/vertica/packages/kafka/bin/vkconfig cluster --create --cluster StreamCluster1 \
                                           --hosts 10.10.10.10:9092,10.10.10.11:9092
                                           --conf myscheduler.config

This example shows how you can list all of the clusters associated with the scheduler defined in the weblogs.conf file:

$ vkconfig cluster --read --conf weblog.conf
{"cluster":"kafka_weblog", 
"hosts":"kafka01.example.com:9092,kafka02.example.com:9092"}