Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id C57A0200B5B for ; Fri, 22 Jul 2016 01:34:36 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id C4456160A87; Thu, 21 Jul 2016 23:34:36 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id BDF2F160A73 for ; Fri, 22 Jul 2016 01:34:35 +0200 (CEST) Received: (qmail 87687 invoked by uid 500); 21 Jul 2016 23:34:34 -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 87674 invoked by uid 99); 21 Jul 2016 23:34:34 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 21 Jul 2016 23:34:34 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 0650FC9A7F for ; Thu, 21 Jul 2016 23:34:34 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 3.28 X-Spam-Level: *** X-Spam-Status: No, score=3.28 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=2, KAM_BADIPHTTP=2, NORMAL_HTTP_TO_IP=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd1-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=cloudera-com.20150623.gappssmtp.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id TFYC29Bmx2TU for ; Thu, 21 Jul 2016 23:34:31 +0000 (UTC) Received: from mail-vk0-f46.google.com (mail-vk0-f46.google.com [209.85.213.46]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 827B45FDF7 for ; Thu, 21 Jul 2016 23:34:31 +0000 (UTC) Received: by mail-vk0-f46.google.com with SMTP id w127so135479898vkh.2 for ; Thu, 21 Jul 2016 16:34:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloudera-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=3w2+D5jghxb6oQNteqfh7D6RKIbnCb/PJzsJxtanOWo=; b=dsL7Wc7u+w/8tPbsktFHPom/G2liuBzxtkDTTu0uF8+ek8qzpovIjoNrMBh9zkuUCb zPYjUf3Dpg1RpPkTLVNAoz7IhB67E/N3sPuLdDNABF0KutwEADuRj4dimrOdbpEw6Eo1 Exj4JHboEb6Zzwqkf3TjmIZ+3+wX+wTpnOYCBRBSheAJf+5LW0wVSqK2G06GxLCr/8+E ev69fGdvjYN/mlRl13hrqKl16QhrD6jS8gynNxEaRVrzyGmOEaFMQExlUsH2eyLwByl0 HeI7K/P/U5PRJ2gqh4oWEk5x/QT/0T3gwghmVuyaTCFzr/ErZSBhgov8UZM82A31o62L Qt7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=3w2+D5jghxb6oQNteqfh7D6RKIbnCb/PJzsJxtanOWo=; b=IaHnK/KjNvJXgLFJCW2IyLfAacG/WyCaTv8jPBjo9TgboAT2UNpeG71+9BmMTqS48l 2oZ6h6KjsN+L/nZJaDdcXyjPHd4RX44CcGuiiFeqpDzaTvkaDAm2AOStbKdFnWBCAGpU GkUAthJecN3BRnfWhq6GnKe2ogEY7qRJhVdrROayc1uCnoPpzw1DE3JUp2Fa6iynjOXX 4bBzxwbgtk0QAuaLUVMFix9BRJu8UeR0l+ZUxrhJe4HtgNBKlEhjEbW9DcX9Ekmp4eH3 h3B0S4Z2Tax+bx/kXZr6sn6Xi9y9JV9nTVg/D8uqhgRUrFkWiUiGnoaAgpAJvMHuyyCk r6ew== X-Gm-Message-State: AEkoous+a9TmMBuuqghxiU49xjpPCiIfP/jdD1HzjeLGkjAvWKggGg9COIneDNeCxN2vmk7Dpr+uUrze51dXqjOp X-Received: by 10.176.5.97 with SMTP id 88mr488187uax.26.1469144070144; Thu, 21 Jul 2016 16:34:30 -0700 (PDT) MIME-Version: 1.0 Received: by 10.176.69.166 with HTTP; Thu, 21 Jul 2016 16:34:00 -0700 (PDT) In-Reply-To: References: From: Michael Han Date: Thu, 21 Jul 2016 16:34:00 -0700 Message-ID: Subject: Re: Config options not being loaded? To: UserZooKeeper Content-Type: multipart/alternative; boundary=94eb2c1256a06ce34205382dc229 archived-at: Thu, 21 Jul 2016 23:34:37 -0000 --94eb2c1256a06ce34205382dc229 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable >> using zookeeper only in memory I don't think you can completely disable persistency - ZK will at least write transaction logs and snap shot to disk in any case. There is ZOOKEEPER-866 relates to disable persistency completely for ZK, which is probably what you are looking for ultimately, but that work is not done yet. >> what would you suggest? I think your original config looks OK, in particular: - 'forceSync=3Dno' will make transaction log write async. - Set snapCount to a really large number to disable snap shot as it seems you don't have durable requirement and not care about recovery time. You might also want to clarify / provide more information regarding your use case (e.g. work load type, read heavy or write heavy, etc), and maybe some users here that had similar use cases can provide their insights. On Thu, Jul 21, 2016 at 2:35 PM, Andr=C3=A9 Mantas wrote: > Ok thanks I'll check it out. As for my other question of using zookeeper > only in memory, what would you suggest? > > Thanks for the help so far. > > A 10:18PM Qui, 21 de Jul de 2016, Michael Han > escreveu: > > > I think it is not guaranteed that we can find all configuration options > in > > server logs because ZK may not log all available configuration options. > > Another idea to verify the configuration options are loaded with the > value > > you specified is to examine the Java system properties of the JVM ZK > > process, because all the configuration options are loaded as Java syste= m > > properties. As an example, skipACL will also be presented as > > zookeeper.skipACL property. > > > > On Thu, Jul 21, 2016 at 2:07 PM, Andr=C3=A9 Mantas > > wrote: > > > > > Thanks for the reply. Indeed I was able to see the skip ACL config in > the > > > server log but not any of the other 3 configs. Was it because I > > specified a > > > wrong value for these configs maybe? > > > > > > A 9:56PM Qui, 21 de Jul de 2016, Michael Han > > escreveu: > > > > > > > The fact that 'conf' does not print out all configuration options > > encoded > > > > in zoo.cfg does not necessarily mean these options are not loaded i= n > > ZK. > > > In > > > > face the options 'conf' will print out is pretty limited and you ca= n > > > check > > > > those options in ZooKeeperServerConf.java > > > > < > > > > > > > > > > https://github.com/apache/zookeeper/blob/trunk/src/java/main/org/apache/z= ookeeper/server/ZooKeeperServerConf.java#L26 > > > > >. > > > > It'll be good to make this class up to date with regards to latest > > > > available configuration options in ZK but most if not all > configuration > > > > options could also be validated in server logs (like the skipACL on= e > > > here). > > > > > > > > On Thu, Jul 21, 2016 at 11:55 AM, Andr=C3=A9 Mantas < > andremantas7@gmail.com > > > > > > > wrote: > > > > > > > > > Follow up: > > > > > With start-foreground I'm able to see that skipACL=3Dyes was > effective > > > > (full > > > > > output in the end of the email): > > > > > > > > > > 2016-07-21 20:36:19,433 [myid:] - INFO > [main:PrepRequestProcessor@87 > > ] > > > - > > > > > zookeeper.skipACL=3D=3D"yes", ACL checks will be skipped > > > > > > > > > > What is the problem with the other config values? I'm trying to > boost > > > > > performance by disabling the persistency of zookeeper. I'm only > > > > interested > > > > > in using zookeeper in memory database (no need for data persisten= cy > > > after > > > > > reboot). > > > > > > > > > > Any advice on how to achieve this? > > > > > > > > > > Thanks > > > > > > > > > > ----- > > > > > > > > > > ~/amantas/zookeeper-3.4.8# ./bin/zkServer.sh start-foreground > > > > > ZooKeeper JMX enabled by default > > > > > Using config: /root/amantas/zookeeper-3.4.8/bin/../conf/zoo.cfg > > > > > 2016-07-21 20:36:15,060 [myid:] - INFO [main:QuorumPeerConfig@10= 3 > ] > > - > > > > > Reading configuration from: > > > > > /root/amantas/zookeeper-3.4.8/bin/../conf/zoo.cfg > > > > > 2016-07-21 20:36:15,069 [myid:] - INFO > > [main:DatadirCleanupManager@78 > > > ] > > > > - > > > > > autopurge.snapRetainCount set to 3 > > > > > 2016-07-21 20:36:15,069 [myid:] - INFO > > [main:DatadirCleanupManager@79 > > > ] > > > > - > > > > > autopurge.purgeInterval set to 0 > > > > > 2016-07-21 20:36:15,069 [myid:] - INFO > > [main:DatadirCleanupManager@101 > > > ] > > > > - > > > > > Purge task is not scheduled. > > > > > 2016-07-21 20:36:15,071 [myid:] - WARN [main:QuorumPeerMain@113] > - > > > > Either > > > > > no config or no quorum defined in config, running in standalone > mode > > > > > 2016-07-21 20:36:15,093 [myid:] - INFO [main:QuorumPeerConfig@10= 3 > ] > > - > > > > > Reading configuration from: > > > > > /root/amantas/zookeeper-3.4.8/bin/../conf/zoo.cfg > > > > > 2016-07-21 20:36:15,094 [myid:] - INFO > [main:ZooKeeperServerMain@95 > > ] > > > - > > > > > Starting server > > > > > 2016-07-21 20:36:15,105 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:zookeeper.version=3D3.4.8--1, built on 02/06/2016 03:= 18 > GMT > > > > > 2016-07-21 20:36:15,105 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:host.name=3Dt8.wan > > > > > 2016-07-21 20:36:15,105 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:java.version=3D1.8.0_91 > > > > > 2016-07-21 20:36:15,105 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:java.vendor=3DOracle Corporation > > > > > 2016-07-21 20:36:15,105 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:java.home=3D/usr/lib/jvm/java-8-oracle/jre > > > > > 2016-07-21 20:36:15,106 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > > > > > > > > > > > > > > > > environment:java.class.path=3D/root/amantas/zookeeper-3.4.8/bin/../build/= classes:/root/amantas/zookeeper-3.4.8/bin/../build/lib/*.jar:/root/amantas/= zookeeper-3.4.8/bin/../lib/slf4j-log4j12-1.6.1.jar:/root/amantas/zookeeper-= 3.4.8/bin/../lib/slf4j-api-1.6.1.jar:/root/amantas/zookeeper-3.4.8/bin/../l= ib/netty-3.7.0.Final.jar:/root/amantas/zookeeper-3.4.8/bin/../lib/log4j-1.2= .16.jar:/root/amantas/zookeeper-3.4.8/bin/../lib/jline-0.9.94.jar:/root/ama= ntas/zookeeper-3.4.8/bin/../zookeeper-3.4.8.jar:/root/amantas/zookeeper-3.4= .8/bin/../src/java/lib/*.jar:/root/amantas/zookeeper-3.4.8/bin/../conf: > > > > > 2016-07-21 20:36:15,106 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > > > > > > > > > > > > > > > > environment:java.library.path=3D/usr/java/packages/lib/amd64:/usr/lib64:/= lib64:/lib:/usr/lib > > > > > 2016-07-21 20:36:15,106 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:java.io.tmpdir=3D/tmp > > > > > 2016-07-21 20:36:15,106 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:java.compiler=3D > > > > > 2016-07-21 20:36:15,108 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:os.name=3DLinux > > > > > 2016-07-21 20:36:15,108 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:os.arch=3Damd64 > > > > > 2016-07-21 20:36:15,108 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:os.version=3D4.4.0-21-generic > > > > > 2016-07-21 20:36:15,109 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:user.name=3Droot > > > > > 2016-07-21 20:36:15,109 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:user.home=3D/root > > > > > 2016-07-21 20:36:15,109 [myid:] - INFO [main:Environment@100] - > > > Server > > > > > environment:user.dir=3D/root/amantas/zookeeper-3.4.8 > > > > > 2016-07-21 20:36:15,118 [myid:] - INFO [main:ZooKeeperServer@787= ] > - > > > > > tickTime set to 2000 > > > > > 2016-07-21 20:36:15,118 [myid:] - INFO [main:ZooKeeperServer@796= ] > - > > > > > minSessionTimeout set to -1 > > > > > 2016-07-21 20:36:15,118 [myid:] - INFO [main:ZooKeeperServer@805= ] > - > > > > > maxSessionTimeout set to -1 > > > > > 2016-07-21 20:36:15,132 [myid:] - INFO > [main:NIOServerCnxnFactory@89 > > ] > > > - > > > > > binding to port 0.0.0.0/0.0.0.0:2181 > > > > > 2016-07-21 20:36:19,433 [myid:] - INFO > [main:PrepRequestProcessor@87 > > ] > > > - > > > > > zookeeper.skipACL=3D=3D"yes", ACL checks will be skipped > > > > > > > > > > Andr=C3=A9 Mantas escreveu no dia quinta= , > > > 21/07/2016 > > > > > =C3=A0s > > > > > 03:28: > > > > > > > > > > > Hi all. > > > > > > > > > > > > I'm trying to experiment with some config options found in > > > > > > > > > > > > > > > > > > > > > https://zookeeper.apache.org/doc/r3.4.8/zookeeperAdmin.html#sc_configurat= ion > > > > > but > > > > > > they are not being loaded/used by the zookeeper server. > > > > > > > > > > > > I've modified my config file 'zoo.cfg' to: > > > > > > > > > > > > # The number of milliseconds of each tick > > > > > > tickTime=3D2000 > > > > > > # The number of ticks that the initial > > > > > > # synchronization phase can take > > > > > > initLimit=3D10 > > > > > > # The number of ticks that can pass between > > > > > > # sending a request and getting an acknowledgement > > > > > > syncLimit=3D5 > > > > > > # the directory where the snapshot is stored. > > > > > > # do not use /tmp for storage, /tmp here is just > > > > > > # example sakes. > > > > > > dataDir=3D/root/amantas/zookeeper-3.4.8/data > > > > > > # the port at which the clients will connect > > > > > > clientPort=3D2181 > > > > > > # Requires updates to be synced to media of the transaction log > > > before > > > > > > finishing processing the update. > > > > > > # If this option is set to no, ZooKeeper will not require updat= es > > to > > > be > > > > > > synced to the media. > > > > > > forceSync=3Dno > > > > > > # Skips ACL checks. This results in a boost in throughput, but > > opens > > > up > > > > > > full access to the data tree to everyone. > > > > > > skipACL=3Dyes > > > > > > # The observers now log transaction and write snapshot to disk = by > > > > default > > > > > > like the participants. > > > > > > # This reduces the recovery time of the observers on restart. > > > > > > # Set to "false" to disable this feature. Default is "true" > > > > > > syncEnabled=3Dfalse > > > > > > # ZooKeeper logs transactions to a transaction log. > > > > > > # After snapCount transactions are written to a log file a > snapshot > > > is > > > > > > started and a new transaction log file is created. > > > > > > # The default snapCount is 100,000 > > > > > > snapCount=3D1000000 > > > > > > > > > > > > Then, restarted the zookeeper server: > > > > > > > > > > > > ~/amantas/zookeeper-3.4.8# ./bin/zkServer.sh stop > > > > > > ZooKeeper JMX enabled by default > > > > > > Using config: /root/amantas/zookeeper-3.4.8/bin/../conf/zoo.cfg > > > > > > Stopping zookeeper ... STOPPED > > > > > > > > > > > > ~/amantas/zookeeper-3.4.8# ./bin/zkServer.sh start > > > > > > ZooKeeper JMX enabled by default > > > > > > Using config: /root/amantas/zookeeper-3.4.8/bin/../conf/zoo.cfg > > > > > > Starting zookeeper ... STARTED > > > > > > > > > > > > However, when listing the server configuration I don't see some > of > > > the > > > > > > config params: > > > > > > > > > > > > ~/amantas/zookeeper-3.4.8# nc localhost 2181 > > > > > > conf > > > > > > clientPort=3D2181 > > > > > > dataDir=3D/root/amantas/zookeeper-3.4.8/data/version-2 > > > > > > dataLogDir=3D/root/amantas/zookeeper-3.4.8/data/version-2 > > > > > > tickTime=3D2000 > > > > > > maxClientCnxns=3D60 > > > > > > minSessionTimeout=3D4000 > > > > > > maxSessionTimeout=3D40000 > > > > > > serverId=3D0 > > > > > > > > > > > > What am I doing wrong? > > > > > > > > > > > > Thanks in advance! > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > Cheers > > > > Michael. > > > > > > > > > > > > > > > -- > > Cheers > > Michael. > > > --=20 Cheers Michael. --94eb2c1256a06ce34205382dc229--