I'm getting below error when running cassandra-stress command
./cassandra-stress user profile=/home/cass/apache-cassandra-3.11.2/tools/stress_test.yaml duration=1m "ops(insert=1,latest_event=1,events=1)"
I'm getting the below errors/warnings:
WARN 18:28:41,488 You listed localhost/0:0:0:0:0:0:0:1:9042 in your contact points, but it wasn't found in the control host's system.peers at startup
Connected to cluster: Test Cluster, max pending requests per connection 128, max connections per host 8
Datatacenter: datacenter1; Host: localhost/127.0.0.1; Rack: rack1
Generating batches with [1..50] partitions and [0..50] rows (of [1..50] total rows in the partitions)
Sleeping 2s...
Warming up insert with 0 iterations... Warming up latest_event with 0 iterations...
java.lang.IllegalArgumentException: No query defined with name latest_event at org.apache.cassandra.stress.StressProfile.getQuery(StressProfile.java:362) at org.apache.cassandra.stress.settings.SettingsCommandUser$1.get(SettingsCommandUser.java:93) at org.apache.cassandra.stress.settings.SettingsCommandUser$1.get(SettingsCommandUser.java:82) at org.apache.cassandra.stress.operations.SampledOpDistributionFactory$1.get(SampledOpDistributionFactory.java:83) at org.apache.cassandra.stress.StressAction$Consumer.(StressAction.java:409) at org.apache.cassandra.stress.StressAction.run(StressAction.java:233) at org.apache.cassandra.stress.StressAction.warmup(StressAction.java:121) at org.apache.cassandra.stress.StressAction.run(StressAction.java:70) at org.apache.cassandra.stress.Stress.run(Stress.java:143) at org.apache.cassandra.stress.Stress.main(Stress.java:62)
Here's how my stress_test.yaml file looks like:
keyspace: hss_cass_2
table: equipment_status
insert: partitions: uniform(1..50)
batchtype: LOGGED
select: uniform(1..10)/10
queries:simple1: cql: select * from equipment_status where equipment_id = ? and eq_status = ? LIMIT 100 fields: samerow
range1: cql: select * from equipment_status where equipment_id = ? and eq_status = ? and equipment_id_type = ? LIMIT 100 fields: multirow
Also, the name of the data center is dc1 but from the error log I find that Datacenter: datacenter1 is given. It might be one of the things which is wrong but I don't know.
Apache Cassandra 3.11.2. RHEL 6.5
You have an error in your command-line - you specified ops(insert=1,latest_event=1,events=1)
, but you don't have queries with name latest_event
& events
- per your file you have only queries simple1
& range1
- you need to specify them in the ops
command...
Following blog posts could provide more information on how to use it: from the lastpickle, and this series from instaclustr: 1, 2, 3 (especially this) & on how to test multiple tables.