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 9862E9F31 for ; Mon, 19 Mar 2012 10:54:10 +0000 (UTC) Received: (qmail 88660 invoked by uid 500); 19 Mar 2012 10:54:09 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 88630 invoked by uid 500); 19 Mar 2012 10:54:08 -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 88621 invoked by uid 99); 19 Mar 2012 10:54:08 -0000 Received: from minotaur.apache.org (HELO minotaur.apache.org) (140.211.11.9) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Mar 2012 10:54:08 +0000 Received: from localhost (HELO mail-iy0-f180.google.com) (127.0.0.1) (smtp-auth username rnewson, mechanism plain) by minotaur.apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Mar 2012 10:54:08 +0000 Received: by iage36 with SMTP id e36so12364213iag.11 for ; Mon, 19 Mar 2012 03:54:07 -0700 (PDT) MIME-Version: 1.0 Received: by 10.50.219.163 with SMTP id pp3mr5753790igc.1.1332154447702; Mon, 19 Mar 2012 03:54:07 -0700 (PDT) Received: by 10.42.99.195 with HTTP; Mon, 19 Mar 2012 03:54:07 -0700 (PDT) In-Reply-To: References: Date: Mon, 19 Mar 2012 10:54:07 +0000 Message-ID: Subject: Re: Weird error From: Robert Newson To: user@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable hm, looks like it wasn't me that committed the fix, but everything still st= ands. On 19 March 2012 10:52, Robert Newson wrote: > The genuine error aside, the io_lib part of that is because we don't > capture the stacktrace correctly when we log. I fixed this over on > cloudant a while back; > > Couchdb does this; > > =A0 =A0 =A0 =A0Tag:Error -> > =A0 =A0 =A0 =A0 =A0 =A0?LOG_ERROR("Uncaught error in HTTP request: ~p",[{= Tag, Error}]), > =A0 =A0 =A0 =A0 =A0 =A0?LOG_INFO("Stacktrace: ~p",[erlang:get_stacktrace(= )]), > =A0 =A0 =A0 =A0 =A0 =A0send_error(HttpReq, Error) > > The improvement is this; > > =A0 =A0 =A0 =A0Tag:Error -> > =A0 =A0 =A0 =A0 =A0 =A0Stack =3D erlang:get_stacktrace(), > =A0 =A0 =A0 =A0 =A0 =A0twig:log(error, "req_err ~p:~p ~p", [Tag, Error, > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0json_stack({Error, nil, Stack})]), > =A0 =A0 =A0 =A0 =A0 =A0send_error(HttpReq, {Error, nil, Stack}) > > This is fixed on master but not 1.1.x or 1.2.x. Worth a backport imo > if it's not too late for 1.2.0. > > B. > > > > On 19 March 2012 09:21, Dave Cottlehuber wrote: >> On 19 March 2012 09:08, Karoly Szanto wrote: >>> Hi, >>> In the couchDB server log file I get the following weird error that I c= an't >>> understand >>> >>> [Thu, 08 Mar 2012 02:07:29 GMT] [error] [<0.1783.0>] Uncaught error in = HTTP >>> request: {error, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0{case_clause, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {error,enotsock}}} >>> [Thu, 08 Mar 2012 02:07:29 GMT] [info] [<0.1783.0>] Stacktrace: >>> [{io_lib_pretty,cind_tag_tuple,7}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _pretty,while_fail,3}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _pretty,print,6}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _format,build,3}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _format,build,3}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _format,build,3}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _format,build,3}, >>> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 {io_lib= _format,build,3}] >>> >>> Any hints? >>> >>> Thank you, >>> Karoly >> >> Hi Karoly >> >> enotsock I think is complaining you passed a file not a socket. >> Nothing comes to mind immediately, >> but I'd be interested to know - >> >> what erlang version, OS are you running? >> do you have multiple network interfaces, and what is your bind_address >> set to for couchdb? >> any relevant couch activity prior to this issue? maybe some more log >> info would help. >> is this repeatable, and has couch been running correctly prior? >> >> Some reading - >> http://erlang.2086793.n4.nabble.com/enotsock-again-td2088701.html >> http://erlang.2086793.n4.nabble.com/erlang-questions-Unable-to-start-eja= bberd-or-use-TCP-IP-communication-in-erlang-interpreter-td2093426.html >> http://comments.gmane.org/gmane.comp.lang.erlang.general/8410%3Cbr >> >> A+ >> Dave