WriteTimeoutException:一致性一致的写查询期间卡桑德拉超时

时间:2019-11-26 01:06:25

标签: kubernetes cassandra datastax ycsb

我正在尝试在通过kubernetes集群上的头盔图表部署的cassandra statefulset上运行ycsb基准测试。这是我要运行的命令-

$bin/ycsb load cassandra2-cql -s  -P workloads/workloada -P db.params -p recordcount=5000000 -p operationcount=10000000 -threads 10

params文件包含主机信息。我不断收到此错误,它似乎与我正在运行的线程数相对应。

Error inserting, not retrying any more. number of attempts: 1Insertion Retry Limit: 0
com.datastax.driver.core.exceptions.WriteTimeoutException: Cassandra timeout during write query at consistency ONE (1 replica were required but only 0 acknowledged the write)
    at com.datastax.driver.core.exceptions.WriteTimeoutException.copy(WriteTimeoutException.java:73)
    at com.datastax.driver.core.exceptions.WriteTimeoutException.copy(WriteTimeoutException.java:26)
    at com.datastax.driver.core.DriverThrowables.propagateCause(DriverThrowables.java:37)
    at com.datastax.driver.core.DefaultResultSetFuture.getUninterruptibly(DefaultResultSetFuture.java:245)
    at com.datastax.driver.core.AbstractSession.execute(AbstractSession.java:63)
    at site.ycsb.db.CassandraCQLClient.insert(CassandraCQLClient.java:586)
    at site.ycsb.DBWrapper.insert(DBWrapper.java:221)
    at site.ycsb.workloads.CoreWorkload.doInsert(CoreWorkload.java:601)
    at site.ycsb.ClientThread.run(ClientThread.java:135)
    at java.lang.Thread.run(Thread.java:748)
Caused by: com.datastax.driver.core.exceptions.WriteTimeoutException: Cassandra timeout during write query at consistency ONE (1 replica were required but only 0 acknowledged the write)
    at com.datastax.driver.core.exceptions.WriteTimeoutException.copy(WriteTimeoutException.java:100)
    at com.datastax.driver.core.Responses$Error.asException(Responses.java:122)
    at com.datastax.driver.core.RequestHandler$SpeculativeExecution.onSet(RequestHandler.java:477)
    at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:1005)
    at com.datastax.driver.core.Connection$Dispatcher.channelRead0(Connection.java:928)
    at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:318)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:304)

End output - 

[OVERALL], RunTime(ms), 32097
[OVERALL], Throughput(ops/sec), 8605.66408075521
[TOTAL_GCS_PS_Scavenge], Count, 27
[TOTAL_GC_TIME_PS_Scavenge], Time(ms), 89
[TOTAL_GC_TIME_%_PS_Scavenge], Time(%), 0.27728448141570866
[TOTAL_GCS_PS_MarkSweep], Count, 0
[TOTAL_GC_TIME_PS_MarkSweep], Time(ms), 0
[TOTAL_GC_TIME_%_PS_MarkSweep], Time(%), 0.0
[TOTAL_GCs], Count, 27
[TOTAL_GC_TIME], Time(ms), 89
[TOTAL_GC_TIME_%], Time(%), 0.27728448141570866
[CLEANUP], Operations, 10
[CLEANUP], AverageLatency(us), 222311.4
[CLEANUP], MinLatency(us), 0
[CLEANUP], MaxLatency(us), 2224127
[CLEANUP], 95thPercentileLatency(us), 2224127
[CLEANUP], 99thPercentileLatency(us), 2224127
[INSERT], Operations, 276216
[INSERT], AverageLatency(us), 900.1717641266256
[INSERT], MinLatency(us), 137
[INSERT], MaxLatency(us), 2502655
[INSERT], 95thPercentileLatency(us), 792
[INSERT], 99thPercentileLatency(us), 2463
[INSERT], Return=OK, 276216
[INSERT], Return=ERROR, 10
[INSERT-FAILED], Operations, 10
[INSERT-FAILED], AverageLatency(us), 4456857.6
[INSERT-FAILED], MinLatency(us), 4427776
[INSERT-FAILED], MaxLatency(us), 4481023
[INSERT-FAILED], 95thPercentileLatency(us), 4481023
[INSERT-FAILED], 99thPercentileLatency(us), 4481023

我在values.yaml处附加了我的values.yaml。我尝试提供资源-内存和cpu,但没有成功。我也尝试设置

name: WRITE_REQUEST_TIMEOUT_IN_MS
value: "50000"

在values.yaml和template / statefulset.yaml中以不同的组合 我从这里使用头盔图表-helm chart和ycsb cassandra-ycsb

有人可以在这里帮助我吗?如果需要,我可以分享更多详细信息。

0 个答案:

没有答案