From user-return-21097-apmail-cassandra-user-archive=cassandra.apache.org@cassandra.apache.org Mon Sep 26 21:05:19 2011 Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id CAC20761B for ; Mon, 26 Sep 2011 21:05:19 +0000 (UTC) Received: (qmail 23429 invoked by uid 500); 26 Sep 2011 21:05:17 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 23395 invoked by uid 500); 26 Sep 2011 21:05:17 -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 23385 invoked by uid 99); 26 Sep 2011 21:05:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 26 Sep 2011 21:05:17 +0000 X-ASF-Spam-Status: No, hits=1.8 required=5.0 tests=FREEMAIL_FROM,HTML_FONT_FACE_BAD,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of baskar.duraikannu.db@gmail.com designates 209.85.212.44 as permitted sender) Received: from [209.85.212.44] (HELO mail-vw0-f44.google.com) (209.85.212.44) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 26 Sep 2011 21:05:09 +0000 Received: by vws5 with SMTP id 5so7350908vws.31 for ; Mon, 26 Sep 2011 14:04:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:mime-version:content-type:subject:date:in-reply-to:to :references:message-id:x-mailer; bh=cyvrzJcEOaCvINQu5RLnenp6cqi38oKHuXe59LFs/Gc=; b=atMy7d+QD/j8wzAnFLoQIdwoBfL4HSy3tj9yNsRXxYB7GV5aBRCBvXAOurs0IaWAtu PCmCNaOH/g5kckFFzFcaAtdzTqlUt2A0zd3eMujuFqbAS0g+OrCfWCIt9dVDuLYj0KC+ 6E5Q7iLKB3tJab+TQxY1SA+yeS1ndKbRoUELg= Received: by 10.52.36.212 with SMTP id s20mr2826735vdj.31.1317071088749; Mon, 26 Sep 2011 14:04:48 -0700 (PDT) Received: from bdmacbookpro.us.ad.irmc.com ([66.246.173.34]) by mx.google.com with ESMTPS id jo8sm18380871vdb.20.2011.09.26.14.04.47 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 26 Sep 2011 14:04:48 -0700 (PDT) From: Baskar Duraikannu Mime-Version: 1.0 (Apple Message framework v1244.3) Content-Type: multipart/alternative; boundary="Apple-Mail=_3EA5839E-054E-41BC-B9FB-33F0E00B5D90" Subject: Re: Thrift CPU Usage Date: Mon, 26 Sep 2011 17:04:46 -0400 In-Reply-To: <0271F27E-CCCE-4F43-BB22-4BF98848B194@thelastpickle.com> To: user@cassandra.apache.org References: <4BE0A38A-E7C9-4E55-B4DC-05CD70E316DB@gmail.com> <0271F27E-CCCE-4F43-BB22-4BF98848B194@thelastpickle.com> Message-Id: X-Mailer: Apple Mail (2.1244.3) X-Virus-Checked: Checked by ClamAV on apache.org --Apple-Mail=_3EA5839E-054E-41BC-B9FB-33F0E00B5D90 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Aaron =46rom the CPU samples report. Here is the parts of the CPU samples = report (-Xrunhprof:cpu=3Dsamples, depth=3D4). =20 TRACE 300668: = java.net.SocketInputStream.socketRead0(SocketInputStream.java:Unknown = line) java.net.SocketInputStream.read(SocketInputStream.java:129) = org.apache.thrift.transport.TIOStreamTransport.read(TIOStreamTransport.jav= a:127) = org.apache.thrift.transport.TTransport.readAll(TTransport.java:84) TRACE 300310: = java.net.PlainSocketImpl.socketAccept(PlainSocketImpl.java:Unknown line) java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408) java.net.ServerSocket.implAccept(ServerSocket.java:462) java.net.ServerSocket.accept(ServerSocket.java:430) TRACE 300639: = sun.nio.ch.ServerSocketChannelImpl.accept0(ServerSocketChannelImpl.java:Un= known line) = sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.java:152= ) = sun.nio.ch.ServerSocketAdaptor.accept(ServerSocketAdaptor.java:84) = org.apache.cassandra.net.MessagingService$SocketThread.run(MessagingServic= e.java:617) TRACE 300670: = java.net.SocketOutputStream.socketWrite0(SocketOutputStream.java:Unknown = line) = java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92) java.net.SocketOutputStream.write(SocketOutputStream.java:136) = org.apache.thrift.transport.TIOStreamTransport.write(TIOStreamTransport.ja= va:145) TRACE 301122: java.lang.Object.notify(Object.java:Unknown line) = org.apache.cassandra.utils.SimpleCondition.signal(SimpleCondition.java:62)= = org.apache.cassandra.service.ReadCallback.response(ReadCallback.java:169) = org.apache.cassandra.service.StorageProxy$LocalReadRunnable.runMayThrow(St= orageProxy.java rank self accum count trace method 1 74.00% 74.00% 160934 300668 java.net.SocketInputStream.socketRead0 2 14.85% 88.85% 32302 300310 java.net.PlainSocketImpl.socketAccept 3 3.67% 92.52% 7990 300639 = sun.nio.ch.ServerSocketChannelImpl.accept0 4 1.90% 94.43% 4142 300670 = java.net.SocketOutputStream.socketWrite0 5 0.79% 95.22% 1716 301122 java.lang.Object.notify -- Thanks Baskar Duraikannu On Sep 26, 2011, at 4:55 PM, aaron morton wrote: > How are you deciding what is thrift ? Thrift is used to handle = connections and serialize / de-serialize off the wire. >=20 > Cheers >=20 >=20 >=20 > ----------------- > Aaron Morton > Freelance Cassandra Developer > @aaronmorton > http://www.thelastpickle.com >=20 > On 27/09/2011, at 2:32 AM, Baskar Duraikannu wrote: >=20 >> Hello -=20 >>=20 >> I have been running read tests on Cassandra using "stress" tool. I = have been noticing that thrift seems to be taking lot of CPU over 70% = when I look at the "CPU samples" report. Is this normal? =20 >>=20 >> CPU usage seems to go down by 5 to 10% when I change the RPC from = "sync" to "async". Is this normal?=20 >>=20 >> I am running Cassandra 0.8.4 on Cent OS 5.6 ( Kernel 2.6.18.238) and = Oracle JVM.=20 >>=20 >> -=20 >> Thanks >> Baskar Duraikannu >=20 --Apple-Mail=_3EA5839E-054E-41BC-B9FB-33F0E00B5D90 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=us-ascii RACE 300668:
= java.net.SocketInputStream.socketRead0(SocketInputStream.java:Unkno= wn line)
= java.net.SocketInputStream.read(SocketInputStream.java:129)
= org.apache.thrift.transport.TIOStreamTransport.read(TIOStreamTransp= ort.java:127)
= org.apache.thrift.transport.TTransport.readAll(TTransport.java:84)<= br>TRACE 300310:
= java.net.PlainSocketImpl.socketAccept(PlainSocketImpl.java:Unknown = line)
= java.net.PlainSocketImpl.accept(PlainSocketImpl.java:408)
= java.net.ServerSocket.implAccept(ServerSocket.java:462)
= java.net.ServerSocket.accept(ServerSocket.java:430)
TRACE = 300639:
= sun.nio.ch.ServerSocketChannelImpl.accept0(ServerSocketChannelImpl.= java:Unknown line)
= sun.nio.ch.ServerSocketChannelImpl.accept(ServerSocketChannelImpl.j= ava:152)
= sun.nio.ch.ServerSocketAdaptor.accept(ServerSocketAdaptor.java:84)<= br> = org.apache.cassandra.net.MessagingService$SocketThread.run(Messagin= gService.java:617)
TRACE 300670:
= java.net.SocketOutputStream.socketWrite0(SocketOutputStream.java:Un= known line)
= java.net.SocketOutputStream.write(SocketOutputStream.java:136)
<= span class=3D"Apple-tab-span" style=3D"white-space: pre; "> = org.apache.thrift.transport.TIOStreamTransport.write(TIOStreamTrans= port.java:145)
TRACE 301122:
= java.lang.Object.notify(Object.java:Unknown line)
= org.apache.cassandra.utils.SimpleCondition.signal(SimpleCondition.j= ava:62)
= org.apache.cassandra.service.ReadCallback.response(ReadCallback.jav= a:169)
= org.apache.cassandra.service.StorageProxy$LocalReadRunnable.runMayT= hrow(StorageProxy.java


rank   self =  accum   count trace method
   1 74.00% 74.00% =  160934 300668 java.net.SocketInputStream.socketRead0
  =  2 14.85% 88.85%   32302 300310 = java.net.PlainSocketImpl.socketAccept
   3  3.67% = 92.52%    7990 300639 = sun.nio.ch.ServerSocketChannelImpl.accept0
   4  1.90% = 94.43%    4142 300670 = java.net.SocketOutputStream.socketWrite0
   5  0.79% = 95.22%    1716 301122 = java.lang.Object.notify

--
T= hanks
Baskar Duraikannu

On Sep 26, 2011, at = 4:55 PM, aaron morton wrote:

How = are you deciding what is thrift ? Thrift is used to handle connections = and serialize  / de-serialize off the = wire.

Cheers



-----------------
Aaron = Morton
Freelance Cassandra Developer
@aaronmorton
http://www.thelastpickle.com
=
On 27/09/2011, at 2:32 AM, Baskar Duraikannu = wrote:

Hello - =

I have been running read tests on Cassandra using "stress" = tool.  I have been noticing that thrift seems to be taking lot of = CPU over 70% when I look at the "CPU samples" report. Is this normal? =  

CPU usage seems = to go down by 5 to 10% when I change the RPC from "sync" to "async". =  Is this normal?

I am running = Cassandra 0.8.4 on Cent OS 5.6 ( Kernel 2.6.18.238) and Oracle JVM. =

-
Thanks
Baskar = Duraikannu


= --Apple-Mail=_3EA5839E-054E-41BC-B9FB-33F0E00B5D90--