From user-return-21056-apmail-couchdb-user-archive=couchdb.apache.org@couchdb.apache.org Fri Jun 1 20:56:54 2012 Return-Path: X-Original-To: apmail-couchdb-user-archive@www.apache.org Delivered-To: apmail-couchdb-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 5115592E0 for ; Fri, 1 Jun 2012 20:56:54 +0000 (UTC) Received: (qmail 98618 invoked by uid 500); 1 Jun 2012 20:56:52 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 98537 invoked by uid 500); 1 Jun 2012 20:56:52 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 98529 invoked by uid 99); 1 Jun 2012 20:56:52 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Jun 2012 20:56:52 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of tisdall@gmail.com designates 209.85.212.182 as permitted sender) Received: from [209.85.212.182] (HELO mail-wi0-f182.google.com) (209.85.212.182) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Jun 2012 20:56:46 +0000 Received: by wibhm6 with SMTP id hm6so752882wib.5 for ; Fri, 01 Jun 2012 13:56:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=tb4e9lYpwXAmetPH4EajAup3qO9X4OnXTKbTpu3GuU8=; b=GxAQ8BchrBk4Z/rWFBzHWEwrDDKChsdivbEfbgouB1rK5ixrcF7w6WEMzzXyOiRIB9 ToDN6aDFICH49cgiRBP/JozG+4JPMx9vfqgF49AnpOqdy45YEj6Af9YrBfACJfulvEOW YNqd3SnQjtNkBlo1Fs/vYKyK8IrgiqYF1HsAUXHn83wYIWtB8UpVOx1JfTz2r9VYBxql REzgQrW807i5+I5AU5aM/NWctA9peXL4/5LcOq/HQo0F+xv+mf75vV8oBtNE3qBYYPEF s4MIJKGxlErrVmCj1Thd9UOLSuBT9aPVqOB4FiH+16s+IjzOsFTwMMOaesweFnmhXKDJ 0t8w== MIME-Version: 1.0 Received: by 10.216.30.213 with SMTP id k63mr3255486wea.59.1338584185793; Fri, 01 Jun 2012 13:56:25 -0700 (PDT) Received: by 10.216.90.77 with HTTP; Fri, 1 Jun 2012 13:56:25 -0700 (PDT) In-Reply-To: References: Date: Fri, 1 Jun 2012 16:56:25 -0400 Message-ID: Subject: Re: local.ini settings not taking precedence From: Tim Tisdall To: user@couchdb.apache.org Content-Type: multipart/alternative; boundary=0016e6ddab60e56ce104c16f6a5b --0016e6ddab60e56ce104c16f6a5b Content-Type: text/plain; charset=ISO-8859-1 I have the same config order as you. It seems to have written the log level change to local.ini . However, I'm not sure how to interpret that... does that mean it's giving local.ini the highest precedence? So, I looked at http://localhost:5984/_utils/config.html and it's now reporting socket_options [{nodelay, true}] This is after I changed local.ini to have the value socket_option = [{keepalive, true}, {nodelay, true}] since both default and local.ini say keepalive is true, it seems odd that it's now dropped... On Fri, Jun 1, 2012 at 2:15 PM, Dave Cottlehuber wrote: > On 1 June 2012 17:09, Tim Tisdall wrote: > > Maybe I'm missing something simple, but my understanding is that > local.ini > > values should take precedence over values in default.ini . However, I'm > > trying to set nodelay to true for the socket_options and that doesn't > > appear to be working. > > > Strictly speaking the ini file that's last in the chain takes precedence, > and > its also the file that gets changes written to. > > You can see which ones are being used and in what order with > > $ couchdb -c > /usr/local/etc/couchdb/default.ini > /usr/local/etc/couchdb/local.ini > > > Here's what's in default.ini : > > socket_options = [{keepalive, true}, {nodelay, false}] > > > > here's what's in local.ini: > > socket_options = [{nodelay, true}] > > > > http://localhost:5984/_utils/config.html is reporting that > socket_options > > is equal to: > > [{keepalive, true}, {nodelay, false}] > > > > > > I've restarted the couchdb server multiple times since making the change, > > but just noticed now that the change doesn't appear to have been made. > I'm > > using v1.2.0 > > A restart is not required, the erlang magic picks up the changed config > for you. > > If your config chain above doesn't raise warning bells, can you temporarily > up the log level to debug, try this: > > COUCH=http://admin:passwd@localhost:5984 > curl -vXPUT $COUCH/_config/httpd/fake_key -d '"fake_value"' > > You should see something like this in your logs: > > [Fri, 01 Jun 2012 18:10:23 GMT] [debug] [<0.287.0>] 'PUT' > /_config/httpd/fake_key {1,1} from "127.0.0.1" > Headers: [{'Accept',"*/*"}, > {'Authorization',"Basic YWRtaW46cFGSzc3dk"}, > {'Content-Length',"12"}, > {'Content-Type',"application/x-www-form-urlencoded"}, > {'Host',"localhost:5984"}, > {'User-Agent',"curl/7.21.4 (universal-apple-darwin11.0) > libcurl/7.21.4 OpenSSL/0.9.8r zlib/1.2.5"}] > [Fri, 01 Jun 2012 18:10:23 GMT] [debug] [<0.287.0>] OAuth Params: [] > [Fri, 01 Jun 2012 18:10:23 GMT] [info] [<0.287.0>] 127.0.0.1 - - PUT > /_config/httpd/fake_key 200 > > And you should be able to grep for fake_key if needed to see where > it's being written to. > > In fact you can even use upping the log level as a check: > > curl -vXPUT $COUCH/_config/log/level -d '"debug"' > > and back to error > > curl -vXPUT $COUCH/_config/log/level -d '"error"' > > A+ > Dave > --0016e6ddab60e56ce104c16f6a5b--