Return-Path: Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: (qmail 91274 invoked from network); 7 Apr 2011 13:22:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 7 Apr 2011 13:22:29 -0000 Received: (qmail 85626 invoked by uid 500); 7 Apr 2011 13:22:26 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 85592 invoked by uid 500); 7 Apr 2011 13:22:26 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 85584 invoked by uid 99); 7 Apr 2011 13:22:26 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Apr 2011 13:22:26 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [208.113.200.5] (HELO homiemail-a54.g.dreamhost.com) (208.113.200.5) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 07 Apr 2011 13:22:21 +0000 Received: from homiemail-a54.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a54.g.dreamhost.com (Postfix) with ESMTP id 606303A4061 for ; Thu, 7 Apr 2011 06:22:00 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=thelastpickle.com; h=from :mime-version:content-type:subject:date:in-reply-to:to :references:message-id; q=dns; s=thelastpickle.com; b=MtEV8i8t0G bo8C10mSf1wI6wQzha64jSWKNzu0zhRSrofd4qquk6aTU1treIyHZAA4tKC3qXdP q5S53Cqhj/gskSgHvCbhY49opzHkSNyJheqnu8PBopC32DKWOJp6LDy5opKsbFB1 Z2K2AMaJfJ7OUgwjsMa2uevXJgnGttTIo= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=thelastpickle.com; h=from :mime-version:content-type:subject:date:in-reply-to:to :references:message-id; s=thelastpickle.com; bh=RIVLWeCfLjJWset1 aYK1Ubphp+M=; b=QfcGk3JXj+HjY8z57VikzC0Y+m3WXdVC2XiIzzXvrKAYcFaM 6kUT1Bs7r+DF/NmxrXT8X94m31iPz7F/OzCh5j89u/+RW4Ggvg8mLOwKC76oDHl8 bdYsHZzFbmgCQGMk3uCmNrUOd8Ud2mjon3fcRa0M5k9lXlzqpfneXMtZqvA= Received: from [192.168.0.104] (CPE-58-175-240-72.hdcz1.win.bigpond.net.au [58.175.240.72]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: aaron@thelastpickle.com) by homiemail-a54.g.dreamhost.com (Postfix) with ESMTPSA id 6B8FB3A4058 for ; Thu, 7 Apr 2011 06:21:59 -0700 (PDT) From: aaron morton Mime-Version: 1.0 (Apple Message framework v1082.1) Content-Type: multipart/alternative; boundary=Apple-Mail-79--394713804 Subject: Re: Stress tests failed with secondary index Date: Thu, 7 Apr 2011 23:21:56 +1000 In-Reply-To: To: user@cassandra.apache.org References: Message-Id: <2C459DCC-79F7-49F4-B699-1636B95218E4@thelastpickle.com> X-Mailer: Apple Mail (2.1082.1) --Apple-Mail-79--394713804 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Can you turn the logging up to DEBUG level and look for a message from = CassandraServer that says "... timed out" ? Also check the thread pool stats "nodetool tpstats" to see if the node = is keeping up.=20 =20 Aaron On 7 Apr 2011, at 13:43, Sheng Chen wrote: > Thank you Aaron. >=20 > It does not seem to be an overload problem. >=20 > I have 16 cores and 48G ram on the single node, and I reduced the = concurrent threads to be 1.=20 > Still, it just suddenly dies of a timeout, while the cpu, ram, disk = load are below 10% and write latency is about 0.5ms for the past 10 = minutes which is really fast. >=20 > No logs of dropped messages are found. >=20 >=20 >=20 >=20 >=20 > 2011/4/7 aaron morton > TimedOutException means that the less than CL number of nodes = responded to the coordinator before the rpc_timeout. >=20 > So it was overloaded. Which makes sense when you say it only happens = with secondary indexes. Consider things like > - reducing the throughput > - reducing the number of clients > - ensuring the clients are connecting to all nodes in the cluster. >=20 > You will probably find some logs about dropped messages on some nodes. > Aaron >=20 > On 6 Apr 2011, at 20:39, Sheng Chen wrote: >=20 > > I used py_stress module to insert 10m test data with a secondary = index. > > I got the following exceptions. > > > > # python stress.py -d xxx -o insert -n 10000000 -c 5 -s 34 -C 5 -x = keys > > total,interval_op_rate,interval_key_rate,avg_latency,elapsed_time > > 265322,26532,26541,0.00186140829433,10 > > 630300,36497,36502,0.00129331431204,20 > > 986781,35648,35640,0.0013310986218,30 > > 1332190,34540,34534,0.00135942295893,40 > > 1473578,14138,14138,0.00142941070007,50 > > Process Inserter-38: > > Traceback (most recent call last): > > File = "/usr/lib64/python2.4/site-packages/multiprocessing/process.py", line = 237, in _bootstrap > > self.run() > > File "stress.py", line 242, in run > > self.cclient.batch_mutate(cfmap, consistency) > > File = "/root/apache-cassandra-0.7.4-src/interface/thrift/gen-py/cassandra/Cassan= dra.py", line 784, in batch_mutate > > TimedOutException: TimedOutException(args=3D()) > > self.run() > > File "stress.py", line 242, in run > > self.recv_batch_mutate() > > File = "/root/apache-cassandra-0.7.4-src/interface/thrift/gen-py/cassandra/Cassan= dra.py", line 810, in recv_batch_mutate > > raise result.te > > > > > > Tests without secondary index is ok at about 40k ops/sec. > > > > There is a `GC for ParNew` for about 200ms taking place every = second. Does it matter? > > The same gc for about 400ms happens every 2 seconds, which does not = hurt the inserts without secondary index. > > > > Thanks in advance for any advice. > > > > Sheng >=20 >=20 --Apple-Mail-79--394713804 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset=us-ascii
Can you turn the logging up to DEBUG level and look for a message from CassandraServer that says "... timed out" ?

