You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Sho Fukamachi <sh...@gmail.com> on 2008/05/01 10:03:55 UTC
errors in tests
Hi all,
I am getting errors running the test suite after a seemingly
successful installation on RHEL4.
The errors occur in almost all tests, and the result usually looks
something like this:
Exception raised:{"error":"error","reason":"{{nocatch,
{map_process_error,{exit_status,127}}},\n
[{couch_query_servers,readline,2},\n {couch_query_servers,read_json,1},
\n {couch_query_servers,start_doc_map,2},\n {couch_view,view_compute,
2},\n {couch_view,update_group,1},\n {couch_view,temp_update_loop,
2}]}","line":106,"sourceURL":"http://testserver.net:5984/_utils/script/couch.js
"}
In the console log it looks like this:
info] [<0.1695.0>] 123.456.789.123 - - "GET /test_suite_db/_all_docs"
200
[info] [<0.1706.0>] Spawning new text/javascript instance.
/usr/local/lib/couchdb/bin/couchjs: symbol lookup error: /usr/local/
lib/couchdb/bin/couchjs: undefined symbol: js_fgets
[error] [emulator] Error in process <0.1706.0> with exit value:
{{nocatch,{map_process_error,{exit_status,127}}},
[{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
{couch_view,update_group,1},{couch_view...
=ERROR REPORT==== 1-May-2008::07:52:53 ===
Error in process <0.1706.0> with exit value: {{nocatch,
{map_process_error,{exit_status,127}}},[{couch_query_servers,readline,
2},{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
{couch_view,update_group,1},{couch_view...
[info] [<0.1695.0>] HTTP Error (code 500): {{nocatch,
{map_process_error,{exit_status,127}}},
[{couch_query_servers,readline,2},
{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},
{couch_view,view_compute,2},
{couch_view,update_group,1},
{couch_view,temp_update_loop,2}]}
[info] [<0.1695.0>] 123.456.789.123 - - "POST /test_suite_db/
_temp_view" 500
Any clues? I had many problems installing before but this is a clean
install following the most recent CentOS4 instructions by Dennis Sacks
(subject "building couch from svn") and my own (subject "can't install
on RHEL4 anymore"). I can post full installation steps if it helps.
thanks,
Sho
Re: errors in tests
Posted by Sho Fukamachi <sh...@gmail.com>.
Hi Chris,
> Absolutely, but also by a bad Erlang install.
Well, I've installed Erlang again (several times, from R12-B source)
without (visible) errors...
> I've had a very similar problem with Erlang on Debian Etch on an
> AMD64 Linode. I was using the Erlang version available via apt-get,
> and seeing problems like those you're seeing. I then tried to
> install Erlang from source, only to see the configure script hang on
> a line "checking floating point exceptions" (or similar). After some
> research it turns out this was a compatibility problem with AMD64,
> but you could disable HiPE to get around it. Which is what I did (./
> configure --disable-hipe IIRC), and things worked.
Maybe this is fixed in more recent versions, or maybe it was a Xen
thing - this is a dedicated server. Anyway, I can't see any problems
with Erlang, I can load the console fine. Do you recommend any tests I
can do which might expose the error, if it exists?
> One symptom of this is if couchjs works as expected when run
> manually from the command-line, e.g.
>
> $ /usr/local/couchdb/bin/couchjs /usr/local/couchdb/share/couchdb/
> server/main.js
> ["reset"]
> true
# /usr/local/bin/couchjs /usr/local/share/couchdb/server/main.js
/usr/local/lib/couchdb/bin/couchjs: symbol lookup error: /usr/local/
lib/couchdb/bin/couchjs: undefined symbol: js_fgets
Doesn't work. And while we're at it,
# /tmp/couchdb/bin/couchjs /tmp/couchdb/share/couchdb/server/main.js
/tmp/couchdb/lib/couchdb/bin/couchjs: symbol lookup error: /tmp/
couchdb/lib/couchdb/bin/couchjs: undefined symbol: js_fgets
> If it doesn't work, there's probably something wrong with your
> spidermonkey installation.
Wouldn't surprise me at all, although I've re-installed spidermonkey
several times, with any number of variations on the theme. I've also
copied the js executable to /usr/bin, just to get rid of the old 1.5.0
version which used to be there - although I've been telling couch to
look in the /usr/local/spidermonkey folders anyway.
# which js
/usr/bin/js
# /usr/bin/js -v
JavaScript-C 1.7.0 2007-10-03
The spidermonkey page on Mozilla's site gives a small test, running a
"perfect.js" test script - I've run that against every binary I can
find on the system, they all work fine.
I'm kind of out of ideas as to how to troubleshoot the spidermonkey
install any further. I've also tried to isolate the issue as much as
possible - I just reinstalled spidermoney to /tmp/spidermonkey, then
configured a new couchdb against that and made/installed it to another
tmp dir .. exactly the same problem.
Still, I can't escape the feeling that CouchDB is not linking properly
or something. I'm using this line to configure it:
./configure --with-js-lib=/usr/local/spidermonkey/lib64 --with-js-
include=/usr/local/spidermonkey/include
Which correspond to the correct directories. However I'm aware there
are several other "with js-(something)=" options .. does it need more
information? Does it need to be told where the binary is, too? Could
it be a simple naming issue .. not expecting "lib64"?
Other areas of confusion for me include the necessity of the setting
environment variables like
export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/usr/local/spidermonkey/lib
I've tried this as well, no difference that I could see. Another thing
I'm not sure about is the exact commands to install spidermonkey, I
followed the exact instructions in the wiki (and mailing list, and
IRC) and it *seems* to work but I don't trust it. But maybe that's
just me grasping at straws .. : )
Anyway thanks a lot for your patience and help - it's a tricky one.
Sho
>
>
> Cheers,
> Chris
> --
> Christopher Lenz
> cmlenz at gmx.de
> http://www.cmlenz.net/
>
Re: errors in tests
Posted by Sho Fukamachi <sh...@gmail.com>.
On 06/05/2008, at 2:58 AM, Christopher Lenz wrote:
> The directory is probably just not on your library path. You
> mentioned DYLD_LIBRARY_PATH in your previous post, but that var is
> OS X specific AFAIK; the Linux equivalent is LD_LIBRARY_PATH.
Oops. Well, that fixed one problem (with the manual test of couchjs).
I'm now getting the crash on boot - which is really weird, because it
*was* working before I tried to "fix" spidermonkey. Seems solving one
problem exposes another; I'll reply to later messages on my efforts in
the latter case.
However - I had been under the impression that LD_LIBRARY_PATH was
kind of a hack to get around a bad build, though - doesn't it mean
that couchjs hasn't linked properly in the first place to the library
path in the configure command ?
Been a long time since I messed with that kind of thing, though, not
really a hardcore linux admin, as is probably pretty obvious ...
thanks for your help,
Sho
>
> Cheers,
> --
> Christopher Lenz
> cmlenz at gmx.de
> http://www.cmlenz.net/
>
Re: errors in tests
Posted by Christopher Lenz <cm...@gmx.de>.
On 03.05.2008, at 01:05, Sho Fukamachi wrote:
> testing couchjs:
>
> # /usr/local/bin/couchjs /usr/local/share/couchdb/server/main.js
> /usr/local/lib/couchdb/bin/couchjs: error while loading shared
> libraries: libjs.so: cannot open shared object file: No such file or
> directory
>
> libjs.so?
>
> # locate libjs.so
> /root/src/js/src/Linux_All_DBG.OBJ/libjs.so
> /usr/local/spidermonkey/lib64/libjs.so
The directory is probably just not on your library path. You mentioned
DYLD_LIBRARY_PATH in your previous post, but that var is OS X specific
AFAIK; the Linux equivalent is LD_LIBRARY_PATH.
Cheers,
--
Christopher Lenz
cmlenz at gmx.de
http://www.cmlenz.net/
Re: errors in tests
Posted by Sho Fukamachi <sh...@gmail.com>.
Sorry to double post, but I just did an svn up and now it's a
different error message from couchjs - and a crash when you try to run
couchdb.
configure line:
./configure --with-js-lib=/usr/local/spidermonkey/lib64 --with-js-
include=/usr/local/spidermonkey/include
testing couchjs:
# /usr/local/bin/couchjs /usr/local/share/couchdb/server/main.js
/usr/local/lib/couchdb/bin/couchjs: error while loading shared
libraries: libjs.so: cannot open shared object file: No such file or
directory
libjs.so?
# locate libjs.so
/root/src/js/src/Linux_All_DBG.OBJ/libjs.so
/usr/local/spidermonkey/lib64/libjs.so
Now it can't find it! Well, it's an improvement : )
# ls -la /usr/local/spidermonkey/lib64/
total 2072
drwxr-xr-x 2 root root 4096 May 1 07:04 .
drwxr-xr-x 5 root root 4096 May 1 07:02 ..
-rw-r--r-- 1 root root 1219254 May 2 05:55 libjs.a
-rwxr-xr-x 1 root root 883089 May 2 05:55 libjs.so
Everything's being done as root so i don't think it's a permissions
problem.
Running couchdb now crashes with a crashlog. I've zipped it and placed
it at http://fukamachi.org/media/erl_crash.dump.gz if you're
interested...
thanks again,
Sho
On 03/05/2008, at 7:47 AM, Christopher Lenz wrote:
> On 01.05.2008, at 23:32, Sho Fukamachi wrote:
>> I followed the steps in the troubleshooting page you linked to.
>> I've copied my entire step-by-step process below, exactly as I did
>> it. Bear in mind though that js/spidermonkey is not included in
>> that - the logs suggest the error is in couchjs, but could that be
>> affected by a bad spidermonkey install?
>
> Absolutely, but also by a bad Erlang install.
>
> I've had a very similar problem with Erlang on Debian Etch on an
> AMD64 Linode. I was using the Erlang version available via apt-get,
> and seeing problems like those you're seeing. I then tried to
> install Erlang from source, only to see the configure script hang on
> a line "checking floating point exceptions" (or similar). After some
> research it turns out this was a compatibility problem with AMD64,
> but you could disable HiPE to get around it. Which is what I did (./
> configure --disable-hipe IIRC), and things worked.
>
> (I've since got upgraded to a different Xen-based virtual machine
> where the system Erlang works fine.)
>
> One symptom of this is if couchjs works as expected when run
> manually from the command-line, e.g.
>
> $ /usr/local/couchdb/bin/couchjs /usr/local/couchdb/share/couchdb/
> server/main.js
> ["reset"]
> true
>
> (First line is the commandline invocation, second line is what you
> type in when couchjs waits for input, and third line is the expected
> output).
>
> If this works, then please have a closer look at rebuilding erlang
> with HiPE disabled.
>
> If it doesn't work, there's probably something wrong with your
> spidermonkey installation.
>
> Cheers,
> Chris
> --
> Christopher Lenz
> cmlenz at gmx.de
> http://www.cmlenz.net/
>
Re: errors in tests
Posted by Christopher Lenz <cm...@gmx.de>.
On 01.05.2008, at 23:32, Sho Fukamachi wrote:
> I followed the steps in the troubleshooting page you linked to. I've
> copied my entire step-by-step process below, exactly as I did it.
> Bear in mind though that js/spidermonkey is not included in that -
> the logs suggest the error is in couchjs, but could that be affected
> by a bad spidermonkey install?
Absolutely, but also by a bad Erlang install.
I've had a very similar problem with Erlang on Debian Etch on an AMD64
Linode. I was using the Erlang version available via apt-get, and
seeing problems like those you're seeing. I then tried to install
Erlang from source, only to see the configure script hang on a line
"checking floating point exceptions" (or similar). After some research
it turns out this was a compatibility problem with AMD64, but you
could disable HiPE to get around it. Which is what I did (./configure
--disable-hipe IIRC), and things worked.
(I've since got upgraded to a different Xen-based virtual machine
where the system Erlang works fine.)
One symptom of this is if couchjs works as expected when run manually
from the command-line, e.g.
$ /usr/local/couchdb/bin/couchjs /usr/local/couchdb/share/couchdb/
server/main.js
["reset"]
true
(First line is the commandline invocation, second line is what you
type in when couchjs waits for input, and third line is the expected
output).
If this works, then please have a closer look at rebuilding erlang
with HiPE disabled.
If it doesn't work, there's probably something wrong with your
spidermonkey installation.
Cheers,
Chris
--
Christopher Lenz
cmlenz at gmx.de
http://www.cmlenz.net/
Re: errors in tests
Posted by Sho Fukamachi <sh...@gmail.com>.
Hi Jan (and Noah),
I followed the steps in the troubleshooting page you linked to. I've
copied my entire step-by-step process below, exactly as I did it. Bear
in mind though that js/spidermonkey is not included in that - the logs
suggest the error is in couchjs, but could that be affected by a bad
spidermonkey install?
Anyway, here it is. I've also created a page on the wiki called
InstallingOnRHEL4 which is the steps to get an apparently-working
install like I've been doing and I believe Dennis Sacks has also done
- he, however, has confirmed he doesn't get the same issues as me.
link: http://wiki.apache.org/couchdb/InstallingOnRHEL4
Also, note that this is an x86_64 system.
full installation steps:
# svn co http://svn.apache.org/repos/asf/incubator/couchdb/trunk
couchdb-test
# cd couchdb-test
# ./bootstrap -C
# ./configure --prefix=/tmp/couchdb --with-js-lib=/usr/local/
spidermonkey/lib64 --with-js-include=/usr/local/spidermonkey/include
# make && make install
# vi /tmp/etc/couchdb/couchdb.ini (change binding from 127.0.0.1 to
0.0.0.0 for remote testing)
# /tmp/couchdb/bin/couchdb
output - futon utility "basics" test
• Exception raised:{"error":"error","reason":"{{nocatch,
{map_process_error,{exit_status,127}}},\n
[{couch_query_servers,readline,2},\n {couch_query_servers,read_json,1},
\n {couch_query_servers,start_doc_map,2},\n {couch_view,view_compute,
2},\n {couch_view,update_group,1},\n {couch_view,temp_update_loop,
2}]}","line":106,"sourceURL":"http://myserver.net:5984/_utils/script/couch.js
"}
output - console for same test
[info] [<0.72.0>] Spawning new text/javascript instance.
/tmp/couchdb/lib/couchdb/bin/couchjs: symbol lookup error: /tmp/
couchdb/lib/couchdb/bin/couchjs: undefined symbol: js_fgets
[error] [emulator] Error in process <0.72.0> with exit value:
{{nocatch,{map_process_error,{exit_status,127}}},
[{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
{couch_view,update_group,1},{couch_view...
=ERROR REPORT==== 2-May-2008::04:10:14 ===
Error in process <0.72.0> with exit value: {{nocatch,
{map_process_error,{exit_status,127}}},[{couch_query_servers,readline,
2},{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
{couch_view,update_group,1},{couch_view...
[info] [<0.56.0>] HTTP Error (code 500): {{nocatch,{map_process_error,
{exit_status,127}}},
[{couch_query_servers,readline,2},
{couch_query_servers,read_json,1},
{couch_query_servers,start_doc_map,2},
{couch_view,view_compute,2},
{couch_view,update_group,1},
{couch_view,temp_update_loop,2}]}
thanks,
Sho
On 02/05/2008, at 12:29 AM, Jan Lehnardt wrote:
> Heya Sho,
> it's still confusing me that you keep getting those errors.
>
> This one looks again a lot like your couchjs installation
> is hosed. Maybe it got linked against a too old version
> of libjs, or the linked shared library is not in the library
> search path or so?
>
> Can you see if
> http://wiki.apache.org/couchdb/Troubleshooting
> gets you any more infos?
>
> Cheers
> Jan
> --
>
> On May 1, 2008, at 10:03, Sho Fukamachi wrote:
>> Hi all,
>>
>> I am getting errors running the test suite after a seemingly
>> successful installation on RHEL4.
>>
>> The errors occur in almost all tests, and the result usually looks
>> something like this:
>>
>> Exception raised:{"error":"error","reason":"{{nocatch,
>> {map_process_error,{exit_status,127}}},\n
>> [{couch_query_servers,readline,2},\n {couch_query_servers,read_json,
>> 1},\n {couch_query_servers,start_doc_map,2},\n
>> {couch_view,view_compute,2},\n {couch_view,update_group,1},\n
>> {couch_view,temp_update_loop,2}]}","line":106,"sourceURL":"http://testserver.net:5984/_utils/script/couch.js
>> "}
>>
>> In the console log it looks like this:
>>
>> info] [<0.1695.0>] 123.456.789.123 - - "GET /test_suite_db/
>> _all_docs" 200
>> [info] [<0.1706.0>] Spawning new text/javascript instance.
>> /usr/local/lib/couchdb/bin/couchjs: symbol lookup error: /usr/local/
>> lib/couchdb/bin/couchjs: undefined symbol: js_fgets
>> [error] [emulator] Error in process <0.1706.0> with exit value:
>> {{nocatch,{map_process_error,{exit_status,127}}},
>> [{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
>> {couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
>> {couch_view,update_group,1},{couch_view...
>> =ERROR REPORT==== 1-May-2008::07:52:53 ===
>> Error in process <0.1706.0> with exit value: {{nocatch,
>> {map_process_error,{exit_status,127}}},
>> [{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
>> {couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
>> {couch_view,update_group,1},{couch_view...
>>
>> [info] [<0.1695.0>] HTTP Error (code 500): {{nocatch,
>> {map_process_error,{exit_status,127}}},
>> [{couch_query_servers,readline,2},
>> {couch_query_servers,read_json,1},
>> {couch_query_servers,start_doc_map,2},
>> {couch_view,view_compute,2},
>> {couch_view,update_group,1},
>> {couch_view,temp_update_loop,2}]}
>> [info] [<0.1695.0>] 123.456.789.123 - - "POST /test_suite_db/
>> _temp_view" 500
>>
>> Any clues? I had many problems installing before but this is a
>> clean install following the most recent CentOS4 instructions by
>> Dennis Sacks (subject "building couch from svn") and my own
>> (subject "can't install on RHEL4 anymore"). I can post full
>> installation steps if it helps.
>>
>> thanks,
>>
>> Sho
>
Re: errors in tests
Posted by Jan Lehnardt <ja...@apache.org>.
Heya Sho,
it's still confusing me that you keep getting those errors.
This one looks again a lot like your couchjs installation
is hosed. Maybe it got linked against a too old version
of libjs, or the linked shared library is not in the library
search path or so?
Can you see if
http://wiki.apache.org/couchdb/Troubleshooting
gets you any more infos?
Cheers
Jan
--
On May 1, 2008, at 10:03, Sho Fukamachi wrote:
> Hi all,
>
> I am getting errors running the test suite after a seemingly
> successful installation on RHEL4.
>
> The errors occur in almost all tests, and the result usually looks
> something like this:
>
> Exception raised:{"error":"error","reason":"{{nocatch,
> {map_process_error,{exit_status,127}}},\n
> [{couch_query_servers,readline,2},\n {couch_query_servers,read_json,
> 1},\n {couch_query_servers,start_doc_map,2},\n
> {couch_view,view_compute,2},\n {couch_view,update_group,1},\n
> {couch_view,temp_update_loop,2}]}","line":106,"sourceURL":"http://testserver.net:5984/_utils/script/couch.js
> "}
>
> In the console log it looks like this:
>
> info] [<0.1695.0>] 123.456.789.123 - - "GET /test_suite_db/
> _all_docs" 200
> [info] [<0.1706.0>] Spawning new text/javascript instance.
> /usr/local/lib/couchdb/bin/couchjs: symbol lookup error: /usr/local/
> lib/couchdb/bin/couchjs: undefined symbol: js_fgets
> [error] [emulator] Error in process <0.1706.0> with exit value:
> {{nocatch,{map_process_error,{exit_status,127}}},
> [{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
> {couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
> {couch_view,update_group,1},{couch_view...
> =ERROR REPORT==== 1-May-2008::07:52:53 ===
> Error in process <0.1706.0> with exit value: {{nocatch,
> {map_process_error,{exit_status,127}}},
> [{couch_query_servers,readline,2},{couch_query_servers,read_json,1},
> {couch_query_servers,start_doc_map,2},{couch_view,view_compute,2},
> {couch_view,update_group,1},{couch_view...
>
> [info] [<0.1695.0>] HTTP Error (code 500): {{nocatch,
> {map_process_error,{exit_status,127}}},
> [{couch_query_servers,readline,2},
> {couch_query_servers,read_json,1},
> {couch_query_servers,start_doc_map,2},
> {couch_view,view_compute,2},
> {couch_view,update_group,1},
> {couch_view,temp_update_loop,2}]}
> [info] [<0.1695.0>] 123.456.789.123 - - "POST /test_suite_db/
> _temp_view" 500
>
> Any clues? I had many problems installing before but this is a clean
> install following the most recent CentOS4 instructions by Dennis
> Sacks (subject "building couch from svn") and my own (subject "can't
> install on RHEL4 anymore"). I can post full installation steps if it
> helps.
>
> thanks,
>
> Sho
Re: errors in tests
Posted by Noah Slater <ns...@apache.org>.
On Thu, May 01, 2008 at 06:03:55PM +1000, Sho Fukamachi wrote:
> Any clues?
Not really, you probably want to speak to Chris (who wrote the JS integration)
though he is on holiday at the moment, should be back soon though.
> I had many problems installing before but this is a clean
> install following the most recent CentOS4 instructions by Dennis Sacks
I got confused by these threads, could I ask you write up the problems you had
and the things you did to get them working on the wiki.
Perhaps: InstallingOnCentOs
As well as functioning as documentation for other users I can pull out any
obvious bugs and get them squashed for you. :)
Thanks,
--
Noah Slater - The Apache Software Foundation <http://www.apache.org/>