sunil281984 avatar image
sunil281984 asked Erick Ramirez commented

Running cassandra-stress in DS210 returns "Illegal distribution type"

I Have modified the TestProfile.yaml as per the exercise DS210 : Configure and run cassandrastress exercise. Please find the below Testprofile.yaml file on ds210-node2 as below for your reference:

ubuntu@ds210-node2:/etc/dse/cassandra$ cat /home/ubuntu/labwork/TestProfile.yaml
# Keyspace Name
keyspace: killrvideo
keyspace_definition: |
CREATE KEYSPACE killrvideo WITH replication = {'class': 'SimpleStrategy', 'replication_factor': 1};

# Table name and create CQL
table: user_by_email
table_definition: |
CREATE TABLE user_by_email (
email text,
password text,
user_id uuid,
PRIMARY KEY((email))

# Meta information for generating data
- name: email
size: gaussian(8..30)
population: uniform(1..1234)
- name: password
size: exp(8..30)
population: uniform(1..1432)
- name: user_id
size: fixed(4)
population: unifrom(1..1567)

# Specs for insert queries
partitions: fixed(1)
select: fixed(1)/1
batchtype: UNLOGGED # use unlogged batches

# Read queries to run against the schema
user_by_email :
cql: select * from user_by_email where email = ?
fields: samerow

But when Iam trying to execute the Cassandra stress from Node2(ds210-node2) using below command it is not running, output of the command as below:

ubuntu@ds210-node2:/etc/dse/cassandra$ cassandra-stress user profile=/home/ubuntu/labwork/TestProfile.yaml ops\(insert=4,user_by_email=4\) -node
Illegal distribution type: unifrom
Usage: cassandra-stress <command> [options]
Help usage: cassandra-stress help <command>

read : Multiple concurrent reads - the cluster must first be populated by a write test
write : Multiple concurrent writes against the cluster
mixed : Interleaving of any basic commands, with configurable ratio and distribution - the cluster must first be populated by a write test
counter_write : Multiple concurrent updates of counters.
counter_read : Multiple concurrent reads of counters. The cluster must first be populated by a counterwrite test.
user : Interleaving of user provided queries, with configurable ratio and distribution
help : Print help for a command or option
print : Inspect the output of a distribution definition
legacy : Legacy support mode
version : Print the version of cassandra stress

-pop : Population distribution and intra-partition visit order
-insert : Insert specific options relating to various methods for batching and splitting partition updates
-col : Column details such as size and count distribution, data generator, names, comparator and if super columns should be used
-rate : Thread count, rate limit or automatic mode (default is auto)
-mode : CQL mode options
-errors : How to handle errors when encountered during stress
-schema : Replication settings, compression, compaction, etc.
-node : Nodes to connect to
-log : Where to log progress to, and the interval at which to do it
-transport : Custom transport factories
-port : The port to connect to cassandra nodes on
-sendto : Specify a stress server to send this command to
-graph : Graph recorded metrics
-tokenrange : Token range settings
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

Erick Ramirez avatar image
Erick Ramirez answered Erick Ramirez commented

As the error you posted indicates, the profile you used is invalid because unifrom is not a valid statistical distribution:

Illegal distribution type: unifrom

You spelled uniform incorrectly in the column specification section of your profile. When you fix the spelling, you should be able to re-run your test. Cheers!

2 comments Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Thanks for the correction. A minute spelling mistake stopped me for an hour.

0 Likes 0 ·
Not a problem. Cheers!
0 Likes 0 ·