incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Randall Leeds <randall.le...@gmail.com>
Subject Re: Not too important...until it causes something to break...
Date Sun, 15 Jan 2012 19:19:29 GMT
On Sat, Jan 14, 2012 at 17:02, Paul Torres <ptorresnyc@gmail.com> wrote:
> Does anyone have any idea how this happened? Hopefully it'll help somebody.
>
> I have 2 near-identical machines. They run the same OS (Debian
> Squeeze), with the same versions of Erlang, etc., and other
> dependencies. I built the same version of CouchDB from source (1.1.0)
> and built the same version from source of geocouch, and the directory
> structures are near identical...and are identical in the /usr
> directory which was the target of the make install for couchdb, but:
>
> On my 2nd machine I spent an entire day figuring out that my couchdb
> was crashing only when the geocouch.ini file was in place. And this
> was only discernable via the log file, because at the command line it
> gave no hint of crashing aside from being unreachable by curl or
> futon. Why was this? Because the erlang path did not include the beam
> files in my geocouch build. The log file showed errors that partly
> stated: ... [error] ...
> {errorContext,starterror},{reason{'EXIT',undef,[{couch_spatial,start_link,[]}
> ...
>
> My environment had specified the proper path with ERL_FLAGS="-pa
> /path/to/geocouch/build" as per the readme and as I had done on my 1st
> machine--which is working even now. Just throwing spaghetti at the
> wall in desperation--along with reinstalling couchdb and geocouch--I
> read here (http://markmail.org/message/abpfknxj4vm62qym) about using a
> slightly different erlang environment variable: ERL_ZFLAGS="-pz
> /path/to/geocouch/ebin".
>
> That fixed things for me, and now my 2nd machine works, couchdb doesnt
> crash, and futon tests pass including the spatial tests. But it
> refuses to work any other way and I wasted an entire day on this.
> What's the diff? Is this caused by something that will cause more
> problems down the road? As far as I can tell there is no difference
> between ERL_FLAGS and ERL_ZFLAGS, yet there is in practice. And why
> else would there be 2 kinds of ERL flags anyway?


As far as I know ERL_ZFLAGS and ERL_FLAGS are the same. Probably the
second one is there because it's what people expect and the first is
there to be the match for ERL_AFLAGS which adds new flags to the
beginning of the command rather than the end.

Both ZFLAGS and FLAGS should work, though. Strange if it doesn't.

>
> I should mention that I bone-headedly made the mistake of building the
> wrong version of couchdb on top of a prior version by mistake...but I
> removed the resulting mess...and then built the correct version...but
> I don't see how that affects the erlang path. I even reinstalled
> erlang packages to no effect as well prior to hitting upon the
> ERL_ZFLAG. Futon shows the correct version too.
>
> -Paul

-Randall

Mime
View raw message