Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 327351 - dev-db/desktopcouch doesn't like /etc/couchdb permissions
Summary: dev-db/desktopcouch doesn't like /etc/couchdb permissions
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Jesus Rivero (RETIRED)
URL: https://bugs.launchpad.net/desktopcou...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-07 16:36 UTC by Maciej Piechotka
Modified: 2012-04-16 18:43 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Maciej Piechotka 2010-07-07 16:36:25 UTC
% cat .cache/desktop-couch/desktop-couchdb.stdout

=CRASH REPORT==== 7-Jul-2010::18:20:46 ===
  crasher:
    initial call: couch_config:init/1
    pid: <0.76.0>
    registered_name: []
    exception exit: {{case_clause,{error,eacces}},
                     [{couch_config,parse_ini_file,1},
                      {couch_config,'-init/1-fun-0-',1},
                      {lists,map,2},
                      {couch_config,init,1},
                      {gen_server,init_it,6},
                      {proc_lib,init_p_do_apply,3}]}
      in function gen_server:init_it/6
    ancestors: [<0.32.0>]
    messages: []
    links: [<0.32.0>]
    dictionary: []
    trap_exit: false
    status: running
    heap_size: 610
    stack_size: 24
    reductions: 179
  neighbours:

=CRASH REPORT==== 7-Jul-2010::18:20:46 ===
  crasher:
    initial call: application_master:init/4
    pid: <0.31.0>
    registered_name: []
    exception exit: {bad_return,
                        {{couch_app,start,
                             [normal,
                              ["/etc/couchdb/default.ini",
                               "/etc/couchdb/local.ini"]]},
                         {'EXIT',
                             {{badmatch,
                                  {error,
                                      {{case_clause,{error,eacces}},
                                       [{couch_config,parse_ini_file,1},
                                        {couch_config,'-init/1-fun-0-',1},
                                        {lists,map,2},
                                        {couch_config,init,1},
                                        {gen_server,init_it,6},
                                        {proc_lib,init_p_do_apply,3}]}}},
                              [{couch_server_sup,start_server,1},
                               {application_master,start_it_old,4}]}}}}
      in function application_master:init/4
    ancestors: [<0.30.0>]
    messages: [{'EXIT',<0.32.0>,normal}]
    links: [<0.30.0>,<0.6.0>]
    dictionary: []
    trap_exit: true
    status: running
    heap_size: 987
    stack_size: 24
    reductions: 118
  neighbours:

desktopcouch stack:

  File "/usr/lib64/python2.6/site-packages/desktopcouch/__init__.py", line 51, in find_port
    return _direct_access_find_port(pid=pid, ctx=ctx)
  File "/usr/lib64/python2.6/site-packages/desktopcouch/__init__.py", line 132, in __find_port__linux
    raise RuntimeError("Unable to find listening port")
RuntimeError: Unable to find listening port

After making /etc/couchdb/*.ini readable problem is gone
Comment 1 Dirkjan Ochtman (RETIRED) gentoo-dev 2010-07-17 17:23:43 UTC
CouchDB is installed as a server, to be run through /etc/init.d/couchdb. Not sure how you ran it here, but looks like some other way.
Comment 2 Maciej Piechotka 2010-07-25 19:09:16 UTC
By desktopcouch https://launchpad.net/desktopcouch

It runs per-user instance of couchdb.
Comment 3 Mike Nelson 2010-11-03 16:18:08 UTC
(In reply to comment #2)
> By desktopcouch https://launchpad.net/desktopcouch
> 
> It runs per-user instance of couchdb.
> 

I was getting a similar error when doing "/etc/init.d/couchdb start". I would look like it started properly but it just stop running silently. In the log there were access errors on "/etc/couchdb/local.ini". Looks like it was when it tried to update the password on one of my admin users that I added there. This fixed it for me,

# chown couchdb.couchdb /etc/couchdb/local.ini

Not too sure if these permissions would be considered a "proper" install. Permissions on other /etc/couchdb files might need to be get updated as well.
Comment 4 Jesus Rivero (RETIRED) gentoo-dev 2010-12-16 01:15:04 UTC
Hi there, 

    According to the bug at Launchpad, CouchDB *ini files perms should be set to 0664. Dirkjan, what do you think about this?

    Best regards,
Comment 5 Dirkjan Ochtman (RETIRED) gentoo-dev 2010-12-16 07:42:06 UTC
My problem with that is that /etc/couchdb/local.ini may contain a password for the admin user, and I don't think it's a good idea to make that world-readable.
Comment 6 Jesus Rivero (RETIRED) gentoo-dev 2012-04-16 18:43:25 UTC
Nothing to do from desktopcouch's side. Closing as WONTFIX