Return-Path: X-Original-To: apmail-zookeeper-user-archive@www.apache.org Delivered-To: apmail-zookeeper-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 4B0DD1103B for ; Fri, 5 Sep 2014 13:47:56 +0000 (UTC) Received: (qmail 1222 invoked by uid 500); 5 Sep 2014 13:47:55 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 1179 invoked by uid 500); 5 Sep 2014 13:47:55 -0000 Mailing-List: contact user-help@zookeeper.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@zookeeper.apache.org Delivered-To: mailing list user@zookeeper.apache.org Received: (qmail 1165 invoked by uid 99); 5 Sep 2014 13:47:55 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 05 Sep 2014 13:47:55 +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 (nike.apache.org: domain of fpjunqueira@yahoo.com designates 98.139.213.74 as permitted sender) Received: from [98.139.213.74] (HELO nm26-vm0.bullet.mail.bf1.yahoo.com) (98.139.213.74) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 05 Sep 2014 13:47:27 +0000 Received: from [98.139.212.153] by nm26.bullet.mail.bf1.yahoo.com with NNFMP; 05 Sep 2014 13:47:25 -0000 Received: from [98.139.212.249] by tm10.bullet.mail.bf1.yahoo.com with NNFMP; 05 Sep 2014 13:47:25 -0000 Received: from [127.0.0.1] by omp1058.mail.bf1.yahoo.com with NNFMP; 05 Sep 2014 13:47:25 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 499349.26666.bm@omp1058.mail.bf1.yahoo.com Received: (qmail 43049 invoked by uid 60001); 5 Sep 2014 13:47:25 -0000 X-YMail-OSG: EEC1AY4VM1ndImIakzN9V.OaA0mHAEeRxqaaX69a74TUljN jheb9ZrrdH9KmfvfWyCdSfqo2sa.GHj4iHxPik8RBkpo1zjSJMPmdc2ygwmK TsXGKFLICuPxr54LmcTeBkE7v6pmd_KhtrBWLWXcb53hiRyKAkatzHlUEw8l vjOC._sA.5jMhShFllY5ztjt_OCGKtql1RcZ7ln97sgJwAos0gIvNnJQIVJF yacHwQkliKl_22fKOLLTQXoL2U61U.MkVmPOb_8Oi6Gep8Qcd2UwhU2OlO8q t_DM7JVBy.NYu9yF2THHuQS2FKDk3yaYPjQTKZJgcFdl4zVlND1poKiAOfc2 G2nZIur9fofkxgx4tCodJNTN7IFtuhLjSloOi6.x0JuoyangDv239lVjjItm 2IiRb1Gj0Pt1yuTEY7B70Bv3HmyIL3_nYLJ_.5cyhYCXykMHBWbz6scgE3hf qpftlGFTD9KMxjzOU_xPn65Bw8NnKdAATAhEWZrzlsSiV99EKdcUmLnaR5xa 1tcYWU78IqFtb3J6pujxvWYEW64akFz2kVQfHHriIPoAjC45ybxJ_Ae.sT88 hiHW5xIDl8sMVWv7WF2pb3WPLEg6.sluBDqa5wOR1aYCye8beeIsM Received: from [167.220.196.145] by web142304.mail.bf1.yahoo.com via HTTP; Fri, 05 Sep 2014 06:47:25 PDT X-Rocket-MIMEInfo: 002.001,QnJpYW4sCgpIb3cgbXVjaCBzdGF0ZSBhcmUgeW91IHN0b3JpbmcgaW4gWks_IENhbiB5b3UgY2hlY2sgdGhlIHNpemUgb2YgdGhlIHNuYXBzaG90cz8KCk9uZSBjb21tb24gcHJvYmxlbSB3aGVuIGZvbGtzIGFyZSB0ZXN0aW5nIGlzIHRoYXQgdGhleSBmb3JnZXQgdG8gZGVsZXRlIHRoZSBkYXRhIGZyb20gcHJldmlvdXMgdGVzdHMsIHNvIHRoZSBzdGF0ZSBrZWVwcyBhY2N1bXVsYXRpbmcgYW5kIHRoZSBzZXJ2ZXIga2VlcHMgY3Jhc2hpbmcgYmVjYXVzZSB0aGUgc3RhdGUgaXMgdG9vIGxhcmdlLgoKQWxzbywBMAEBAQE- X-Mailer: YahooMailWebService/0.8.201.700 References: <5409B95D.7070807@etinternational.com> Message-ID: <1409924845.82416.YahooMailNeo@web142304.mail.bf1.yahoo.com> Date: Fri, 5 Sep 2014 06:47:25 -0700 From: Flavio Junqueira Reply-To: Flavio Junqueira Subject: Re: Consistently running out of heap space To: "user@zookeeper.apache.org" In-Reply-To: <5409B95D.7070807@etinternational.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="2138815387-1226932479-1409924845=:82416" X-Virus-Checked: Checked by ClamAV on apache.org --2138815387-1226932479-1409924845=:82416 Content-Type: text/plain; charset=us-ascii Brian, How much state are you storing in ZK? Can you check the size of the snapshots? One common problem when folks are testing is that they forget to delete the data from previous tests, so the state keeps accumulating and the server keeps crashing because the state is too large. Also, consider trying 3.4.5 just to see if it is a problem with 3.4.6 alone. -Flavio On Friday, September 5, 2014 2:23 PM, Brian C. Huffman wrote: > > >We're running the latest version of the stable 3.4 branch (3.4.6) and >have been consistently having problems running out of heap space. > >We're running a single server (redundancy isn't a concern at this point) >and I've tried the defaults (which seems to use Java's default heap of >8GB) as well as limiting to 3GB. Either way the Zookeeper server >eventually dies. With larger heap size it seems to take longer to die. > >Here's the latest trace: >2014-09-05 00:51:11,419 [myid:] - ERROR >[SyncThread:0:SyncRequestProcessor@183] - Severe unrecoverable error, >exiting >java.lang.OutOfMemoryError: Java heap space > at java.util.Arrays.copyOf(Arrays.java:2271) > at java.io.ByteArrayOutputStream.grow(ByteArrayOutputStream.java:113) > at >java.io.ByteArrayOutputStream.ensureCapacity(ByteArrayOutputStream.java:93) > at java.io.ByteArrayOutputStream.write(ByteArrayOutputStream.java:140) > at java.io.DataOutputStream.write(DataOutputStream.java:107) > at java.io.FilterOutputStream.write(FilterOutputStream.java:97) > at >org.apache.jute.BinaryOutputArchive.writeBuffer(BinaryOutputArchive.java:119) > at org.apache.zookeeper.txn.Txn.serialize(Txn.java:49) > at >org.apache.jute.BinaryOutputArchive.writeRecord(BinaryOutputArchive.java:123) > at org.apache.zookeeper.txn.MultiTxn.serialize(MultiTxn.java:44) > at >org.apache.zookeeper.server.persistence.Util.marshallTxnEntry(Util.java:263) > at >org.apache.zookeeper.server.persistence.FileTxnLog.append(FileTxnLog.java:216) > at >org.apache.zookeeper.server.persistence.FileTxnSnapLog.append(FileTxnSnapLog.java:314) > at org.apache.zookeeper.server.ZKDatabase.append(ZKDatabase.java:476) > at >org.apache.zookeeper.server.SyncRequestProcessor.run(SyncRequestProcessor.java:140) >2014-09-05 00:51:07,866 [myid:] - WARN >[NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxn@357] - caught >end of stream exception >EndOfStreamException: Unable to read additional data from client >sessionid 0x14837ac98960071, likely client has closed socket > at >org.apache.zookeeper.server.NIOServerCnxn.doIO(NIOServerCnxn.java:228) > at >org.apache.zookeeper.server.NIOServerCnxnFactory.run(NIOServerCnxnFactory.java:208) > at java.lang.Thread.run(Thread.java:745) > >Here's my configuration: >[user@xyz conf]$ grep -v '^#' zoo.cfg >tickTime=2000 >initLimit=10 >syncLimit=5 >dataDir=/usr/local/var/zookeeper >clientPort=2181 >autopurge.snapRetainCount=3 >autopurge.purgeInterval=1 > >Can anyone suggest what the issue could be? > >Thanks, >Brian > > > > --2138815387-1226932479-1409924845=:82416--