Also check the thread pool stats "nodetool tpstats" to see if the node is keeping up. 
 
Aaron

On 7 Apr 2011, at 13:43, Sheng Chen wrote:

Thank you Aaron.

It does not seem to be an overload problem.

I have 16 cores and 48G ram on the single node, and I reduced the concurrent threads to be 1. 
Still, it just suddenly dies of a timeout, while the cpu, ram, disk load are below 10% and write latency is about 0.5ms for the past 10 minutes which is really fast.

No logs of dropped messages are found.





2011/4/7 aaron morton <aaron@thelastpickle.com>
TimedOutException means that the less than CL number of nodes responded to the coordinator before the rpc_timeout.

So it was overloaded. Which makes sense when you say it only happens with secondary indexes. Consider things like
- reducing the throughput
- reducing the number of clients
- ensuring the clients are connecting to all nodes in the cluster.

You will probably find some logs about dropped messages on some nodes.
Aaron

On 6 Apr 2011, at 20:39, Sheng Chen wrote:

> I used py_stress module to insert 10m test data with a secondary index.
> I got the following exceptions.
>
> # python stress.py -d xxx -o insert -n 10000000 -c 5 -s 34 -C 5 -x keys
> total,interval_op_rate,interval_key_rate,avg_latency,elapsed_time
> 265322,26532,26541,0.00186140829433,10
> 630300,36497,36502,0.00129331431204,20
> 986781,35648,35640,0.0013310986218,30
> 1332190,34540,34534,0.00135942295893,40
> 1473578,14138,14138,0.00142941070007,50
> Process Inserter-38:
> Traceback (most recent call last):
>   File "/usr/lib64/python2.4/site-packages/multiprocessing/process.py", line 237, in _bootstrap
>     self.run()
>   File "stress.py", line 242, in run
>     self.cclient.batch_mutate(cfmap, consistency)
>   File "/root/apache-cassandra-0.7.4-src/interface/thrift/gen-py/cassandra/Cassandra.py", line 784, in batch_mutate
> TimedOutException: TimedOutException(args=())
>     self.run()
>   File "stress.py", line 242, in run
>     self.recv_batch_mutate()
>   File "/root/apache-cassandra-0.7.4-src/interface/thrift/gen-py/cassandra/Cassandra.py", line 810, in recv_batch_mutate
>     raise result.te
>
>
> Tests without secondary index is ok at about 40k ops/sec.
>
> There is a `GC for ParNew` for about 200ms taking place every second. Does it matter?
> The same gc for about 400ms happens every 2 seconds, which does not hurt the inserts without secondary index.
>
> Thanks in advance for any advice.
>
> Sheng



--Apple-Mail-79--394713804--