Hey folks. I'm setting up my first CouchDB instance for an internal project, 
and am running into an error on start-up. I was wondering if anybody could help.

In short, I'm trying to run CouchDB like we run Apache. We have Apache 
installed in a shared, unwritable filesystem. To run an instance, one copies 
the apachectl file and the default configuration file, edits apachectl to point 
to the config file copy, then edits the config file to point to local log 
directories and perform other custom configurations. When 'apachectl start' is 
run, it uses the binaries from the shared area and the custom config, and runs 
great.

To mimic this, I copied bin/couchdb to a local area as well as etc/local.*. I 
edited bin/couchdb to point to local files where necessary:

> diff /tools/couchdb/1.2.0/Linux_x86_64/bin/couchdb bin/couchdb
25c25
< HEART_COMMAND="/tools/couchdb/1.2.0/Linux_x86_64/bin/couchdb -k"
---
> HEART_COMMAND="$0 -k"
28,30c28,30
< LOCAL_CONFIG_DIR=/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/local.d
< LOCAL_CONFIG_FILE=/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/local.ini
< PID_FILE=/tools/couchdb/1.2.0/Linux_x86_64/var/run/couchdb/couchdb.pid
---
> LOCAL_CONFIG_DIR=/webserver/couchdb/etc/local.d
> LOCAL_CONFIG_FILE=/webserver/couchdb/etc/local.ini
> PID_FILE=/webserver/couchdb/couchdb.pid

Using the -c startup option, this appears to be fine:

> bin/couchdb -c
/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/default.ini
/webserver/couchdb/etc/local.ini

My etc/local.ini file is also changed minimally, mainly to point things at 
local paths (and turn on debugging):

> diff /tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/local.ini etc/local.ini
7a8,9
> database_dir = /webserver/couchdb/db
> view_index_dir = /webserver/couchdb/db
12c14
< ;bind_address = 127.0.0.1
---
> bind_address = *
38c40,41
< ;level = debug
---
> file = /webserver/logs/couchdb/couch.log
> level = debug

Startup at this point dumps a lot of debug output, and everything seems to be 
as I configured it. I'll only include the things that reflect changes that I've 
made; let me know if you want to see the entire output.

> bin/couchdb
Apache CouchDB 1.2.0 (LogLevel=debug) is starting.
Configuration Settings 
["/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/default.ini",
                        "/webserver/couchdb/etc/local.ini"]:
  [couchdb] database_dir="/webserver/couchdb/db"
  [couchdb] view_index_dir="/webserver/couchdb/db"
  [httpd] bind_address="*"
  [log] file="/webserver/logs/couchdb/couch.log"
  [log] level="debug"
{"init terminating in 
do_boot",{{badmatch,{error,{bad_return,{{couch_app,start,[normal,["/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/default.ini","/tools/couchdb/1.2.0/Linux_x86_64/etc/couchdb/local.ini"]]},{'EXIT',{{badmatch,{error,shutdown}},[{couch_server_sup,start_server,1},{application_master,start_it_old,4}]}}}}}},[{couch,start,0},{init,start_it,1},{init,start_em,1}]}}

Crash dump was written to: erl_crash.dump
init terminating in do_boot ()

All the other debug outputs are the same as the values found in default.ini, so 
it appears that my local.ini is being seen and parsed. Can anybody explain what 
they cryptic error might mean? :) Thanks!

 [cid:[email protected]]
Doug Shea
Lead Engineer
[email protected]<mailto:[email protected]>
www.nokia.com<http://www.nokia.com/>



  ________________________________
The information contained in this communication may be CONFIDENTIAL and is 
intended only for the use of the recipient(s) named above. If you are not the 
intended recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication, or any of its contents, is 
strictly prohibited. If you have received this communication in error, please 
notify the sender and delete/destroy the original message and any copy of it 
from your computer or paper files.

Reply via email to